Skip to content

Add new plasma shaping option#4134

Open
ajpearcey wants to merge 9 commits intomainfrom
i_plasma_geo_12
Open

Add new plasma shaping option#4134
ajpearcey wants to merge 9 commits intomainfrom
i_plasma_geo_12

Conversation

@ajpearcey
Copy link
Copy Markdown
Collaborator

add new relationship for elongation v aspect ratio. Validated for low aspect ratio ST devices.

@ajpearcey ajpearcey requested a review from a team as a code owner March 20, 2026 08:28
Copy link
Copy Markdown
Collaborator

@chris-ashe chris-ashe left a comment

Choose a reason for hiding this comment

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

Few comments, you also need to update the docs and give a reference. Please put the reference in IEEE style with a hyperlink DOI

Comment thread process/io/plot_scans.py Outdated
Comment thread process/input.py Outdated
),
"fiooic": InputVariable(
data_structure.constraint_variables, float, range=(0.001, 1.0)
data_structure.constraint_variables, float, range=(0.001, 10.0)
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.

Why has this been changed?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

This was changed to allow a fudge factor during some future concepts scans

Comment thread process/input.py Outdated
Comment thread process/input.py Outdated

if physics_variables.i_plasma_geometry == 12:

physics_variables.kappa = 2.93e0 * ( 1.8e0 / physics_variables.aspect ) ** 0.4e0
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.

A comment with the model origin needs to be added

Copy link
Copy Markdown
Collaborator Author

@ajpearcey ajpearcey Apr 14, 2026

Choose a reason for hiding this comment

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

I'm slightly unclear on the definitive source of the this scaling.

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.

I will see if I can hunt it down

Comment thread process/models/physics/physics.py Outdated
elif physics_variables.i_plasma_geometry == 12:
po.ovarrf(
self.outfile,
"Elongation, X-point (calculated from aspect ratio via scaling)",
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.

The string needs to state the model

@timothy-nunn timothy-nunn self-assigned this Mar 24, 2026
Copy link
Copy Markdown
Collaborator

@timothy-nunn timothy-nunn left a comment

Choose a reason for hiding this comment

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

Thanks @chris-ashe for the review. @ajpearcey please fix the merge conflicts so that the CI can run and I can review any failures there

Copy link
Copy Markdown
Collaborator

@chris-ashe chris-ashe left a comment

Choose a reason for hiding this comment

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

@ajpearcey Can you please update the docs and add a reference in IEE format with a clickable DOI link

@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Apr 16, 2026

Codecov Report

❌ Patch coverage is 0% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 52.10%. Comparing base (25b9f07) to head (e09bb29).

Files with missing lines Patch % Lines
process/models/physics/plasma_geometry.py 0.00% 4 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4134      +/-   ##
==========================================
- Coverage   52.10%   52.10%   -0.01%     
==========================================
  Files         148      148              
  Lines       30389    30393       +4     
==========================================
  Hits        15835    15835              
- Misses      14554    14558       +4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Copy Markdown
Collaborator

@timothy-nunn timothy-nunn left a comment

Choose a reason for hiding this comment

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

Please talk to @chris-ashe about the enums. Happy otherwise once Chris approves!

Comment thread process/core/io/plot/scans.py Outdated
79: "eta_ecrh_injector_wall_plug",
80: "fcoolcp",
81: "n_tf_coil_turns",
82: "f_p_plasma_separatrix_rad", # really fradpwr
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.

Suggested change
82: "f_p_plasma_separatrix_rad", # really fradpwr
82: "f_p_plasma_separatrix_rad",

Comment thread process/data_structure/physics_variables.py

# ======================================================================

if physics_variables.i_plasma_geometry == 12:
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.

Then use the new enum here

physics_variables.kappa,
"OP ",
)
elif physics_variables.i_plasma_geometry == 12:
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.

And here

Comment thread process/core/io/plot/scans.py Outdated
79: "eta_ecrh_injector_wall_plug",
80: "fcoolcp",
81: "n_tf_coil_turns",
82: "f_p_plasma_separatrix_rad", # really fradpwr
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.

Suggested change
82: "f_p_plasma_separatrix_rad", # really fradpwr
82: "f_p_plasma_separatrix_rad",

Comment thread process/core/io/plot/scans.py Outdated
50: "f_nd_impurity_electrons(13)",
51: "f_p_div_lower",
52: "rad_fraction_sol",
53: "obsolete", # Removed
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.

Suggested change
53: "obsolete", # Removed
53: "Obsolete", # OBSOLETE

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.

4 participants