Skip to content

Calculate/save parallel distance along flux surfaces#193

Merged
johnomotani merged 2 commits into
masterfrom
calculate-parallel-distance
Aug 19, 2025
Merged

Calculate/save parallel distance along flux surfaces#193
johnomotani merged 2 commits into
masterfrom
calculate-parallel-distance

Conversation

@johnomotani
Copy link
Copy Markdown
Collaborator

Parallel connection length is not needed by BOUT++, but can be nice to know. By calculating during the grid generation process we can do the integration using FineContour objects for increased accuracy, rather than depending on the poloidal resolution of the grid.

Slightly unfortunately requires passing equilibrium objects down into fairly low-level methods in order to be able to calculate B and Bp. Due to this, modifies a relatively large number of methods, because like the psi interpolating function, the equilibrium has to be constructed independently on each of the parallel worker processes, and passed in explicitly as a keyword argument in parallel_map.

Expected results of tests updated to add the new parallel_distance variables, as well as a couple of others that had been previously added since the expected outputs were last updated.

Allow tolerances to be increased for certain variables in the integrated tests when adding random noise, to deal with certain variables seeming to be more sensitive. For now, applies only to "ShiftTorsion_ylow".

  • Tests added
  • Udated manual
  • Updated doc/whats-new.md with a summary of the changes

@johnomotani johnomotani added the enhancement New feature or request label Jun 13, 2025
Expected results of tests updated to add the new `parallel_distance`
variables.

Allow tolerances to be increased for certain variables in the integrated
tests when adding random noise, to deal with certain variables seeming
to be more sensitive. For now, applies only to "ShiftTorsion_ylow".
@johnomotani johnomotani force-pushed the calculate-parallel-distance branch from a3c8e82 to 7fc3e43 Compare June 13, 2025 12:30
@mikekryjak
Copy link
Copy Markdown
Collaborator

Thanks for this, it would be very helpful to have this!

Base automatically changed from fix-xbout-grid-loading to master June 13, 2025 13:39
Copy link
Copy Markdown
Contributor

@bendudson bendudson left a comment

Choose a reason for hiding this comment

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

Thanks @johnomotani !

@johnomotani johnomotani merged commit 2855ecd into master Aug 19, 2025
25 checks passed
@johnomotani johnomotani deleted the calculate-parallel-distance branch August 19, 2025 12:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants