9#define scint static_cast<int>
15 std::vector<double>& destination_phi,
16 std::vector<double>& destination_psi,
19 const std::vector<UnitCellMatrices>& unit_cell_matrices,
20 std::vector<lbs::CellLBSView>& cell_transport_views,
21 const std::vector<double>& source_moments,
23 const std::map<int, XSPtr>& xs,
25 int max_num_cell_dofs)
105 G_ = &fe_intgrl_values.G_matrix;
106 M_ = &fe_intgrl_values.M_matrix;
107 M_surf_ = &fe_intgrl_values.face_M_matrices;
124 const auto& face_orientations =
130 const std::vector<size_t>& as_angle_indices = angle_set.
GetAngleIndices();
131 const size_t as_num_angles = as_angle_indices.size();
132 for (
size_t as_ss_idx = 0; as_ss_idx < as_num_angles; ++as_ss_idx)
157 if (face_orientations[f] != FaceOrientation::INCOMING)
continue;
160 const bool boundary = not face.has_neighbor_;
190 if (face_orientations[f] != FaceOrientation::OUTGOING)
continue;
195 const bool boundary = not face.has_neighbor_;
215 size_t num_face_nodes,
216 uint64_t neighbor_id,
244 size_t num_face_nodes,
245 uint64_t neighbor_id,
285 const unsigned int adj_cell_node =
294 const unsigned int adj_face_node =
316 double* psi =
nullptr;
324 psi = &(*psi_dnwnd_data_)[addr_offset];
size_t NumFaceNodes(size_t face_index) const
const CellMapping & GetCellMapping(const chi_mesh::Cell &cell) const
std::vector< CellFace > faces_
LocalCellHandler local_cells
size_t GetNumGroups() const
std::map< uint64_t, SweepBndryPtr > & GetBoundaries()
size_t GetNumAngles() const
virtual const double * PsiBndry(uint64_t bndry_map, unsigned int angle_num, uint64_t cell_local_id, unsigned int face_num, unsigned int fi, int g, size_t gs_ss_begin, bool surface_source_active)=0
const std::vector< size_t > & GetAngleIndices() const
virtual AsynchronousCommunicator * GetCommunicator()
size_t GetRefGroupSubset() const
virtual double * ReflectingPsiOutBoundBndry(uint64_t bndry_map, unsigned int angle_num, uint64_t cell_local_id, unsigned int face_num, unsigned int fi, size_t gs_ss_begin)=0
const SPDS & GetSPDS() const
const FaceNodalMapping & GetFaceNodalMapping(uint64_t cell_local_id, unsigned int face_id) const
const std::vector< std::vector< FaceOrientation > > & CellFaceOrientations() const
bool IsSurfaceSourceActive() const
const double * GetLocalCellUpwindPsi(const std::vector< double > &psi_data_block, const chi_mesh::Cell &cell)
const std::vector< double > & GetNonLocalUpwindData(uint64_t cell_global_id, unsigned int face_id) const
const chi_mesh::sweep_management::FLUDSCommonData & CommonData() const
const std::vector< double > & GetLocalUpwindDataBlock() const
const double * GetNonLocalUpwindPsi(const std::vector< double > &psi_data, unsigned int face_node_mapped, unsigned int angle_set_index)
void SetAngleSet(chi_mesh::sweep_management::AngleSet &angle_set) override
chi_mesh::Cell const * cell_ptr_
void SetCells(const std::vector< const chi_mesh::Cell * > &cell_ptrs) override
CBC_SweepDependencyInterface & cbc_sweep_depinterf_
void Sweep(chi_mesh::sweep_management::AngleSet &angle_set) override
void SetCell(chi_mesh::Cell const *cell_ptr, chi_mesh::sweep_management::AngleSet &angle_set) override
std::vector< const chi_mesh::Cell * > cell_ptrs_
CBC_SweepChunk(std::vector< double > &destination_phi, std::vector< double > &destination_psi, const chi_mesh::MeshContinuum &grid, const chi_math::SpatialDiscretization &discretization, const std::vector< UnitCellMatrices > &unit_cell_matrices, std::vector< lbs::CellLBSView > &cell_transport_views, const std::vector< double > &source_moments, const LBSGroupset &groupset, const std::map< int, XSPtr > &xs, int num_moments, int max_num_cell_dofs)
int FaceLocality(int f) const
const chi_mesh::Cell * FaceNeighbor(int f) const
bool IsFaceLocal(int f) const
std::vector< chi::SubSetInfo > grp_subset_infos_
std::shared_ptr< chi_math::AngularQuadrature > quadrature_
std::vector< LBSGroup > groups_
std::vector< std::vector< double > > Atemp_
std::vector< CallbackFunction > surface_integral_kernels_
const std::vector< VecDbl > * IntS_shapeI_
std::vector< CallbackFunction > flux_update_kernels_
void KernelFEMSTDMassTerms()
void RegisterKernel(const std::string &name, CallbackFunction function)
double direction_qweight_
const std::vector< UnitCellMatrices > & unit_cell_matrices_
std::vector< double > face_mu_values_
const std::vector< MatDbl > * M_surf_
const std::map< int, XSPtr > & xs_
CellLBSView * cell_transport_view_
std::vector< CallbackFunction > mass_term_kernels_
const LBSGroupset & groupset_
std::vector< CallbackFunction > direction_data_callbacks_and_kernels_
const chi_math::SpatialDiscretization & grid_fe_view_
CallbackFunction Kernel(const std::string &name) const
SweepDependencyInterface & sweep_dependency_interface_
void KernelFEMVolumetricGradientTerm()
virtual void OutgoingSurfaceOperations()
static void ExecuteKernels(const std::vector< CallbackFunction > &kernels)
const chi_mesh::Cell * cell_
std::vector< std::vector< double > > b_
std::vector< CallbackFunction > post_cell_dir_sweep_callbacks_
std::vector< CallbackFunction > cell_data_callbacks_
const chi_mesh::MeshContinuum & grid_
void KernelFEMUpwindSurfaceIntegrals()
const chi_math::CellMapping * cell_mapping_
std::vector< lbs::CellLBSView > & grid_transport_view_
void GaussElimination(MatDbl &A, VecDbl &b, int n)
Vector3 Dot(const chi_mesh::TensorRank2Dim3 &that) const
const std::vector< short > face_node_mapping_
const std::vector< short > cell_node_mapping_
const int associated_face_
void SetupIncomingFace(int face_id, size_t num_face_nodes, uint64_t neighbor_id, bool on_local_face, bool on_boundary) override
std::vector< double > * psi_dnwnd_data_
void SetupOutgoingFace(int face_id, size_t num_face_nodes, uint64_t neighbor_id, bool on_local_face, bool on_boundary, int locality) override
size_t group_angle_stride_
const chi_mesh::sweep_management::FaceNodalMapping * face_nodal_mapping_
const std::vector< double > * psi_upwnd_data_block_
const chi_mesh::Cell * neighbor_cell_ptr_
const CellLBSView * cell_transport_view_
const double * psi_local_face_upwnd_data_
double * GetDownwindPsi(int face_node_local_idx) const override
const double * GetUpwindPsi(int face_node_local_idx) const override
bool surface_source_active_
bool is_reflecting_bndry_
virtual void SetupOutgoingFace(int face_id, size_t num_face_nodes, uint64_t neighbor_id, bool on_local_face, bool on_boundary, int locality)
size_t groupset_angle_group_stride_
size_t groupset_group_stride_
const chi_mesh::Cell * cell_ptr_
virtual void SetupIncomingFace(int face_id, size_t num_face_nodes, uint64_t neighbor_id, bool on_local_face, bool on_boundary)
chi_mesh::sweep_management::AngleSet * angle_set_