Jpp test-rotations-new
the software that should make you happy
Loading...
Searching...
No Matches
JMATH::JMath_t Struct Reference

Auxiliary class to hide data type specific methods. More...

#include <JMath.hh>

Static Private Member Functions

template<class T >
static T pow (const T &x, const double y, const JLANG::JBool< true > option)
 Power $ x^{y} $.
 
template<class T >
static T pow (const T &x, const double y, const JLANG::JBool< false > option)
 Power $ x^{y} $.
 

Friends

template<class T >
JMATH::pow (const T &, const double y)
 Friend declaration of global method.
 

Detailed Description

Auxiliary class to hide data type specific methods.

Definition at line 47 of file JMath.hh.

Member Function Documentation

◆ pow() [1/2]

template<class T >
static T JMATH::JMath_t::pow ( const T & x,
const double y,
const JLANG::JBool< true > option )
inlinestaticprivate

Power $ x^{y} $.

This method corresponds to primitive data types.

Parameters
xvalue
ypower
optiontrue
Returns
result

Definition at line 65 of file JMath.hh.

66 {
67 return std::pow(x, y);
68 }

◆ pow() [2/2]

template<class T >
static T JMATH::JMath_t::pow ( const T & x,
const double y,
const JLANG::JBool< false > option )
inlinestaticprivate

Power $ x^{y} $.

This method corresponds to non-primitive data types.

Parameters
xvalue
ypower
optionfalse
Returns
result

Definition at line 82 of file JMath.hh.

83 {
84 return T(x).pow(y);
85 }

Friends And Related Symbol Documentation

◆ JMATH::pow

template<class T >
T JMATH::pow ( const T & ,
const double y )
friend

Friend declaration of global method.


The documentation for this struct was generated from the following file: