13 const size_t ncells = grid.local_cells.size();
17 for (
const auto& cell : grid.local_cells)
19 const auto& cell_mapping = sdm.GetCellMapping(cell);
20 const auto qp_data = cell_mapping.MakeVolumetricQuadraturePointData();
21 const size_t num_nodes = cell_mapping.NumNodes();
23 VF_[counter].resize(num_nodes, 0.0);
25 for (
size_t i=0; i < num_nodes; ++i)
27 double vol_frac_shape_i = 0.0;
28 for (
size_t qp : qp_data.QuadraturePointIndices())
29 vol_frac_shape_i += qp_data.ShapeValue(i, qp) * qp_data.JxW(qp);
30 vol_frac_shape_i /= cell_mapping.CellVolume();
31 VF_[counter][i] = vol_frac_shape_i;
std::vector< std::vector< double > > VF_
void Compute_TwoGrid_VolumeFractions()
chi_mesh::MeshContinuumPtr grid_ptr_
chi_math::SDMPtr sdm_ptr_