<jupyter_start><jupyter_text>Depletion and ConversionA key feature of reactor physics is the depletion of fuel and buildup of other fission products.  Learning Objectives- Describe the relationship between reactivity loss and fuel burnup.- Calculate changes in core power distribution with fuel depletion.- Calculate the need for core reloading based on fuel burnup.- Recognize the relationship between reactivity control and core power distribution.- Calculate depletion of both fuel isotopes and burnable poisons.- Quantify the conversion of uranium into plutonium.- Identify the physical meaning of the capture cross section.- Evaluate the evolution of fuel composition throughout the lifetime of a reactor.- Analyze the energy produced during the cycle based on core power, reactivity control, and depletion.  Fuel DepletionDecays, fissions, and absorptions compete throughout the life of the reactor.![./fuel_comp.png](./fuel_comp.png) DecayRecall decay.$$\begin{align}        \frac{dN}{dt} &= -\lambda N \\       \Rightarrow N_i(t) &= N_i(0)e^{-\lambda t}\\\end{align}$$where$$\begin{align}        N_i(t) &= \mbox{number of isotopes i adjusted for decay}\\        N_i(0)&= \mbox{initial condition}\\        \lambda &= \frac{ln(2)}{t_{1/2}} = \mbox{decay constant} \\        t &= \mbox{time elapsed [s]}\\        t_{1/2} &= 1 = \mbox{half-life [s]} \\\end{align}$$<jupyter_code>import math
def n_decay(t, n_initial=100, half_life=1):
    """This function describes the decay of an isotope"""
    lam = math.log(2)/half_life
    return n_initial*math.exp(-lam*t)


# This code plots the decay of an isotope
import numpy as np
y = np.arange(24)
x = np.arange(24)
for t in range(0,24):
    x[t] = t
    y[t] = n_decay(t)
    
# creates a figure and axes with matplotlib
fig, ax = plt.subplots()
scatter = plt.scatter(x, y, color='blue', s=y*20, alpha=0.4)    
ax.plot(x, y, color='red')    

# adds labels to the plot
ax.set_ylabel('N_i(t)')
ax.set_xlabel('Time')
ax.set_title('N_i')

# adds tooltips
import mpld3
labels = ['{0}% remaining'.format(i) for i in y]
tooltip = mpld3.plugins.PointLabelTooltip(scatter, labels=labels)
mpld3.plugins.connect(fig, tooltip)

mpld3.display()<jupyter_output>/home/huff/anaconda3/lib/python3.5/site-packages/IPython/core/formatters.py:92: DeprecationWarning: DisplayFormatter._ipython_display_formatter_default is deprecated: use @default decorator instead.
  def _ipython_display_formatter_default(self):
/home/huff/anaconda3/lib/python3.5/site-packages/IPython/core/formatters.py:669: DeprecationWarning: PlainTextFormatter._singleton_printers_default is deprecated: use @default decorator instead.
  def _singleton_printers_default(self):
{'fraction_non_alphanumeric': 0.11637448713166729, 'fraction_numerical': 0.014919806042521447, 'mean_word_length': 4.529896907216495, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '46840', 'license': 'CC-BY-4.0', 'n_tokens_mistral': 888, 'n_tokens_neox': 836, 'n_words': 262, 'path': 'reactor-physics/depletion.ipynb', 'repo_name': 'loumis2/Atomicaristides', 'size': '2681'}