A monte carlo pin cell spectral code for nuclear engineering applications.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros
EquivalenceRegion Class Reference

The Equivalence Region is a fuel or moderator region treated using the heterogenous-homogeneous equivalence theory. More...

#include "pinspec/src/Region.h"

Inheritance diagram for EquivalenceRegion:
Region EquivalenceFuelRegion EquivalenceModeratorRegion

Public Member Functions

 EquivalenceRegion (const char *region_name=(char *)"")
 EquivalenceRegion constructor. More...
 
virtual ~EquivalenceRegion ()
 Empty destructor allows SWIG to cleanup memory for surfaces.
 
float getFuelPinRadius ()
 Returns the fuel pin radius. More...
 
float getPinCellPitch ()
 Returns the pin cell pitch. More...
 
int getEnergyGridIndex (float lethargy)
 This method returns the index for a certain lethargy (log10(eV)) into the uniform lethargy grid of the region's first flight collision probabilies. More...
 
bool isFuel ()
 Returns true if this region is the fuel, false otherwise. More...
 
bool isModerator ()
 Returns true if this region is the moderator, false otherwise. More...
 
void setFirstFlightCollProb (float *prob_ff, float *prob_mf, float *prob_energies, int num_prob)
 Sets the first flight collision probabilities. More...
 
void setOtherRegion (EquivalenceRegion *region)
 Sets other region for a homogeneous equivalence region. More...
 
void setFuelPinRadius (float radius)
 Sets the fuel radius if the region. More...
 
void setPinCellPitch (float pitch)
 Sets the pin cell pitch. More...
 
float computeFuelFuelCollsionProb (neutron *neutron)
 Finds the first flight fuel-to-fuel collision probability for a neutron. More...
 
float computeModeratorFuelCollisionProb (neutron *neutron)
 Finds the first flight moderator-to-fuel collision probability for a neutron. More...
 
void collideNeutron (neutron *neutron)
 This method collides a neutron within the region. More...
 
- Public Member Functions inherited from Region
 Region (const char *region_name=(char *)"")
 Region constructor. More...
 
virtual ~Region ()
 Empty destructor allows SWIG to cleanup memory for surfaces. More...
 
char * getName ()
 Return the name of the region. More...
 
int getUid () const
 Returns the unique ID auto-generated for the region. More...
 
MaterialgetMaterial ()
 Returns a pointer to the material filling this region. More...
 
bool containsIsotope (Isotope *isotope)
 Determines whether this region contains a particular isotope. More...
 
regionType getRegionType ()
 Return the type of region. More...
 
float getVolume ()
 returns the volume of this Region $ (cm^3) $. More...
 
float getBucklingSquared ()
 Returns the squared geometric buckling. More...
 
float getTotalMacroXS (float energy)
 Computes and returns the total macroscopic cross-section in the region at some energy (eV). More...
 
float getTotalMacroXS (int energy_index)
 Computes and returns the total macroscopic cross-section in the region at some index into the uniform lethargy grid. More...
 
float getTotalMicroXS (float energy)
 Computes and returns the total microscopic cross-section in the region at some energy (eV). More...
 
float getTotalMicroXS (int energy_index)
 Computes and returns the total microscopic cross-section in the region at some index into the uniform lethargy grid. More...
 
float getElasticMacroXS (float energy)
 Computes and returns the macroscopic elastic scattering cross-section in the region at some energy (eV). More...
 
float getElasticMacroXS (int energy_index)
 Computes and returns the macroscopic elastic scattering cross-section in the region at some index into the uniform lethargy grid. More...
 
float getElasticMicroXS (float energy)
 Computes and returns the microscopic elastic scattering cross-section in the region at some energy (eV). More...
 
float getElasticMicroXS (int energy_index)
 Computes and returns the microscopic elastic scattering cross-section in the region at some index into the uniform lethargy grid. More...
 
float getAbsorptionMacroXS (float energy)
 Computes and returns the macroscopic absorption cross-section in the region at energy (eV). More...
 
float getAbsorptionMacroXS (int energy_index)
 Computes and returns the macroscopic absorption cross-section in the region at some index into the uniform lethargy grid. More...
 
float getAbsorptionMicroXS (float energy)
 Computes and returns the microscopic absorption cross-section in the region at some energy (eV). More...
 
float getAbsorptionMicroXS (int energy_index)
 Computes and returns the microscopic absorption cross-section in the region at some index into the uniform lethargy grid. More...
 
float getCaptureMacroXS (float energy)
 Computes and returns the macroscopic capture cross-section in the region at some energy (eV). More...
 
float getCaptureMacroXS (int energy_index)
 Computes and returns the macroscopic capture cross-section in the region at some index into the uniform lethargy grid. More...
 
float getCaptureMicroXS (float energy)
 Computes and returns the microscopic capture cross-section in the region at some energy (eV). More...
 
float getCaptureMicroXS (int energy_index)
 Computes and returns the microscopic capture cross-section in the region at some index into the uniform lethargy grid. More...
 
float getFissionMacroXS (float energy)
 Computes and returns the macroscopic fission cross-section in the region at some energy (eV). More...
 
float getFissionMacroXS (int energy_index)
 Computes and returns the macroscopic fission cross-section in the region at some index into the uniform lethargy grid. More...
 
float getFissionMicroXS (float energy)
 Computes and returns the microscopic fission cross-section in the region at some energy (eV) More...
 
float getFissionMicroXS (int energy_index)
 Computes and returns the microscopic fission cross-section in the region at some index into the uniform lethargy grid. More...
 
float getTransportMicroXS (float energy)
 Computes and returns the microscopic transport cross-section in the region at some index into the uniform lethargy grid. More...
 
float getTransportMicroXS (int energy_index)
 Computes and returns the microscopic transport cross-section in the region at some index into the uniform lethargy grid. More...
 
float getTransportMacroXS (float energy)
 Computes and returns the macroscopic transport cross-section in the region at some index into the uniform lethargy grid. More...
 
float getTransportMacroXS (int energy_index)
 Computes and returns the macroscopic transport cross-section in the region at some index into the uniform lethargy grid. More...
 
void setMaterial (Material *material)
 Set the material filling this region. More...
 
void setVolume (float volume)
 Sets the volume for this region $ (cm^3) $. More...
 
void setBucklingSquared (float buckling_squared)
 Sets the squared geometric buckling for the geometry. More...
 

Private Attributes

float _fuel_radius
 
float _pitch
 
float _half_width
 
EquivalenceRegion_other_region
 
float * _prob_ff
 
float * _prob_mf
 
float * _prob_energies
 
int _num_prob
 
float _start_lethargy
 
float _end_lethargy
 
float _delta_lethargy
 

Additional Inherited Members

- Protected Attributes inherited from Region
char * _region_name
 
int _uid
 
Material_material
 
regionType _region_type
 
float _buckling_squared
 
float _volume
 
- Static Protected Attributes inherited from Region
static int _n = 1
 

Detailed Description

The Equivalence Region is a fuel or moderator region treated using the heterogenous-homogeneous equivalence theory.

In particular, this class uses Carlvik's Rational Approximation for first flight collision probabilities. This heterogeneous - homogeneous approximation allows this class to treat a heterogeneous pin cell simply as a homogeneous fuel and homogeneous moderator regions with probabilities for a particle to travel from one region to another at a given energy. This avoids the need for explicit ray tracing of particle trajectories across the geometry.

Constructor & Destructor Documentation

EquivalenceRegion::EquivalenceRegion ( const char *  region_name = (char*)"")

EquivalenceRegion constructor.

Sets defaults for the geometric parameters: fuel radius (0.45 cm), pitch (1.26 cm).

Parameters
region_namethe name of the region

Member Function Documentation

void EquivalenceRegion::collideNeutron ( neutron neutron)
virtual

This method collides a neutron within the region.

This method encapsulates all of the neutron scattering physics which is further encapsulated by the material and isotope classes.

Parameters
neutronthe neutron of interest

Implements Region.

float EquivalenceRegion::computeFuelFuelCollsionProb ( neutron neutron)

Finds the first flight fuel-to-fuel collision probability for a neutron.

Uses linear interpolation to compute the first flight fuel-to-fuel collision probabilty at a neutron's energy using the region's first flight collision probability table.

Parameters
neutronthe neutron of interest
Returns
the first flight fuel-to-fuel collision probability
float EquivalenceRegion::computeModeratorFuelCollisionProb ( neutron neutron)

Finds the first flight moderator-to-fuel collision probability for a neutron.

Uses linear interpolation to compute the first flight moderator-to-fuel collision probabilty at a neutron's energy using the region's first flight collision probability table.

Parameters
neutronthe neutron of interest
Returns
the first flight moderator-to-fuel collision probability
int EquivalenceRegion::getEnergyGridIndex ( float  lethargy)

This method returns the index for a certain lethargy (log10(eV)) into the uniform lethargy grid of the region's first flight collision probabilies.

The index is for the closest lethargy which is greater than or equal to the input lethargy.

Parameters
lethargythe lethargy (log10(eV)) of interest
Returns
the index into the uniform lethargy grid
float EquivalenceRegion::getFuelPinRadius ( )

Returns the fuel pin radius.

Returns
the fuel pin radius
float EquivalenceRegion::getPinCellPitch ( )

Returns the pin cell pitch.

Returns
the pin cell pitch
bool EquivalenceRegion::isFuel ( )

Returns true if this region is the fuel, false otherwise.

Returns
true if fuel, false otherwise
bool EquivalenceRegion::isModerator ( )

Returns true if this region is the moderator, false otherwise.

Returns
true if moderator, false otherwise
void EquivalenceRegion::setFirstFlightCollProb ( float *  prob_ff,
float *  prob_mf,
float *  prob_energies,
int  num_prob 
)

Sets the first flight collision probabilities.

Sets the first flight collision (fuel-to-fuel and moderator-to-fuel) at each of the energies for which the isotope cross-sections are defined on a uniform lethargy grid. The first flight collison probabilities are computed by the geometry and set at the beginning of each PINSPEC simulation.

Parameters
prob_ffan array of fuel-to-fuel collision probabilities
prob_mfan array of moderator-to-fuel collision probabilities
prob_energiesan array of energies for which the first flight collision probabilities are defined
num_probthe number of first flight collision probabilities
void EquivalenceRegion::setFuelPinRadius ( float  radius)

Sets the fuel radius if the region.

Parameters
radiusthe fuel pin radius (cm)
void EquivalenceRegion::setOtherRegion ( EquivalenceRegion region)

Sets other region for a homogeneous equivalence region.

If this region is an EQUIVALENT_FUEL region, the other region must be EQUIVALENT_MODERATOR region type. If this region is an EQUIVALENT_MODERATOR region, the other region must be EQUIVALENT_FUEL region type.

Parameters
regionthe other region
void EquivalenceRegion::setPinCellPitch ( float  pitch)

Sets the pin cell pitch.

Parameters
pitchthe pin cell pitch (cm)

Member Data Documentation

float EquivalenceRegion::_delta_lethargy
private

Space between lethargy for the first flight collision probabilities

float EquivalenceRegion::_end_lethargy
private

Highest lethargy for the first flight collision probabilities

float EquivalenceRegion::_fuel_radius
private

The radius of the fuel

float EquivalenceRegion::_half_width
private

Half of the pin cell pitch

int EquivalenceRegion::_num_prob
private

The number of first flight collision probabilities

EquivalenceRegion* EquivalenceRegion::_other_region
private

The other region (ie, if this region is an EQUIVALENT_FUEL type region, the other region is EQUIVALENT_MODERATOR)

float EquivalenceRegion::_pitch
private

The pin cell pitch

float* EquivalenceRegion::_prob_energies
private

Energies (eV) for first flight collision probabilities

float* EquivalenceRegion::_prob_ff
private

First flight fuel-to-fuel collision probabilities

float* EquivalenceRegion::_prob_mf
private

First flight fuel-to-fuel collision probabilities

float EquivalenceRegion::_start_lethargy
private

Lowest lethargy for the first flight collision probabilities


The documentation for this class was generated from the following files: