Adding CAD cell class and constructor.

This commit is contained in:
shriwise 2018-02-22 22:01:34 -06:00 committed by pshriwise
parent 85722f5e5f
commit dcf3eb84ee
3 changed files with 18 additions and 3 deletions

View file

@ -111,7 +111,10 @@ public:
explicit Cell(pugi::xml_node cell_node);
//! \brief Determine if a cell contains the particle at a given location.
explicit Cell();
//! \brief Determine if a cell contains the particle at a given location.
//! Determine if a cell contains the particle at a given location.
//!
//! The bounds of the cell are detemined by a logical expression involving
//! surface half-spaces. At initialization, the expression was converted
@ -146,5 +149,11 @@ protected:
bool contains_complex(Position r, Direction u, int32_t on_surface) const;
};
class CADCell : public Cell
{
explicit CADCell();
};
} // namespace openmc
#endif // OPENMC_CELL_H

View file

@ -209,6 +209,8 @@ Universe::to_hdf5(hid_t universes_group) const
// Cell implementation
//==============================================================================
Cell::Cell() {} // empty constructor
Cell::Cell(pugi::xml_node cell_node)
{
if (check_for_node(cell_node, "id")) {
@ -586,9 +588,13 @@ Cell::contains_complex(Position r, Direction u, int32_t on_surface) const
}
//==============================================================================
// Non-method functions
// CAD Cell implementation
//==============================================================================
CADCell::CADCell() : Cell{} {};
//==============================================================================
// Non-method functions
extern "C" void
read_cells(pugi::xml_node* node)
{

View file

@ -138,7 +138,7 @@ void read_coeffs(pugi::xml_node surf_node, int surf_id, double &c1, double &c2,
// Surface implementation
//==============================================================================
Surface::Surface() {}
Surface::Surface() {} // empty constructor
Surface::Surface(pugi::xml_node surf_node)
{