mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 14:15:42 -04:00
Add accessors for Material.density_ and density_gpcc_
This commit is contained in:
parent
4815cfebac
commit
5d3afc1110
2 changed files with 9 additions and 1 deletions
|
|
@ -65,6 +65,14 @@ public:
|
|||
//! \param[in] density Density of the nuclide in [atom/b-cm]
|
||||
void add_nuclide(const std::string& nuclide, double density);
|
||||
|
||||
//! Get density in [atom/b-cm]
|
||||
//! \return Density in [atom/b-cm]
|
||||
double density() const { return density_; }
|
||||
|
||||
//! Get density in [g/cm^3]
|
||||
//! \return Density in [g/cm^3]
|
||||
double density_gpcc() const { return density_gpcc_; }
|
||||
|
||||
//! Set total density of the material
|
||||
int set_density(double density, std::string units);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue