9 #define MAX_DOUBLE DBL_MAX
12 #include "CLHEP/Units/GlobalSystemOfUnits.h"
13 #include <Math/RotationZ.h>
30 rangeAngle_( 360.*deg ),
34 DCOUT(
'A',
"Creating angular label=" << label);
77 " n=" <<
n_ <<
" delta=" <<
delta_/deg);
81 sz_type sz =
ParE_[
"rotateSolid"].size();
85 err_ +=
"\trotateSolid must occur 3*n times (defining n subsequent rotations)\n";
86 err_ +=
"\t currently it appears " +
d2s(sz) +
" times!\n";
89 for (sz_type
i=0;
i<sz; ++
i) {
92 for (sz_type
i=0;
i<sz;
i += 3 ) {
94 err_ +=
"\trotateSolid \'theta\' must be in range [0,180*deg]\n";
96 +
"*deg in rotateSolid[" +
d2s(
double(
i)) +
"]!\n";
101 DCOUT(
'a',
" rotsolid[" << i <<
"] axis=" << temp.Axis() <<
" rot.angle=" << temp.Angle()/deg);
108 sz =
ParE_[
"rotate"].size();
112 err_ +=
"\trotate must occur 3*n times (defining n subsequent rotations)\n";
113 err_ +=
"\t currently it appears " +
d2s(sz) +
" times!\n";
116 for (sz_type
i=0;
i<sz; ++
i) {
119 for (sz_type
i=0;
i<sz;
i += 3 ) {
121 err_ +=
"\trotate \'theta\' must be in range [0,180*deg]\n";
123 +
"*deg in rotate[" +
d2s(
double(
i)) +
"]!\n";
128 DCOUT(
'a',
" rotsolid[" << i <<
"] axis=" << temp.Axis() <<
" rot.angle=" << temp.Angle()/deg);
137 if (
ParS_[
"alignSolid"][0] !=
"T") {
138 DCOUT(
'a',
" alignSolid = false");
162 DCOUT(
'A',
" angle=" << angle/deg <<
" translation=" << v <<
" count_=" <<
count_);
174 ROOT::Math::RotationZ
r2(angle);
208 os <<
"global_angular_0::stream(): not implemented.";
void checkTermination()
for algorithms with incr_==0 the algorithm must check whether to terminate
DDRotationMatrix planeRot_
class for algorithmic positioning, represents an algorithm
Sin< T >::type sin(const T &t)
Geom::Theta< T > theta() const
std::vector< double > rotateSolid_
constraints as defined for algorithm-parameters in the XML schema Algorithm.xsd, strings ...
constraints as defined for algorithm-parameters in the XML schema Algorithm.xsd, expressions ...
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< double > > DDTranslation
virtual int copyno() const
copy-number calculation
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< double > > DD3Vector
A DD Translation is currently implemented with Root Vector3D.
DDTranslation translation()
subclass must calculate a translation std::vector
Cos< T >::type cos(const T &t)
implementation of an algorithm, non generated checking code.
int copyno() const
copy-number calculation
constraintsS_type constraintsS_
format: "ParameterName" -> ConstraintS
DD3Vector fUnitVector(double theta, double phi)
static std::string d2s(double x)
ahh, converts a double into a std::string ... yet another one of this kind!
std::vector< double > rotate_
constraintsE_type constraintsE_
format: "ParameterName" -> ConstraintE
std::vector< double > center_
global_angular_0(AlgoPos *, std::string label)
void stream(std::ostream &) const
DDRotationMatrix rotation()
subclass must calculate a rotation matrix
DDRotationMatrix solidRot_
ROOT::Math::AxisAngle DDAxisAngle
ROOT::Math::Rotation3D DDRotationMatrix
A DDRotationMatrix is currently implemented with a ROOT Rotation3D.
#define DCOUT(M_v_Y, M_v_S)
bool checkParameters()
subclass must check the supplied parameters ParE_, ParS_
void terminate()
stop the current iteration of the algorithm (for incr_==0 types of algorithms)
T angle(T x1, T y1, T z1, T x2, T y2, T z2)