Skip to content

Update first wall variables for clarity#3502

Merged
timothy-nunn merged 34 commits intomainfrom
update_blanket_variables_for_clarity
Feb 18, 2025
Merged

Update first wall variables for clarity#3502
timothy-nunn merged 34 commits intomainfrom
update_blanket_variables_for_clarity

Conversation

@chris-ashe
Copy link
Copy Markdown
Collaborator

@chris-ashe chris-ashe commented Jan 26, 2025

Description

Update the First Wall (FW) variables to be more verbose and meet the new style guide. This should make the code easier to understand.

  • New style guide unit for component lifetime with the life_ prefix.
  • New style guide unit for fluid viscosity with the visc_ prefix.

Namespace changes

Functions


Variables

  • afw -> radius_fw_channel
  • fw_wall -> dr_fw_wall
  • pitch -> dx_fw_module : Since this is the distance between adjacent FW cooling pipes or more simply the width of each seperate FW cooled segment the dx_ prefix has been used as the direction is not in a single dimension.
  • fwith -> dr_fw_inboard : Now more clearly shows that it is the radial thickness
  • fwoth -> dr_fw_outboard : Now more clearly shows that it is the radial thickness
  • 🔥 denw: Removed from fwbs_variables and added as new variable den_tungsten into constants.py
  • iblanket -> i_blanket_type: More explicitly shows that this is the type of blanket system chosen instead of possible being a switch for the presence of a blanket.
  • fwinlet -> temp_fw_coolant_in: Makes this more explicit that this is the coolant temperature instead of the FW structure
  • fwoutlet -> temp_fw_coolant_out: Makes this more explicit that this is the coolant temperature instead of the FW structure
  • fwpressure -> pres_fw_coolant: Makes this more explicit that this is the coolant pressure
  • fwareaib -> a_fw_inboard: Changed to meet new style guide
  • fwareaob -> a_fw_outboard: Changed to meet new style guide
  • fwarea -> a_fw_total: Changed to make it more explicit that it is the sum of the inboard and outboard FW areas.
  • volfw -> vol_fw_total: Changed to make it more explicit that it is the sum of the inboard and outboard FW volumes.
  • vffwo -> f_a_fw_coolant_outboard: Make it easier to show that this is the fraction of the FW cross-sectional area taken by the coolant pipes.
  • vffwi -> f_a_fw_coolant_inboard: Make it easier to show that this is the fraction of the FW cross-sectional area taken by the coolant pipes.
  • fwmass -> m_fw_total: Make it easier to show that this is the total mass of both first walls.
  • fwcoolant -> i_fw_coolant_type : Add switch i_ prefix and make it easier to discern if this is choosing the presence of a FW coolant or its type (incase an inertially cooled FW is a future option).
  • fwlife -> life_fw_fpy
  • pnucfw -> p_fw_nuclear_heat_total_mw
  • fw_channel_length -> len_fw_channel
  • tpeak -> temp_fw_peak
  • tfwmatmax -> temp_fw_max
  • rhof_fw -> den_fw_coolant
  • visc_fw -> visc_fw_coolant
  • peaking_factor -> f_fw_peak

✨ New additions

  • den_tungsten : Now added to constants.f90

🐛 Bugs

Checklist

I confirm that I have completed the following checks:

  • My changes follow the PROCESS style guide
  • I have justified any large differences in the regression tests caused by this pull request in the comments.
  • I have added new tests where appropriate for the changes I have made.
  • If I have had to change any existing unit or integration tests, I have justified this change in the pull request comments.
  • If I have made documentation changes, I have checked they render correctly.
  • I have added documentation for my change, if appropriate.

@chris-ashe chris-ashe self-assigned this Jan 26, 2025
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Jan 26, 2025

Codecov Report

❌ Patch coverage is 50.46729% with 53 lines in your changes missing coverage. Please review.
✅ Project coverage is 31.55%. Comparing base (7db8627) to head (724c025).
⚠️ Report is 479 commits behind head on main.

Files with missing lines Patch % Lines
process/stellarator.py 11.76% 15 Missing ⚠️
process/blanket_library.py 37.50% 10 Missing ⚠️
process/power.py 0.00% 8 Missing ⚠️
process/build.py 0.00% 6 Missing ⚠️
process/io/sankey_funcs.py 0.00% 4 Missing ⚠️
process/caller.py 0.00% 3 Missing ⚠️
process/output.py 0.00% 3 Missing ⚠️
process/costs.py 66.66% 1 Missing ⚠️
process/fw.py 95.45% 1 Missing ⚠️
process/hcpb.py 88.88% 1 Missing ⚠️
... and 1 more
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3502   +/-   ##
=======================================
  Coverage   31.55%   31.55%           
=======================================
  Files          82       82           
  Lines       19565    19565           
=======================================
  Hits         6173     6173           
  Misses      13392    13392           

☔ 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.

@chris-ashe chris-ashe force-pushed the update_blanket_variables_for_clarity branch from c630b67 to 6ea5011 Compare January 26, 2025 16:36
@chris-ashe chris-ashe changed the title Update blanket variables for clarity Update first wall variables for clarity Jan 26, 2025
@chris-ashe chris-ashe changed the title Update first wall variables for clarity 🚧 Update first wall variables for clarity Jan 26, 2025
@chris-ashe chris-ashe force-pushed the update_blanket_variables_for_clarity branch 2 times, most recently from a43a614 to e007996 Compare February 13, 2025 16:39
@chris-ashe chris-ashe force-pushed the update_blanket_variables_for_clarity branch from f78c311 to 20cba43 Compare February 17, 2025 11:12
@chris-ashe chris-ashe changed the title 🚧 Update first wall variables for clarity Update first wall variables for clarity Feb 17, 2025
@chris-ashe chris-ashe marked this pull request as ready for review February 17, 2025 11:13
@chris-ashe chris-ashe force-pushed the update_blanket_variables_for_clarity branch from b086d77 to 140fed0 Compare February 17, 2025 14:15
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.

Just one thing missing from the obsolete_variables I think

Comment thread process/io/obsolete_vars.py
@chris-ashe chris-ashe force-pushed the update_blanket_variables_for_clarity branch from 8aa4efe to 261c375 Compare February 18, 2025 09:53
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.

Happy with code and docs changes.

@chris-ashe chris-ashe force-pushed the update_blanket_variables_for_clarity branch 2 times, most recently from 26c592c to 9109f45 Compare February 18, 2025 13:18
@chris-ashe chris-ashe force-pushed the update_blanket_variables_for_clarity branch from 9109f45 to 724c025 Compare February 18, 2025 14:34
@timothy-nunn timothy-nunn merged commit b7aefc2 into main Feb 18, 2025
@timothy-nunn timothy-nunn deleted the update_blanket_variables_for_clarity branch February 18, 2025 15:26
@OceanNuclear
Copy link
Copy Markdown
Contributor

(Typo on iblanket? (iblnaket))

@chris-ashe
Copy link
Copy Markdown
Collaborator Author

(Typo on iblanket? (iblnaket))

Yes, small typo. Have corrected

ajpearcey pushed a commit that referenced this pull request Feb 26, 2025
* ❇️ Create new den_tungsten variable in constants and implement to replace denw in fwbs variables

* 🔥 Remove `denw` variable and its references for tungsten density from the codebase

* 🔄 Rename `iblanket` to `i_blanket_type` for consistency across multiple files

* 🔄 Rename `fwinlet` to `temp_fw_coolant_in` for clarity and consistency across the codebase

* 🔄 Rename `fwoutlet` to `temp_fw_coolant_out` for clarity and consistency across the codebase

* 🔄 Rename `fwpressure` to `pres_fw_coolant` for clarity and consistency across the codebase

* 🔄 Rename `fwareaib` to `a_fw_inboard` for clarity and consistency across the codebase

* 🔄 Rename `fwareaob` to `a_fw_outboard` for clarity and consistency across the codebase

* 🔄 Rename `fwarea` to `a_fw_total` for clarity and consistency across the codebase

* 🔄 Rename `volfw` to `vol_fw_total` for clarity and consistency across the codebase

* 🔄 Rename `vffwo` to `f_a_fw_coolant_outboard` for clarity and consistency across the codebase

* 🔄 Rename `vffwi` to `f_a_fw_coolant_inboard` for clarity and consistency across the codebase

* 🔄 Rename `fwmass` to `m_fw_total` for clarity and consistency across the codebase

* 🔄 Rename `fwcoolant` to `i_fw_coolant_type` for clarity and consistency across the codebase

* 🔄 Rename `afw` to `radius_fw_channel` for clarity and consistency across the codebase

* 🔄 Rename `fw_wall` to `dr_fw_wall` for clarity and consistency across the codebase

* 🔄 Rename `pitch` to `dx_fw_module` for clarity and consistency across the codebase

* 🔄 Update description of `dx_fw_module` for clarity and consistency across the codebase

* 🔄 Refactor `fw_temp` method parameters and variable names for clarity and consistency

* Fix unit tests

* 📝 Update documentation to include standards for component lifetimes and naming conventions

* 🔄 Rename `fwlife` to `life_fw_fpy` for clarity and consistency across the codebase

* 🔄 Rename `pnucfw` to `p_fw_nuclear_mw` for clarity and consistency across the codebase

* 🔄 Rename `fw_channel_length` to `len_fw_channel` for clarity and consistency across the codebase

* 🔄 Rename `tpeak` to `temp_fw_peak` for clarity and consistency across the codebase

* 🔄 Rename `tfwmatmax` to `temp_fw_max` for clarity and consistency across the codebase

* 🔄 Rename `rhof_fw` to `den_fw_coolant` for clarity and consistency across the codebase

* 📝 Update documentation to include standards for viscosity variable naming

* 🔄 Rename `visc_fw` to `visc_fw_coolant` for clarity and consistency across the codebase

* 🔄 Rename `peaking_factor` to `f_fw_peak` for clarity and consistency across the codebase

* 🔄 Rename obsolete variables for clarity and consistency across the codebase

* 🔄 Rename p_fw_nuclear_mw to p_fw_nuclear_heat_total_mw for clarity and consistency across the codebase

* 🔄 Add obsolete variable 'denw' to OBS_VARS for clarity and consistency across the codebase

* Update ST tests
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants