Go to the documentation of this file.    1 #ifndef __JMATHTOOLKIT__ 
    2 #define __JMATHTOOLKIT__ 
   28 namespace JPP { 
using namespace JMATH; }
 
   61   inline long long int factorial(
const long long int n, 
const long long int m)
 
   63     if (
n < 0 || m < 0 || 
n < m) {
 
   84   template<
class JFirst_t, 
class JSecond_t>
 
   85   inline bool equals(
const JFirst_t&  first,
 
   86                      const JSecond_t& second,
 
   87                      const double     precision = std::numeric_limits<double>::min())
 
   89     return first.equals(second, precision);
 
  100   template<
class JFirst_t, 
class JSecond_t>
 
  102                                    const JSecond_t& second)
 
  104     return first.getDistanceSquared(second);    
 
  115   template<
class JFirst_t, 
class JSecond_t>
 
  117                             const JSecond_t& second)
 
  119     return first.getDistance(second);
 
  130   template<
class JFirst_t, 
class JSecond_t>
 
  131   inline double getDot(
const JFirst_t&  first,
 
  132                        const JSecond_t& second)
 
  134     return first.getDot(second);
 
  145   template<
class JFirst_t, 
class JSecond_t>
 
  147                          const JSecond_t& second)
 
  149     const double dot = 
getDot(first,second);
 
  153     else if (dot <= -1.0)
 
  156       return acos(dot) * 180.0 / acos(-1.0);
 
  167   template<
class JFirst_t, 
class JSecond_t>
 
  169                            const JSecond_t& second)
 
  171     return first.getPerpDot(second);
 
  189     return T(first).interpolate(second, alpha);
 
 
T interpolate(const T &first, const T &second, const double alpha)
Interpolation between objects.
 
bool equals(const JFirst_t &first, const JSecond_t &second, const double precision=std::numeric_limits< double >::min())
Check equality.
 
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
 
double getPerpDot(const JFirst_t &first, const JSecond_t &second)
Get perpendicular dot product of objects.
 
#define THROW(JException_t, A)
Marco for throwing exception with std::ostream compatible message.
 
double getDistance(const JFirst_t &first, const JSecond_t &second)
Get distance between objects.
 
Exception for accessing a value in a collection that is outside of its range.
 
Auxiliary classes and methods for mathematical operations.
 
long long int factorial(const long long int n, const long long int m)
Determine combinatorics.
 
double getAngle(const JFirst_t &first, const JSecond_t &second)
Get space angle between objects.
 
double getDot(const JFirst_t &first, const JSecond_t &second)
Get dot product of objects.
 
double getDistanceSquared(const JFirst_t &first, const JSecond_t &second)
Get square of distance between objects.