Skip to content

Commit

Permalink
Merge pull request #40 from fusion-energy/fixing_mising_nuclide_bug
Browse files Browse the repository at this point in the history
adding nuc_with_data to allow all nuclides
  • Loading branch information
shimwell committed May 3, 2023
2 parents ff159c3 + 99eea9d commit 5623170
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/openmc_depletion_plotter/results.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@
import numpy as np
import matplotlib.pyplot as plt

lots_of_nuclides = []
elements = list(openmc.data.ATOMIC_SYMBOL.values())
for el in elements:
for atomic_num in range(1, 1000):
lots_of_nuclides.append(f'{el}{atomic_num}')


def plot_activity_vs_time(
self,
Expand All @@ -37,7 +43,7 @@ def plot_activity_vs_time(

all_materials = []
for counter, step in enumerate(time_steps):
materials = self.export_to_materials(burnup_index=counter, path=path)[
materials = self.export_to_materials(nuc_with_data=lots_of_nuclides,burnup_index=counter, path=path)[
material_index
]
all_materials.append(materials)
Expand Down Expand Up @@ -165,7 +171,7 @@ def plot_atoms_vs_time(

all_materials = []
for counter, step in enumerate(time_steps):
materials = self.export_to_materials(burnup_index=counter, path=path)[
materials = self.export_to_materials(nuc_with_data=lots_of_nuclides,burnup_index=counter, path=path)[
material_index
]
all_materials.append(materials)
Expand Down

0 comments on commit 5623170

Please sign in to comment.