Skip to content

RDCON - BUGFIX - Fill the netcdf cell grid whatever the Galerkin output flags - #327

Merged
matt-pharr merged 2 commits into
developfrom
bugfix/rdcon-cellinfo-netcdf
Oct 23, 2026
Merged

matt-pharr merged 2 commits into
developfrom
bugfix/rdcon-cellinfo-netcdf

Conversation

@StuartBenjamin

Copy link
Copy Markdown
Collaborator

rdcon_netcdf.f writes the Galerkin cell grid (interval_icell, iitvl, etypes, cell_x1, cell_x2) whenever cellinfos is allocated, but gal_output_solution fills it only after its early return on bin_delmatch/out_galsol/bin_galsol. With all three off, the netcdf output gets uninitialised memory. This moves the fill before the return.

DIIID_resistive_example with the three flags set to f:

variable develop this PR
interval_icell[0:3] 1, −1074790400, 879332478 1, 2, 3
cell_x2 max ~1e300 0.976
Δ′ and every other output identical

With the flags on (the shipped deck) the output is bit-identical, and the flags-off cell variables now equal the flags-on ones.


🤖 Generated with Claude Code

…ut flags

gal_output_solution filled cellinfos (interval_icell, iitvl, etypes, cell_x1, cell_x2)
after its early return on bin_delmatch/out_galsol/bin_galsol, but rdcon_netcdf writes
cellinfos whenever it is allocated. With those flags off the netcdf got uninitialised
memory (interval_icell = -1074790400, ..., cell_x2 ~ 1e300). The fill now runs before the
return. DIIID_resistive_example: Delta' and every other variable unchanged; with the
flags off the cell variables now equal the flags-on run.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
StuartBenjamin added a commit to StuartBenjamin/GPEC-1 that referenced this pull request Oct 18, 2026
@StuartBenjamin
StuartBenjamin marked this pull request as draft October 19, 2026 07:57
@logan-nc logan-nc mentioned this pull request Oct 21, 2026
27 tasks done
@StuartBenjamin
StuartBenjamin marked this pull request as ready for review October 23, 2026 02:13

@matt-pharr matt-pharr left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good to me

@matt-pharr
matt-pharr merged commit f7e56f1 into develop Oct 23, 2026
6 checks passed
StuartBenjamin pushed a commit to StuartBenjamin/GPEC-1 that referenced this pull request Oct 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants