1 #ifndef __JFIT__JENERGY__
2 #define __JFIT__JENERGY__
16 namespace JPP {
using namespace JFIT; }
146 return pow(10.0,
__X);
168 return getE() * log(10.0);
179 return std::fabs(energy.
__X);
190 return JEnergy(-std::numeric_limits<double>::max());
201 return JEnergy(+std::numeric_limits<double>::max());
double getE() const
Get energy.
static JEnergy max()
Get maximum possible value.
Auxiliary base class for aritmetic operations of derived class types.
double getDE() const
Get derivative of energy.
bool less(const JEnergy &X) const
Less than method.
JEnergy()
Default constructor.
JEnergy & sub(const JEnergy &value)
Subtraction operator.
JEnergy(const double X)
Constructor.
friend double fabs(const JEnergy &energy)
Get absolute value.
JEnergy & div(const double value)
Division operator.
JEnergy & negate()
Prefix unary minus.
double JEnergy::* parameter_type
Template definition of auxiliary base class for comparison of data structures.
double getX() const
Get energy.
static parameter_type pE()
void putE(const double E)
Put energy.
friend std::istream & operator>>(std::istream &in, JEnergy &object)
Read object from input.
static JEnergy min()
Get minimum possible value.
Base class for data structures with artithmetic capabilities.
Data structure for fit of energy.
friend std::ostream & operator<<(std::ostream &out, const JEnergy &object)
Write object to output.
JEnergy & mul(const double value)
Multiplication operator.
JEnergy & add(const JEnergy &value)
Addition operator.