Repository navigation
Add all ion rad contributions - #4684
Conversation
2939375 to
4312540
Compare
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #4684 +/- ##
==========================================
- Coverage 50.26% 50.26% -0.01%
==========================================
Files 181 181
Lines 30513 30627 +114
==========================================
+ Hits 15338 15395 +57
- Misses 15175 15232 +57 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
…ting and visual styling
grmtrkngtn
left a comment
There was a problem hiding this comment.
Since calculate_species_radiation_powers() independently recalculates the species radiation at output rather than decomposing a quantity already calculated by the main physics model, could we add a test demonstrating that the summed species contributions reproduce the existing PROCESS radiation power to numerical tolerance?
…actions for ions and impurities
grmtrkngtn
left a comment
There was a problem hiding this comment.
Modelling changes look good - this is a useful addition to output.
This pull request introduces detailed tracking, calculation, and visualization of plasma radiation power contributions from individual ion species and synchrotron radiation. The changes enhance both the data structure and output reporting, and add a new plot summarizing these contributions. Below are the most important changes grouped by theme:
Data Structure Enhancements:
PhysicsDatafor storing the radiation power (in MW) contributed by each supported ion species (e.g., hydrogen, helium, beryllium, etc.), as well as impurity (Z>2) and synchrotron radiation fractions. This allows for fine-grained analysis and output of plasma radiation sources. [1] [2]Computation and Output of Species Radiation Power:
calculate_species_radiation_powersin theImpurityRadiationmodel to compute and store the volume-averaged and total radiation power for each species, and aggregate impurity contributions.output_species_radiation_power_densityand updatedoutplasin the main physics model to output the specific radiation power of each ion species, as well as the impurity and synchrotron fractions, to the results file. [1] [2]Visualization Improvements:
plot_radiation_power_contributions, to generate a horizontal bar chart summarizing the contributions of synchrotron and each ion species to the total plasma radiation power, including percentage annotations and a legend.Internal Consistency and Infrastructure:
SPECIES_POWER_ATTRIBUTES, to map species labels to their corresponding attribute names, ensuring consistency between calculation and output.Checklist
I confirm that I have completed the following checks: