Two sets of arrays reach the wout without ever being assigned.
potvac. vacmod.f90:176 allocates potvac(2*mnpd) for every run. For lasym = F, vacmod0.f90:66 sets mnpd2 = mnpd, and the solve at vacuum.f90:139 fills the first mnpd entries only. wrout.f90:330 and 442 define and write the whole array, and freeb_data.f90:149 reads potvac(mn0+mnpd) as potcos. On input.cth_like_free_bdy (VMEC++ test data, with mgrid_cth_like.nc) the written array has 126 entries; entries 64 to 126 are heap contents, nine of them above 1e100 (2.6e111, 1.5e279, ...) in one run and zero in another. The 2017 VMEC2000 8.52 source allocates the same size (allocate_nunv.f:27).
am_aux_f, ai_aux_f, ac_aux_f. vmec_input.f90:359-361 defaults the three _aux_s arrays to -1; the _aux_f arrays (vmec_input.f90:52-56) have no default and are written by wrout.f90:722 and the neighbouring lines. Built with -finit-real=snan, all 1001 entries of each are NaN in the wout; a release build writes whatever static memory holds.
potvac = 0 after the allocation and am_aux_f = 0; ai_aux_f = 0; ac_aux_f = 0 beside the _aux_s defaults make both deterministic.
Two sets of arrays reach the wout without ever being assigned.
potvac. vacmod.f90:176 allocates
potvac(2*mnpd)for every run. Forlasym = F, vacmod0.f90:66 setsmnpd2 = mnpd, and the solve at vacuum.f90:139 fills the firstmnpdentries only. wrout.f90:330 and 442 define and write the whole array, and freeb_data.f90:149 readspotvac(mn0+mnpd)aspotcos. Oninput.cth_like_free_bdy(VMEC++ test data, withmgrid_cth_like.nc) the written array has 126 entries; entries 64 to 126 are heap contents, nine of them above 1e100 (2.6e111, 1.5e279, ...) in one run and zero in another. The 2017 VMEC2000 8.52 source allocates the same size (allocate_nunv.f:27).am_aux_f, ai_aux_f, ac_aux_f. vmec_input.f90:359-361 defaults the three
_aux_sarrays to -1; the_aux_farrays (vmec_input.f90:52-56) have no default and are written by wrout.f90:722 and the neighbouring lines. Built with-finit-real=snan, all 1001 entries of each are NaN in the wout; a release build writes whatever static memory holds.potvac = 0after the allocation andam_aux_f = 0; ai_aux_f = 0; ac_aux_f = 0beside the_aux_sdefaults make both deterministic.