Analysis Software
Documentation for sPHENIX simulation software
|
#include <JETSCAPE/blob/main/external_packages/cornelius.h>
Public Member Functions | |
Polyhedron () | |
~Polyhedron () | |
void | init () |
bool | add_polygon (Polygon *, int) |
Polyhedron () | |
~Polyhedron () | |
void | init () |
bool | add_polygon (Polygon *, int) |
Polyhedron () | |
~Polyhedron () | |
void | init () |
bool | add_polygon (Polygon *, int) |
Polyhedron () | |
~Polyhedron () | |
void | init () |
bool | add_polygon (Polygon *, int) |
Public Member Functions inherited from GeneralElement | |
GeneralElement () | |
~GeneralElement () | |
double * | get_centroid () |
double * | get_normal () |
GeneralElement () | |
~GeneralElement () | |
double * | get_centroid () |
double * | get_normal () |
GeneralElement () | |
~GeneralElement () | |
double * | get_centroid () |
double * | get_normal () |
GeneralElement () | |
~GeneralElement () | |
double * | get_centroid () |
double * | get_normal () |
Private Member Functions | |
bool | lines_equal (Line *, Line *) |
void | tetravolume (double *, double *, double *, double *) |
void | calculate_centroid () |
void | calculate_normal () |
bool | lines_equal (Line *, Line *) |
void | tetravolume (double *, double *, double *, double *) |
void | calculate_centroid () |
void | calculate_normal () |
bool | lines_equal (Line *, Line *) |
void | tetravolume (double *, double *, double *, double *) |
void | calculate_centroid () |
void | calculate_normal () |
bool | lines_equal (Line *, Line *) |
void | tetravolume (double *, double *, double *, double *) |
void | calculate_centroid () |
void | calculate_normal () |
Private Attributes | |
Polygon ** | polygons |
int | Npolygons |
int | Ntetrahedra |
int | x1 |
int | x2 |
int | x3 |
int | x4 |
Static Private Attributes | |
static const int | MAX_POLYGONS = 24 |
Additional Inherited Members | |
Protected Member Functions inherited from GeneralElement | |
void | check_normal_direction (double *normal, double *out) |
void | check_normal_direction (double *normal, double *out) |
void | check_normal_direction (double *normal, double *out) |
void | check_normal_direction (double *normal, double *out) |
Protected Attributes inherited from GeneralElement | |
double * | centroid |
double * | normal |
int | normal_calculated |
int | centroid_calculated |
Static Protected Attributes inherited from GeneralElement | |
static const int | DIM = 4 |
A class for storing polyhedrons given by Cornelius. Can calculate the normal and centroid of the polyhedron.
Definition at line 669 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 669 of file cornelius.cpp
Polyhedron::Polyhedron | ( | ) |
Allocates memory for a list pointers to the polygons which form the polyhedron.
Definition at line 694 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 694 of file cornelius.cpp
Polyhedron::~Polyhedron | ( | ) |
Frees memory allocated at the constructor.
Definition at line 705 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 705 of file cornelius.cpp
Polyhedron::Polyhedron | ( | ) |
Polyhedron::~Polyhedron | ( | ) |
Polyhedron::Polyhedron | ( | ) |
Polyhedron::~Polyhedron | ( | ) |
Polyhedron::Polyhedron | ( | ) |
Polyhedron::~Polyhedron | ( | ) |
bool Polyhedron::add_polygon | ( | Polygon * | , |
int | |||
) |
bool Polyhedron::add_polygon | ( | Polygon * | , |
int | |||
) |
bool Polyhedron::add_polygon | ( | Polygon * | , |
int | |||
) |
bool Polyhedron::add_polygon | ( | Polygon * | p, |
int | donocheck | ||
) |
Adds a polygon to the polyhedron. Also possible to check if the new polygon is connected with previous polygons and only make the addition if this is the case.
[in] | p | Polygon which is tried to add to polyhedron |
[in] | donotcheck | 1 if no check is needed, 0 otherwise |
Definition at line 743 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 743 of file cornelius.cpp
References Polygon::get_lines(), Polygon::get_Nlines(), i, j, k, and merge_hashes::p.
|
privatevirtual |
Reimplemented from GeneralElement.
|
privatevirtual |
Reimplemented from GeneralElement.
|
privatevirtual |
This determines the centroid (center of mass) of the polyhedron.
Reimplemented from GeneralElement.
Definition at line 842 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 842 of file cornelius.cpp
References KFPMath::a, KFPMath::b, Acts::PhysicalConstants::c, double(), Line::get_end(), Line::get_start(), i, j, k, test_fpe::lines, mean(), and n.
|
privatevirtual |
Reimplemented from GeneralElement.
|
privatevirtual |
Reimplemented from GeneralElement.
|
privatevirtual |
Reimplemented from GeneralElement.
|
privatevirtual |
Reimplemented from GeneralElement.
|
privatevirtual |
Determines the normal vector for polygon. Makes sure that it points in the outward direction.
Reimplemented from GeneralElement.
Definition at line 928 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 928 of file cornelius.cpp
References KFPMath::a, KFPMath::b, Acts::PhysicalConstants::c, Line::get_end(), Line::get_out(), Line::get_start(), i, j, k, and test_fpe::lines.
void Polyhedron::init | ( | ) |
void Polyhedron::init | ( | ) |
void Polyhedron::init | ( | ) |
void Polyhedron::init | ( | void | ) |
This initializes the polygon. Can be used several times.
Definition at line 715 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 715 of file cornelius.cpp
Checks if two lines are connected.
Definition at line 786 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 786 of file cornelius.cpp
References Acts::UnitConstants::e, eps, Line::get_end(), Line::get_start(), and i.
Calculates the normal vector for tetrahedra, which also tells the volume of the tetrahedra.
[in] | a | Vector that spans the tetrahedra |
[in] | b | Vector that spans the tetrahedra |
[in] | c | Vector that spans the tetrahedra |
[out] | n | Normal vector for tetrahedra |
Definition at line 815 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 815 of file cornelius.cpp
|
staticprivate |
Definition at line 672 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 672 of file cornelius.cpp
|
private |
Definition at line 674 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 674 of file cornelius.cpp
|
private |
Definition at line 675 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 675 of file cornelius.cpp
|
private |
Definition at line 673 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 673 of file cornelius.cpp
|
private |
Definition at line 676 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 676 of file cornelius.cpp
|
private |
Definition at line 676 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 676 of file cornelius.cpp
|
private |
Definition at line 676 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 676 of file cornelius.cpp
|
private |
Definition at line 676 of file cornelius.cpp.
View newest version in sPHENIX GitHub at line 676 of file cornelius.cpp