mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 21:55:41 -04:00
Using a common count_sites implementation.
This commit is contained in:
parent
cf55d15a7d
commit
36e99d70fb
2 changed files with 59 additions and 0 deletions
|
|
@ -83,6 +83,12 @@ public:
|
|||
//! \param[in] group HDF5 group
|
||||
virtual void to_hdf5(hid_t group) const = 0;
|
||||
|
||||
//! \param[in] bank Array of bank sites
|
||||
//! \param[out] Whether any bank sites are outside the mesh
|
||||
//! \return Array indicating number of sites in each mesh/energy bin
|
||||
virtual xt::xarray<double>
|
||||
count_sites(const std::vector<Particle::Bank>& bank, bool* outside) const;
|
||||
|
||||
//! Find the mesh lines that intersect an axis-aligned slice plot
|
||||
//
|
||||
//! \param[in] plot_ll The lower-left coordinates of the slice plot.
|
||||
|
|
@ -404,7 +410,59 @@ private:
|
|||
std::pair<moab::Tag, moab::Tag>
|
||||
get_score_tags(std::string score) const;
|
||||
|
||||
<<<<<<< HEAD
|
||||
// data members
|
||||
=======
|
||||
public:
|
||||
|
||||
std::pair<std::vector<double>, std::vector<double>>
|
||||
plot(Position plot_ll, Position plot_ur) const override;
|
||||
|
||||
//! Determine which surface bins were crossed by a particle.
|
||||
//
|
||||
//! \param[in] p Particle to check
|
||||
//! \param[out] bins Surface bins that were crossed
|
||||
void surface_bins_crossed(const Particle* p, std::vector<int>& bins) const;
|
||||
|
||||
//! Write mesh data to an HDF5 group.
|
||||
//
|
||||
//! \param[in] group HDF5 group
|
||||
void to_hdf5(hid_t group) const;
|
||||
|
||||
//! Get bin at a given position.
|
||||
//
|
||||
//! \param[in] r Position to get bin for
|
||||
//! \return Mesh bin
|
||||
int get_bin(Position r) const;
|
||||
|
||||
std::string get_label_for_bin(int bin) const;
|
||||
|
||||
int n_bins() const override;
|
||||
|
||||
int n_surface_bins() const override;
|
||||
|
||||
Position centroid(moab::EntityHandle tet) const;
|
||||
|
||||
std::string bin_label(int bin) const override;
|
||||
|
||||
//! Add a score to the mesh instance
|
||||
void add_score(std::string score) const;
|
||||
|
||||
//! Set data for a score
|
||||
void set_score_data(const std::string& score,
|
||||
std::vector<double> values,
|
||||
std::vector<double> std_dev) const;
|
||||
|
||||
//! Write the mesh with any current tally data
|
||||
void write(std::string base_filename) const;
|
||||
std::string filename_; //<! Path to unstructured mesh file
|
||||
|
||||
std::string get_label_for_bin(int bin) const;
|
||||
|
||||
double get_volume_frac(int bin = -1) const;
|
||||
|
||||
private:
|
||||
>>>>>>> Using a common count_sites implementation.
|
||||
moab::Range ehs_; //!< Range of tetrahedra EntityHandle's in the mesh
|
||||
moab::EntityHandle tetset_; //!< EntitySet containing all tetrahedra
|
||||
moab::EntityHandle kdtree_root_; //!< Root of the MOAB KDTree
|
||||
|
|
|
|||
|
|
@ -2021,6 +2021,7 @@ UnstructuredMesh::count_sites(const std::vector<Particle::Bank>& bank,
|
|||
}
|
||||
|
||||
double UnstructuredMesh::get_volume_frac(int bin = -1) const {
|
||||
|
||||
return 0.0;
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue