Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #4095 +/- ##
=======================================
Coverage 46.86% 46.87%
=======================================
Files 136 136
Lines 29228 29227 -1
=======================================
+ Hits 13698 13699 +1
+ Misses 15530 15528 -2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
timothy-nunn
left a comment
There was a problem hiding this comment.
Can you move the outputting of pflux_fw_rad_mw, pflux_fw_neutron_mw, and p_fw_alpha_mw from physics to the first wall.
…iables and update references
…remove redundant logic from Physics class
ab1af9c to
8711d26
Compare
Have added a new output for surface loads in |
| # ============================== | ||
|
|
||
| # First wall power fluxes | ||
|
|
||
| # ============================== |
There was a problem hiding this comment.
| # ============================== | |
| # First wall power fluxes | |
| # ============================== |
We are trying to rid PROCESS of comment blocks like this
| physics_variables.pflux_fw_neutron_mw = ( | ||
| physics_variables.p_neutron_total_mw / first_wall_variables.a_fw_total | ||
| ) |
There was a problem hiding this comment.
Before there was an if statement for the number of divertors, why has this changed?
PROCESS/process/models/physics/physics.py
Lines 2284 to 2312 in 73e929a
| physics_variables.pflux_fw_rad_mw = ( | ||
| physics_variables.p_plasma_rad_mw / build_variables.a_fw_total | ||
| ) |
There was a problem hiding this comment.
Again, no if for the different divertor configurations, why?
Before:
PROCESS/process/models/physics/physics.py
Lines 2591 to 2628 in 73e929a
| constraint_variables.pflux_fw_rad_max_mw = ( | ||
| physics_variables.pflux_fw_rad_mw * constraint_variables.f_fw_rad_max | ||
| ) |
There was a problem hiding this comment.
Are these two really constraint_variables or can they be moved into the first wall data structure?
This pull request primarily fixes a variable naming typo (
plfux_plasma_surface_neutron_avg_mw→pflux_plasma_surface_neutron_avg_mw) throughout the codebase, and refactors the calculation and assignment of first wall neutron and photon power fluxes. The logic for these calculations is moved out ofphysics.pyand consolidated withinfw.py, simplifying and centralizing the power flux computations. Additionally, related output and plotting code is updated to use the corrected variable name.Refactor and relocation of first wall power flux calculations:
pflux_fw_neutron_mwandpflux_fw_rad_mwfromphysics.pytofw.py, consolidating the logic and simplifying the code structure. The new implementation uses a more unified approach for both neutron and photon wall loads, removing configuration-specific branches fromphysics.py.✅ - Within
fw.py🟥 - In
physics.pywith redundant calculation already done byapply_first_wall_coverage_factors()Variable name correction and consistency:
plfux_plasma_surface_neutron_avg_mwtopflux_plasma_surface_neutron_avg_mwacross all relevant files and function signatures, including initialization and output routines.Output and plotting updates:
Code cleanup:
physics.pyand updated import statements to reflect the new locations of relevant calculations.These changes improve code clarity, maintainability, and correctness regarding the calculation and reporting of first wall neutron and photon fluxes.## Description
Checklist
I confirm that I have completed the following checks: