9 double x_part = node_1.
x - node_2.
x;
10 double y_part = node_1.
y - node_2.
y;
11 double z_part = node_1.
z - node_2.
z;
12 return std::sqrt(x_part * x_part + y_part * y_part + z_part * z_part);
17 std::vector<QuadraturePair> quad_pairs;
18 quad_pairs.reserve(angular_quadrature.
n_points());
19 for (
auto i = 0; i < angular_quadrature.
n_points(); i++)
25 const Node& node,
const int material_id,
const int source_id,
28 std::vector<double> source_fluxes;
29 source_fluxes.reserve(angular_quadrature.
n_points());
30 for (
auto n = 0; n < angular_quadrature.
n_points(); n++) {
31 double ind_source = source_bank.
GetByID(source_id)->EvaluateAtNode(
35 source_fluxes.push_back(inscattering + ind_source);
const T & GetByID(const int id) const
Get the object by its ID.
Bank holding the materials defined in the input file.
Base class for defining a quadrature set.
T GetAbscissa(const unsigned int index) const
Get the abscissa corresponding to the index.
size_t n_points() const
Get total number of abscissas.
double Integrate(const std::vector< QuadraturePair > &quad_pairs) const
Integrate the function using the function value and its location on the quadrature grid.
Bank holding the volumetric sources defined in the input file.
void UpdateScalarFlux(Node &node, const QuadratureBase< Ordinate > angular_quadrature)
Update the scalar flux of a node using the angular quadrature set.
std::vector< double > ComputeNodeSourceFluxes(const Node &node, const int material_id, const int source_id, const MaterialBank &material_bank, const SourceBank &source_bank, const QuadratureBase< Ordinate > &angular_quadrature)
Compute the node source flux values.
double DistanceBetweenNodes(const Node &node_1, const Node &node_2)
Compute the Euclidean distance between two nodes.
double scattering_xs
Isotropic scattering macroscopic cross section in 1/cm.
A point in the mesh holding its coordinates, boundary info, and flux solution values.
std::vector< double > angular_fluxes
Angular flux values in order of the SN quadrature set.
double x
X-coordinate of the node.
double scalar_flux
Scalar flux on the node.
double z
Z-coordinate of the node.
double y
Y-coordinate of the node.
Simple struct holding a function value evaluated at the supplied abscissa value.