9 #include "TMatrixDSymEigen.h"
25 namespace JGEOMETRY3D {}
26 namespace JPP {
using namespace JGEOMETRY3D; }
28 namespace JGEOMETRY3D {
34 public std::map<double, JVector3D, std::greater<double> >
54 for (
T i = __begin; i != __end; ++i) {
56 const double dx = center.
getX() - i->getX();
57 const double dy = center.
getY() - i->getY();
58 const double dz = center.
getZ() - i->getZ();
74 const TMatrixDSymEigen
result(A);
76 const TVectorD&
u = result.GetEigenValues();
77 const TMatrixD& V = result.GetEigenVectors();
79 for (Int_t i = 0; i != u.GetNoElements(); ++i) {
125 for (
T i = __begin; i != __end; ++i) {
150 const TMatrixDSymEigen
result(
A);
152 const TVectorD&
u = result.GetEigenValues();
153 const TMatrixD& V = result.GetEigenVectors();
155 if (u.GetNoElements() != 0 && fabs(u[0]) > MINIMAL_EIGEN_VALUE) {
159 if (Q.
getA() < 0.0) {
187 a(3,0) =
a(0,3);
a(3,1) =
a(1,3);
a(3,2) =
a(2,3);
a(3,3) = Q.
getD()*Q.
getD();
229 this->
set(xmin, xmax);
241 const double z = this->getX(x);
244 for (
size_t n = 0;
n != this->size(); ++
n) {
282 this->
set(xmin, xmax);
301 this->
set(__begin, __end);
319 this->
set(__begin, __end, __end);
340 static const double factor = 1.0 / (
PI * 45.0 / 180.0);
342 for (
size_t n = 0;
n !=
N + 1; ++
n) {
346 this->xmin = std::numeric_limits<double>::max();
347 this->xmax = std::numeric_limits<double>::lowest();
349 for (
T i = __begin; i != __end; ++i) {
351 if (i->first < this->xmin) { this->xmin = i->first; }
352 if (i->first > this->xmax) { this->xmax = i->first; }
356 for (
size_t n = 0;
n !=
N + 1; ++
n) {
360 for (
T i = __begin; i != __end; ++i) {
363 const double x = i->first;
365 const double z = this->getX(x);
376 (*this)[
n].pow(factor);
391 for (
typename JLegendre::iterator i =
object.begin(); i !=
object.end(); ++i) {
JQuaternion3D & pow(const double y)
Raise quaternion to given power.
virtual JQuaternion3D getValue(const double x) const override
Function value.
double getValue(const JScale_t scale)
Get numerical value corresponding to scale.
double getB() const
Get b value.
void set(T __begin, T __end)
Set Legendre polynome of quaternions.
JLegendre()
Default constructor.
JLegendre(const double xmin, const double xmax)
Constructor.
friend std::istream & operator>>(std::istream &in, JLegendre &object)
Read Legendre polynome from input.
JLegendre(const double xmin, const double xmax)
Constructor.
static const JZero zero
Function object to assign zero value.
Template spacialisation for averaging quaternions.
void put(const JValue_t &value, const double w=1.0)
Put value.
void set(T __begin, T __not, T __end)
Set Legendre polynome of quaternions.
JAverage(T __begin, T __end)
Constructor.
Data structure for vector in three dimensions.
do set_variable OUTPUT_DIRECTORY $WORKDIR T
Template definition for function evaluation of Legendre polynome.
JLegendre(T __begin, T __end)
Constructor.
T pow(const T &x, const double y)
Power .
static const double PI
Mathematical constants.
double getY() const
Get y position.
JAverage()
Default constructor.
double legendre(const unsigned int n, const double x)
Legendre polynome.
double getD() const
Get d value.
Data structure for unit quaternion in three dimensions.
void put(const JQuaternion3D &Q, const double w=1.0)
Put quaternion.
Exception for division by zero.
JLegendre()
Default constructor.
alias put_queue eval echo n
double getC() const
Get c value.
double getX() const
Get x position.
Base class for data structures with artithmetic capabilities.
double getA() const
Get a value.
static double MINIMAL_EIGEN_VALUE
Numerical precision for eigen value evaluation.
JQuaternion3D & normalise()
Normalise quaternion.
void set(T __begin, T __end)
Set Legendre polynome.
then fatal Wrong number of arguments fi set_variable DETECTOR $argv[1] set_variable INPUT_FILE $argv[2] eval JPrintDetector a $DETECTOR O IDENTIFIER eval JPrintDetector a $DETECTOR O SUMMARY source JAcoustics sh $DETECTOR_ID typeset A TRIPODS get_tripods $WORKDIR tripod txt TRIPODS for EMITTER in
JEigenValues3D(T __begin, T __end)
Constructor.
Base class for Legendre polynome.
then usage $script[input file[working directory[option]]] nWhere option can be N
JQuaternion3D & negate()
Negate quaternion.
double getZ() const
Get z position.
source $JPP_DIR setenv csh $JPP_DIR eval JShellParser o a A
Auxiliary class to determine average of set of values.