A monte carlo pin cell spectral code for nuclear engineering applications.
|
The Isotope represents a nuclide at some temperature. More...
#include "pinspec/src/Isotope.h"
Public Member Functions | |
Isotope (char *_isotope_name) | |
Isotope constructor. More... | |
virtual | ~Isotope () |
Isotope destructor deletes arrays of cross-section values that have been assigned to this isotope. | |
void | parseName (char *isotope_name) |
Parse input name and set atomic number for isotope. | |
void | makeFissionable () |
Inform isotope that it is fissionable. | |
char * | getIsotopeName () const |
Returns the name of the of isotope. More... | |
int | getUid () const |
Returns the unique ID auto-generated for the isotope. More... | |
int | getA () const |
Returns the atomic number of this isotope. More... | |
float | getAlpha () const |
Returns the alpha ![]() | |
float | getTemperature () const |
Return the temperature in degrees Kelvin for this isotope. More... | |
float | getMuAverage () const |
Return the average value of the cosine of the scattering angle. More... | |
bool | isFissionable () const |
Return whether this isotope is fissionable (true) or not (false) More... | |
float | getThermalScatteringCutoff () |
Return the thermal scattering high energy cutoff. More... | |
int | getNumXSEnergies (char *xs_type) const |
Returns the number of energies for a particular cross-section type. More... | |
float | getElasticXS (float energy) const |
Returns the microscopic elastic scattering cross-section value for some energy. More... | |
float | getElasticXS (int energy_index) const |
Returns the microscopic elastic cross-section value for a certain energy index in this isotope's rescaled uniform lethargy grid of cross-section data. More... | |
float | getAbsorptionXS (float energy) const |
Returns the microscopic absorption cross-section value for some energy. More... | |
float | getAbsorptionXS (int energy_index) const |
Returns the microscopic absorption cross-section value for a certain energy index in this isotope's rescaled uniform lethargy grid of cross-section data. More... | |
float | getCaptureXS (float energy) const |
Returns the microscopic capture cross-section value for some energy. More... | |
float | getCaptureXS (int energy_index) const |
Returns the microscopic capture cross-section value for a certain energy index in this isotope's rescaled uniform lethargy grid of cross-section data. More... | |
float | getFissionXS (float energy) const |
Returns the microscopic fission cross-section value for some energy. More... | |
float | getFissionXS (int energy_index) const |
Returns the microscopic fission cross-section value for a certain energy index in this isotope's rescaled uniform lethargy grid of cross-section data. More... | |
float | getTotalXS (float energy) const |
Returns the microscopic total cross-section value for some energy. More... | |
float | getTotalXS (int energy_index) const |
Returns the microscopic total cross-section value for a certain energy index in this isotope's rescaled uniform lethargy grid of cross-section data. More... | |
float | getTransportXS (int energy_index) const |
Returns the microscopic transport cross-section value for a certain energy index in this isotope's rescaled uniform lethargy grid of cross-section data. More... | |
float | getTransportXS (float energy) const |
Returns the microscopic transport cross-section value for some energy. More... | |
bool | usesThermalScattering () |
This method returns true if the thermal scattering distributions for this isotope are to be used when sampling outgoing collision energy. More... | |
bool | isRescaled () const |
This method returns whether or not the Isotope's cross-sections have been rescaled to a uniform lethargy grid. More... | |
int | getEnergyGridIndex (float energy) const |
This method returns the index for a certain energy (eV) into the Isotope's uniform lethargy grid. More... | |
void | retrieveXSEnergies (float *energies, int num_xs, char *xs_type) const |
Fills an array with cross-section energy values. More... | |
void | retrieveXS (float *xs, int num_xs, char *xs_type) const |
Fills an array with microscopic cross-section values. More... | |
void | setElasticXS (double *energies, int num_energies, double *elastic_xs, int num_xs) |
Sets the elastic cross-section data for this isotope. More... | |
void | setCaptureXS (double *energies, int num_energies, double *capture_xs, int num_xs) |
Sets the capture cross-section data for this isotope. More... | |
void | setFissionXS (double *energies, int num_energies, double *fission_xs, int num_xs) |
Sets the fission cross-section data for this isotope. More... | |
void | setMultigroupElasticXS (double *energies, int num_energies, double *elastic_xs, int num_xs) |
Sets the multigroup elastic cross-section data for this isotope. More... | |
void | setMultigroupCaptureXS (double *energies, int num_energies, double *capture_xs, int num_xs) |
Sets the multigroup capture cross-section data for this isotope. More... | |
void | setMultigroupFissionXS (double *energies, int num_energies, double *fission_xs, int num_xs) |
Sets the multigroup fission cross-section data for this isotope. More... | |
void | loadXS (char *xs_type) |
Load the ENDF cross-section data for a particular cross-section from an ASCII file into the appropriate array for this isotope. More... | |
void | setA (int A) |
Set the atomic number and update alpha, eta and rho. More... | |
void | setTemperature (float T) |
Set the temperature of the isotope in degrees Kelvin. More... | |
void | neglectThermalScattering () |
Informs isotope not to use thermal scattering to sample outgoing collision energies. | |
void | setThermalScatteringCutoff (float cutoff_energy) |
Sets the thermal scattering high energy cutoff energy. More... | |
void | useThermalScattering () |
Informs isotope to use thermal scattering to sample outgoing collision energies. | |
Isotope * | clone () |
This method clones a given Isotope class object by executing a deep copy of all of the Isotope's class attributes and giving them to a new Isotope class object. More... | |
void | sampleCollisionType (neutron *neutron) |
Determines a random collision type based on the values of each of the isotope's cross-section values at a given enery. More... | |
float | getDistanceTraveled (neutron *neutron) |
For a given neutron, this method samples a distance traveled to next collision. More... | |
void | collideNeutron (neutron *neutron) |
For a given energy, this method samples a collision type, updates the neutron's outgoing energy and kills the neutron if it sampled absorption or leakage. More... | |
float | getThermalScatteringEnergy (float energy) |
For a given neutron energy (eV) in a scattering collision, this function returns the outgoing energy in eV, ![]() | |
int | getNumThermalCDFs () |
Returns the number of thermal scattering CDFs. More... | |
int | getNumThermalCDFBins () |
Returns the number of energy bins for each thermal scattering CDF. More... | |
void | retrieveThermalCDFs (float *cdfs, int num_values) |
Loads an input array with the values for each of the isotope's thermal CDFs. More... | |
void | retrieveThermalPDFs (float *pdfs, int num_values) |
Loads an input array with the energies for each of the isotope's thermal PDFs. More... | |
void | retrieveEtokT (float *E_to_kT, int num_cdfs) |
Loads an input array with the ![]() | |
void | retrieveEprimeToE (float *Eprime_to_E, int num_bins) |
Loads an input array with the ![]() | |
Private Member Functions | |
void | loadXS () |
Load the ENDF cross-section data from ASCII files into arrays for this isotope. More... | |
void | setElasticXS (float *elastic_xs, float *elastic_xs_energies, int num_elastic_xs) |
Set the elastic cross-section for this isotope. More... | |
void | setCaptureXS (float *capture_xs, float *capture_xs_energies, int num_capture_xs) |
Set the capture cross-section for this isotope. More... | |
void | setFissionXS (float *fission_xs, float *fission_xs_energies, int num_fission_xs) |
Set the fission cross-section for this isotope. More... | |
void | rescaleXS (float start_energy, float end_energy, int num_energies) |
Rescales all of the isotope's cross-sections onto a uniform lethargy grid. More... | |
void | generateAbsorptionXS (float start_energy, float end_energy, int num_energies) |
Computes the microscopic absorption cross-section from the isotope's capture and fission (if applicable) cross-sections. More... | |
void | generateTotalXS (float start_energy, float end_energy, int num_energies) |
Computes the microscopic total cross-section from the isotope's capture, elastic scatter and fission (if applicable) cross-sections. More... | |
void | initializeThermalScattering (float start_energy, float end_energy, int num_bins, int num_distributions) |
This method initializes the probability distributions for thermal scattering. More... | |
float | thermalScatteringProb (float E_prime_to_E, int dist_index) |
This function computes the thermal scattering probability for a ratio of initial to final energies. More... | |
Private Attributes | |
char * | _isotope_name |
int | _uid |
int | _A |
int | _A_squared |
int | _A_plus_one_squared |
float | _alpha |
float | _eta |
float | _rho |
float | _AO |
float | _T |
float | _mu_avg |
bool | _fissionable |
bool | _rescaled |
int | _num_elastic_xs |
float * | _elastic_xs |
float * | _elastic_xs_energies |
bool | _elastic_rescaled |
int | _num_capture_xs |
float * | _capture_xs |
float * | _capture_xs_energies |
bool | _capture_rescaled |
int | _num_fission_xs |
float * | _fission_xs |
float * | _fission_xs_energies |
bool | _fission_rescaled |
int | _num_absorb_xs |
float * | _absorb_xs |
float * | _absorb_xs_energies |
int | _num_total_xs |
float * | _total_xs |
float * | _total_xs_energies |
int | _num_energies |
float | _start_lethargy |
float | _end_lethargy |
float | _delta_lethargy |
bool | _use_thermal_scattering |
float | _thermal_cutoff |
float | _kB |
int | _num_thermal_cdfs |
int | _num_thermal_cdf_bins |
float * | _thermal_dist |
float ** | _thermal_cdfs |
float * | _E_to_kT |
float * | _Eprime_to_E |
Static Private Attributes | |
static int | _n = 1 |
The Isotope represents a nuclide at some temperature.
The Isotope class represents a nuclide and all of its properties which are relevant to reactor physics calculations.
Isotope::Isotope | ( | char * | isotope_name | ) |
Isotope constructor.
Searches the cross-section library for appropriately named files using the isotope name and loads the capture, scatter, and fission (if file is found) cross-sectoins. By default, the constructor rescales the cross-sections onto a uniform lethargy grid of 100,000 values between 1E-5 eV and 20 MeV. In addition, the constructor creates thermal scattering CDFs for the isotope at 300K by default.
Isotope * Isotope::clone | ( | ) |
void Isotope::collideNeutron | ( | neutron * | neutron | ) |
For a given energy, this method samples a collision type, updates the neutron's outgoing energy and kills the neutron if it sampled absorption or leakage.
neutron | the neutron struct of interest |
|
private |
Computes the microscopic absorption cross-section from the isotope's capture and fission (if applicable) cross-sections.
This class method computes the absorption cross-section on a uniform lethargy grid.
start_energy | the highest lethargy value in the grid |
end_energy | the lowest lethargy value in the grid |
num_energies | the number of energies represented in the grid |
|
private |
Computes the microscopic total cross-section from the isotope's capture, elastic scatter and fission (if applicable) cross-sections.
This class method computes the total cross-section on a uniform lethargy grid.
start_energy | the highest lethargy value in the grid |
end_energy | the lowest lethargy value in the grid |
num_energies | the number of energies represented in the grid |
int Isotope::getA | ( | ) | const |
Returns the atomic number of this isotope.
float Isotope::getAbsorptionXS | ( | float | energy | ) | const |
Returns the microscopic absorption cross-section value for some energy.
Uses linear interpolation to compute the cross-section at a a certain energy (eV).
energy | the energy (eV) of interest |
float Isotope::getAbsorptionXS | ( | int | energy_index | ) | const |
Returns the microscopic absorption cross-section value for a certain energy index in this isotope's rescaled uniform lethargy grid of cross-section data.
energy_index | the index into the energy array |
float Isotope::getAlpha | ( | ) | const |
Returns the alpha values for this isotope.
float Isotope::getCaptureXS | ( | float | energy | ) | const |
Returns the microscopic capture cross-section value for some energy.
Uses linear interpolation to compute the cross-section at a a certain energy (eV).
energy | the energy (eV) of interest |
float Isotope::getCaptureXS | ( | int | energy_index | ) | const |
Returns the microscopic capture cross-section value for a certain energy index in this isotope's rescaled uniform lethargy grid of cross-section data.
energy_index | the index into the energy array |
float Isotope::getDistanceTraveled | ( | neutron * | neutron | ) |
For a given neutron, this method samples a distance traveled to next collision.
neutron | the neutron struct of interest |
float Isotope::getElasticXS | ( | float | energy | ) | const |
Returns the microscopic elastic scattering cross-section value for some energy.
Uses linear interpolation to compute the cross-section at a a certain energy (eV).
energy | the energy (eV) of interest |
float Isotope::getElasticXS | ( | int | energy_index | ) | const |
Returns the microscopic elastic cross-section value for a certain energy index in this isotope's rescaled uniform lethargy grid of cross-section data.
energy_index | the index into the energy array |
|
inline |
This method returns the index for a certain energy (eV) into the Isotope's uniform lethargy grid.
The index computed is that of nearest energy less than or equal to the input energy.
energy | the energy (eV) of interest |
float Isotope::getFissionXS | ( | float | energy | ) | const |
Returns the microscopic fission cross-section value for some energy.
Uses linear interpolation to compute the cross-section at a a certain energy (eV).
energy | the energy (eV) of interest |
float Isotope::getFissionXS | ( | int | energy_index | ) | const |
Returns the microscopic fission cross-section value for a certain energy index in this isotope's rescaled uniform lethargy grid of cross-section data.
energy_index | the index into the energy array |
char * Isotope::getIsotopeName | ( | ) | const |
Returns the name of the of isotope.
float Isotope::getMuAverage | ( | ) | const |
Return the average value of the cosine of the scattering angle.
Returns the average value of cosine of theta for this isotope in a scattering collision:
int Isotope::getNumThermalCDFBins | ( | ) |
Returns the number of energy bins for each thermal scattering CDF.
int Isotope::getNumThermalCDFs | ( | ) |
Returns the number of thermal scattering CDFs.
int Isotope::getNumXSEnergies | ( | char * | xs_type | ) | const |
Returns the number of energies for a particular cross-section type.
Returns the number of energies for 'capture', 'elastic', 'fission', 'fission' and 'absorption cross-section types.
xs_type | a character array for the xs_type |
float Isotope::getTemperature | ( | ) | const |
Return the temperature in degrees Kelvin for this isotope.
float Isotope::getThermalScatteringCutoff | ( | ) |
Return the thermal scattering high energy cutoff.
float Isotope::getThermalScatteringEnergy | ( | float | energy | ) |
For a given neutron energy (eV) in a scattering collision, this function returns the outgoing energy in eV, , for the collision based on its thermal scattering distributions.
energy | the energy of the neutron of interest (eV) |
float Isotope::getTotalXS | ( | float | energy | ) | const |
Returns the microscopic total cross-section value for some energy.
Uses linear interpolation to compute the cross-section at a a certain energy (eV).
energy | the energy (eV) of interest |
float Isotope::getTotalXS | ( | int | energy_index | ) | const |
Returns the microscopic total cross-section value for a certain energy index in this isotope's rescaled uniform lethargy grid of cross-section data.
energy_index | the index into the energy array |
float Isotope::getTransportXS | ( | int | energy_index | ) | const |
Returns the microscopic transport cross-section value for a certain energy index in this isotope's rescaled uniform lethargy grid of cross-section data.
The transport cross-section corrects for anisotropic scattering using a linear approximation and is computed as follows:
energy_index | the index into the energy array |
float Isotope::getTransportXS | ( | float | energy | ) | const |
Returns the microscopic transport cross-section value for some energy.
Uses linear interpolation to compute the cross-section at a a certain energy (eV). The transport cross-section corrects for anisotropic scattering and is computed as follows:
energy | the energy (eV) of interest |
int Isotope::getUid | ( | ) | const |
Returns the unique ID auto-generated for the isotope.
|
private |
This method initializes the probability distributions for thermal scattering.
It takes in arguments for the starting energy and end energy (ratios of kT) and the number of distributions which it uses to generate logarithmically spaced energies for the distributions.
start_energy | the first distribution's energy (ratio of kT) |
end_energy | the final distribution's energy (ratio of kT) |
num_bins | the number of bins per distribution |
num_distributions | the number of scattering distributions |
bool Isotope::isFissionable | ( | ) | const |
Return whether this isotope is fissionable (true) or not (false)
bool Isotope::isRescaled | ( | ) | const |
This method returns whether or not the Isotope's cross-sections have been rescaled to a uniform lethargy grid.
|
private |
Load the ENDF cross-section data from ASCII files into arrays for this isotope.
This method finds the appropriate ENDF data files for the isotope in the PINSPEC cross-section library based on the user-defined name of the isotope. If the appropriate files are not found the method will return an exception. If only capture and elastic scattering cross-section data files are discovered in the cross-section library then the isotope is not fissionable; otherwise if a fission cross-section file is found then the isotope is fissionable. Finally, after all cross-sections are parsed in from data files, this method computes a total cross-section and an absorption cross-section and then rescales all cross-sections onto a uniform lethargy grid to allow for fast O(1) data lookup.
void Isotope::loadXS | ( | char * | xs_type | ) |
Load the ENDF cross-section data for a particular cross-section from an ASCII file into the appropriate array for this isotope.
This method finds the appropriate ENDF data file for the isotope in the PINSPEC cross-section library based on the user-defined name of the isotope as well as the type of cross-section input ('capture' 'elastic', or 'fission'). If the appropriate file is not found the method will return an exception. Finally, after the cross-section is parsed in from the data file, this method recomputes a total cross-section and an absorption cross-section and then rescales all cross-sections onto a uniform lethargy grid to allow for fast O(1) data lookup.
xs_type | a character array for the cross-section type |
|
private |
Rescales all of the isotope's cross-sections onto a uniform lethargy grid.
Cross-section rescaling is useful because it allows for a fast O(1) table lookup (and linear interpolation) to compute cross-section values for any given energy.
start_energy | the highest lethargy value in the grid |
end_energy | the lowest lethargy value in the grid |
num_energies | the number of energies represented in the grid |
void Isotope::retrieveEprimeToE | ( | float * | Eprime_to_E, |
int | num_bins | ||
) |
Loads an input array with the values for each thermal scattering CDF.
This method is intended to make data available to the PINSPEC user in Python. Although this function appears to require two input arguments, in reality it only requires one argument for the array in Python. This method would be called in Python as follows:
Eprime_to_E | an array of ![]() |
num_bins | the number of bins per thermal scattering CDF |
void Isotope::retrieveEtokT | ( | float * | E_to_kT, |
int | num_cdfs | ||
) |
Loads an input array with the values for each thermal scattering CDF.
This method is intended to make data available to the PINSPEC user in Python. Although this function appears to require two input argument, in reality it only requires one argument for the array in Python. This method would be called in Python as follows:
E_to_kT | an array of ![]() |
num_cdfs | the number of thermal scattering CDFs |
void Isotope::retrieveThermalCDFs | ( | float * | cdfs, |
int | num_values | ||
) |
Loads an input array with the values for each of the isotope's thermal CDFs.
This method is intended to make the CDF data available to the PINSPEC user in Python. Although this function appears to require two input arguments - the cdfs array and the length of the array - in reality it only requires one argument for the array in Python. This method would be called in Python as follows:
cdfs | an input array for to fill with CDF values |
num_values | the number of CDF bins multiplied by the number of CDFs |
void Isotope::retrieveThermalPDFs | ( | float * | pdfs, |
int | num_values | ||
) |
Loads an input array with the energies for each of the isotope's thermal PDFs.
This method is intended to make the PDF data available to the PINSPEC user in Python. Although this function appears to require two input arguments - the PDFs array and the length of the array - in reality it only requires one argument for the array in Python. This method would be called in Python as follows:
pdfs | an input array for to fill with CDF values |
num_values | the number of CDF bins multiplied by the number of CDFs |
void Isotope::retrieveXS | ( | float * | xs, |
int | num_xs, | ||
char * | xs_type | ||
) | const |
Fills an array with microscopic cross-section values.
This method is a helper function to allow PINSPEC users to get access to the isotope's nuclear data in Python. A user must initialize a numpy array of the correct size (ie, a float64 array the length of the number of cross-section values) as input to this function. This function then fills the numpy array with the data values for one of the isotope's cross-sections. An example of how this function might be called in Python is as follows:
xs | an array to fill with the microscopic cross-section data |
num_xs | the number of cross-section values |
xs_type | the type of cross-section |
void Isotope::retrieveXSEnergies | ( | float * | energies, |
int | num_xs, | ||
char * | xs_type | ||
) | const |
Fills an array with cross-section energy values.
This method is a helper function to allow PINSPEC users to get access to the isotope's nuclear data in Python. A user must initialize a numpy array of the correct size (ie, a float64 array the length of the number of cross-section values) as input to this function. This function then fills the numpy array with the energy values for the isotope's cross-section data. An example of how this function might be called in Python is as follows:
energies | an array to fill with the cross-section energies |
num_xs | the number of cross-section values |
xs_type | the type of cross-section |
void Isotope::sampleCollisionType | ( | neutron * | neutron | ) |
Determines a random collision type based on the values of each of the isotope's cross-section values at a given enery.
neutron | a pointer to structure the of interest |
void Isotope::setA | ( | int | A | ) |
Set the atomic number and update alpha, eta and rho.
Computes alpha, eta, rho and mu as follows:
A | the isotope's atomic number |
|
private |
Set the capture cross-section for this isotope.
capture_xs | a float array of microscopic capture cross-sections |
capture_xs_energies | a float array of energies (eV) |
num_capture_xs | the number of capture cross-section |
void Isotope::setCaptureXS | ( | double * | energies, |
int | num_energies, | ||
double * | capture_xs, | ||
int | num_xs | ||
) |
Sets the capture cross-section data for this isotope.
This is a helper function for users to assign the cross-section data for an isotope from a numpy array in Python. Although the prototype for this function seems to require four arguments - two with arrays of data for energies and cross-sections and two for the length of each array - in Python one must only give the method a handle to each of two arrays. A user may call this method from within Python as follows:
energies | an array of energy values |
num_energies | the number of data points |
capture_xs | the microscopic elastic cross-section values |
num_xs | the number of cross-section values |
|
private |
Set the elastic cross-section for this isotope.
elastic_xs | a float array of microscopic elastic cross-sections |
elastic_xs_energies | a float array of energies (eV) |
num_elastic_xs | the number of elastic cross-section values |
void Isotope::setElasticXS | ( | double * | energies, |
int | num_energies, | ||
double * | elastic_xs, | ||
int | num_xs | ||
) |
Sets the elastic cross-section data for this isotope.
This is a helper function for users to assign the cross-section data for an isotope from a numpy array in Python. Although the prototype for this function seems to require four arguments - two with arrays of data for energies and cross-sections and two for the length of each array - in Python one must only give the method a handle to each of two arrays. A user may call this method from within Python as follows:
energies | an array of energy values |
num_energies | the number of data points |
elastic_xs | the microscopic elastic cross-section values |
num_xs | the number of cross-section values |
|
private |
Set the fission cross-section for this isotope.
fission_xs | a float array of microscopic fission cross-sections |
fission_xs_energies | a float array of energies (eV) |
num_fission_xs | the number of fission cross-sections values |
void Isotope::setFissionXS | ( | double * | energies, |
int | num_energies, | ||
double * | fission_xs, | ||
int | num_xs | ||
) |
Sets the fission cross-section data for this isotope.
This is a helper function for users to assign the cross-section data for an isotope from a numpy array in Python. Although the prototype for this function seems to require four arguments - two with arrays of data for energies and cross-sections and two for the length of each array - in Python one must only give the method a handle to each of two arrays. A user may call this method from within Python as follows:
energies | an array of energy values |
num_energies | the number of data points |
fission_xs | the microscopic fission cross-section values |
num_xs | the number of cross-section values |
void Isotope::setMultigroupCaptureXS | ( | double * | energies, |
int | num_energies, | ||
double * | capture_xs, | ||
int | num_xs | ||
) |
Sets the multigroup capture cross-section data for this isotope.
This is a helper function for users to assign the cross-section data for an isotope from a numpy array in Python. Although the prototype for this function seems to require four arguments - two with arrays of data for energies and cross-sections and two for the length of each array - in Python one must only give the method a handle to each of two arrays. A user may call this method from within Python as follows:
energies | an array of energy bounds |
num_energies | the number of energy bounds |
capture_xs | the microscopic capture multigroup cross-sections |
num_xs | the number of multigroup cross-sections |
void Isotope::setMultigroupElasticXS | ( | double * | energies, |
int | num_energies, | ||
double * | elastic_xs, | ||
int | num_xs | ||
) |
Sets the multigroup elastic cross-section data for this isotope.
This is a helper function for users to assign the cross-section data for an isotope from a numpy array in Python. Although the prototype for this function seems to require four arguments - two with arrays of data for energies and cross-sections and two for the length of each array - in Python one must only give the method a handle to each of two arrays. A user may call this method from within Python as follows:
energies | an array of energy bounds |
num_energies | the number of energy bounds |
elastic_xs | the microscopic elastic multigroup cross-sections |
num_xs | the number of multigroup cross-sections |
void Isotope::setMultigroupFissionXS | ( | double * | energies, |
int | num_energies, | ||
double * | fission_xs, | ||
int | num_xs | ||
) |
Sets the multigroup fission cross-section data for this isotope.
This is a helper function for users to assign the cross-section data for an isotope from a numpy array in Python. Although the prototype for this function seems to require four arguments - two with arrays of data for energies and cross-sections and two for the length of each array - in Python one must only give the method a handle to each of two arrays. A user may call this method from within Python as follows:
energies | an array of energy bounds |
num_energies | the number of energy bounds |
fission_xs | the microscopic fission multigroup cross-sections |
num_xs | the number of multigroup cross-sections |
void Isotope::setTemperature | ( | float | T | ) |
Set the temperature of the isotope in degrees Kelvin.
T | the temperature in degrees Kelvin |
void Isotope::setThermalScatteringCutoff | ( | float | cutoff_energy | ) |
Sets the thermal scattering high energy cutoff energy.
cutoff_energy | the thermal scattering high energy cutoff energy (eV) |
|
private |
This function computes the thermal scattering probability for a ratio of initial to final energies.
E_prime_to_E | a ratio of initial to final energies |
dist_index | the distribution of interest |
bool Isotope::usesThermalScattering | ( | ) |
This method returns true if the thermal scattering distributions for this isotope are to be used when sampling outgoing collision energy.
|
private |
Atomic number
|
private |
Atomic number plus one squared (an optimization for speeup):
|
private |
Atomic number squared (an optimization for speedup)
|
private |
Array of microscopic absorption cross-section values
|
private |
Array of absorption cross-section energies (eV)
|
private |
|
private |
Atomic number ratio
|
private |
Whether or not the capture cross-section is rescaled onto a uniform lethargy grid
|
private |
Array of microscopic capture cross-section values
|
private |
Array of capture cross-section energies (eV)
|
private |
Space between lethargies in uniform grid
|
private |
Array of the values for each PDF/CDF
|
private |
Whether or not the elastic scattering cross-section is rescaled onto a uniform lethargy grid
|
private |
Array of microscopic elastic scattering cross-section values
|
private |
Array of elastic scattering cross-section energies (eV)
|
private |
Final lethargy for uniform lethargy grid
|
private |
Array of for each PDF/CDF
|
private |
|
private |
Whether or not the fission cross-section is rescaled onto a uniform lethargy grid
|
private |
Array of microscopic fission cross-section values
|
private |
Array of fission cross-section energies (eV)
|
private |
Whether isotope is fissionable or not
|
private |
The name of the isotope-periodic table name followed by atomic number
|
private |
Boltzmann's constant
|
private |
The average cosine of the scattering angle:
|
staticprivate |
A static class variable to generate a UID for each new isotope
|
private |
The number of absorption cross-section data points
|
private |
The number of capture cross-section data points
|
private |
The number of elastic scattering cross-section data points
|
private |
Number of rescaled cross-section values on uniform lethargy grid
|
private |
The number of fission cross-section data points
|
private |
The number of bins per thermal scattering CDFs
|
private |
The number of thermal scattering CDFs
|
private |
The number of total cross-section data points
|
private |
Whether cross-sections are rescaled on uniform lethargy grid
|
private |
|
private |
Starting lethargy for uniform lethargy grid
|
private |
Temperature of the isotope in degrees Kelvin
|
private |
2D array of thermal scattering CDFs
|
private |
The high energy cutoff for the thermal scattering treatment (eV)
|
private |
The number of thermal scattering PDFs
|
private |
Array of microscopic total cross-section values
|
private |
Whether or not the total cross-section is rescaled onto a uniform lethargy grid
|
private |
The isotope's unique identifier
|
private |
Whether or not to use thermal scattering