26int main(
int argc,
char**argv)
37 JParser<> zap(
"Example program to test rotations in 3D.");
46 catch(
const exception &error) {
47 FATAL(error.what() << endl);
50 gRandom->SetSeed(seed);
61 for (
int i = 0; i != numberOfEvents; ++i) {
63 STATUS(
"event: " << setw(10) << i <<
'\r');
DEBUG(endl);
65 const double theta = gRandom->Uniform(0.0, PI);
66 const double phi = gRandom->Uniform(0.0, 2*PI);
88 for (
int j = 0; j !=
sizeof(v)/
sizeof(v[0]); ++j) {
100 Q.
put((B - A).getLength());
102 if ((B - A).getLengthSquared() > precision*precision) {
104 DEBUG(
"theta " << theta << endl);
105 DEBUG(
"phi " << phi << endl);
110 DEBUG(
"R " << endl << R);
112 ERROR(
"A " <<
FIXED(7,3) << A.getX() <<
' ' << A.getY() <<
' ' << A.getZ() << endl);
113 ERROR(
"B " <<
FIXED(7,3) << B.getX() <<
' ' << B.getY() <<
' ' << B.getZ() << endl);
int main(int argc, char **argv)
General purpose messaging.
#define DEBUG(A)
Message macros.
Utility class to parse command line options.
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
I/O formatting auxiliaries.
Data structure for angles in three dimensions.
Data structure for position in three dimensions.
Data structure for unit quaternion in three dimensions.
Data structure for vector in three dimensions.
Utility class to parse command line options.
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
Auxiliary data structure for floating point format specification.
This class represents a rotation around the x-axis.
This class represents a rotation around the y-axis.
This class represents a rotation around the z-axis.