Bayeux
3.4.1
Core Foundation library for SuperNEMO
|
Regular circular placement. More...
#include <bayeux/geomtools/regular_circular_placement.h>
Public Member Functions | |
bool | is_valid () const |
void | invalidate () |
virtual size_t | get_dimension () const |
virtual bool | is_replica () const |
Check if the placement is a replica (GDML/Geant4 concept for multiple placement objects) More... | |
virtual bool | has_only_one_rotation () const |
Check if the placement is based on one unique rotation. More... | |
void | set_rotation_axis (rotation_axis_type) |
rotation_axis_type | get_rotation_axis () const |
bool | is_rotation_x_axis () const |
bool | is_rotation_y_axis () const |
bool | is_rotation_z_axis () const |
void | set_follow_rotation (bool) |
bool | is_follow_rotation () const |
void | set_radius (double radius_) |
double | get_radius () const |
void | set_start_angle (double angle_) |
double | get_start_angle () const |
void | set_step_angle (double angle_) |
double | get_step_angle () const |
void | set_center (const vector_3d &) |
const vector_3d & | get_center () const |
void | set_number_of_items (size_t n_) |
virtual size_t | get_number_of_items () const |
Return the number of placement items. More... | |
virtual void | get_placement (int item_, placement &p_) const |
Compute the placement at given item rank/index. More... | |
virtual size_t | compute_index_map (std::vector< uint32_t > &map_, int item_) const |
Compute an array of indexes in a multidimensional frame from the item rank/index. More... | |
regular_circular_placement () | |
Default constructor. More... | |
regular_circular_placement (const vector_3d ¢er_, double radius_, double step_angle_, double start_angle_, size_t number_of_items_, rotation_axis_type rotation_axis_=ROTATION_AXIS_Z) | |
Constructor. More... | |
virtual | ~regular_circular_placement () |
Destructor. More... | |
void | initialize (const vector_3d ¢er_, double radius_, double step_angle_, double start_angle_, size_t number_of_items_, rotation_axis_type rotation_axis_=ROTATION_AXIS_Z) |
Initialization. More... | |
virtual void | reset () |
Reset. More... | |
virtual void | tree_dump (std::ostream &out_=std::clog, const std::string &title_="geomutils::regular_circular_placement", const std::string &indent_="", bool inherit_=false) const |
Smart print. More... | |
Public Member Functions inherited from geomtools::i_placement | |
i_placement () | |
Default constructor. More... | |
virtual | ~i_placement () |
Destructor. More... | |
bool | is_multiple () const |
Check if the placement handles multiple positions. More... | |
placement | get_placement (int item_) const |
Return the placement at given item rank/index. More... | |
placement | get_placement_by_index (int item_) const |
Same as get_placement(int) but workaround method overloading for CAMP. More... | |
void | compute_placement (int item_, placement &p_) const |
Compute the placement at given item rank/index. More... | |
Public Member Functions inherited from datatools::i_serializable | |
i_serializable () | |
Default constructor. More... | |
virtual | ~i_serializable () |
Destructor. More... | |
virtual const std::string & | get_serial_tag () const =0 |
Return the serialization string identifier of the class. More... | |
Public Member Functions inherited from datatools::i_tree_dumpable | |
i_tree_dumpable () | |
Constructor. More... | |
virtual | ~i_tree_dumpable () |
Destructor. More... | |
virtual void | print_tree (std::ostream &out_=std::clog, const boost::property_tree::ptree &options_=empty_options()) const |
Main new interface method for printing. More... | |
void | print_tree_json (std::ostream &out_=std::clog, const std::string &json_options_="") const |
Printing with jsonized options. More... | |
void | print_tree_json (std::ostream &out_=std::clog, const char *json_options_=nullptr) const |
Printing with jsonized options. More... | |
void | tree_dump_id (const int out_type_=OSTREAM_CLOG, const std::string &title_="", const std::string &indent_="", const bool inherit_=false) const |
void | tree_print_id (const int out_type_=OSTREAM_CLOG, const std::string &title_="") const |
void | smart_print_id (const int out_type_=OSTREAM_CLOG, const std::string &title_="", const std::string &indent_="") const |
Protected Member Functions | |
void | _set_default () |
Set default: More... | |
Additional Inherited Members | |
Public Types inherited from datatools::i_tree_dumpable | |
enum | ostream_type { OSTREAM_COUT = 1, OSTREAM_CERR = 2, OSTREAM_CLOG = 3 } |
Enumeration for standard output streams. More... | |
Static Public Member Functions inherited from datatools::i_tree_dumpable | |
static const boost::property_tree::ptree & | empty_options () |
static boost::property_tree::ptree | make_base_print_options (const std::string &title_, const std::string &indent_="", const bool inherit_=false) |
static std::ostream & | last_skip_tag (std::ostream &out_) |
static std::ostream & | skip_tag (std::ostream &out_) |
static std::ostream & | last_tag (std::ostream &out_) |
static std::ostream & | tag (std::ostream &out_) |
Regular circular placement.
geomtools::regular_circular_placement::regular_circular_placement | ( | ) |
Default constructor.
geomtools::regular_circular_placement::regular_circular_placement | ( | const vector_3d & | center_, |
double | radius_, | ||
double | step_angle_, | ||
double | start_angle_, | ||
size_t | number_of_items_, | ||
rotation_axis_type | rotation_axis_ = ROTATION_AXIS_Z |
||
) |
Constructor.
|
virtual |
Destructor.
|
protected |
Set default:
|
virtual |
Compute an array of indexes in a multidimensional frame from the item rank/index.
Implements geomtools::i_placement.
const vector_3d& geomtools::regular_circular_placement::get_center | ( | ) | const |
|
virtual |
Return the dimension of the placement object
A single unique placement is of dimension 0 A multiple placement replicated along a given axis is of dimension 0 A multiple placement replicated along a 2D mesh addresses by X-Y grid coordinates is of dimension 2
Implements geomtools::i_placement.
|
virtual |
Return the number of placement items.
Implements geomtools::i_placement.
|
virtual |
Compute the placement at given item rank/index.
Implements geomtools::i_placement.
double geomtools::regular_circular_placement::get_radius | ( | ) | const |
rotation_axis_type geomtools::regular_circular_placement::get_rotation_axis | ( | ) | const |
double geomtools::regular_circular_placement::get_start_angle | ( | ) | const |
double geomtools::regular_circular_placement::get_step_angle | ( | ) | const |
|
virtual |
Check if the placement is based on one unique rotation.
Reimplemented from geomtools::i_placement.
void geomtools::regular_circular_placement::initialize | ( | const vector_3d & | center_, |
double | radius_, | ||
double | step_angle_, | ||
double | start_angle_, | ||
size_t | number_of_items_, | ||
rotation_axis_type | rotation_axis_ = ROTATION_AXIS_Z |
||
) |
Initialization.
void geomtools::regular_circular_placement::invalidate | ( | ) |
bool geomtools::regular_circular_placement::is_follow_rotation | ( | ) | const |
|
virtual |
Check if the placement is a replica (GDML/Geant4 concept for multiple placement objects)
Implements geomtools::i_placement.
bool geomtools::regular_circular_placement::is_rotation_x_axis | ( | ) | const |
bool geomtools::regular_circular_placement::is_rotation_y_axis | ( | ) | const |
bool geomtools::regular_circular_placement::is_rotation_z_axis | ( | ) | const |
bool geomtools::regular_circular_placement::is_valid | ( | ) | const |
|
virtual |
Reset.
void geomtools::regular_circular_placement::set_center | ( | const vector_3d & | ) |
void geomtools::regular_circular_placement::set_follow_rotation | ( | bool | ) |
void geomtools::regular_circular_placement::set_number_of_items | ( | size_t | n_ | ) |
void geomtools::regular_circular_placement::set_radius | ( | double | radius_ | ) |
void geomtools::regular_circular_placement::set_rotation_axis | ( | rotation_axis_type | ) |
void geomtools::regular_circular_placement::set_start_angle | ( | double | angle_ | ) |
void geomtools::regular_circular_placement::set_step_angle | ( | double | angle_ | ) |
|
virtual |
Smart print.
Reimplemented from geomtools::i_placement.