Auxiliary base class for mathematical operations on parameters of function.
More...
#include <JMathlib.hh>
|
JF1_t & | negate () |
| Negate function. More...
|
|
JF1_t & | add (const JF1_t &f1) |
| Add function. More...
|
|
JF1_t & | sub (const JF1_t &f1) |
| Subtract function. More...
|
|
JF1_t & | mul (const double factor) |
| Scale function. More...
|
|
JF1_t & | div (const double factor) |
| Scale function. More...
|
|
template<class JF1_t>
struct JMATH::JCalculus< JF1_t >
Auxiliary base class for mathematical operations on parameters of function.
Definition at line 196 of file JMathlib.hh.
◆ negate()
Negate function.
- Returns
- this function
Definition at line 203 of file JMathlib.hh.
205 for (
const auto& i : JF1_t::parameters) {
206 static_cast<JF1_t&
>(*this).*i = -(
static_cast<JF1_t&
>(*this).*i);
209 return static_cast<JF1_t&
>(*this);
◆ add()
Add function.
- Parameters
-
- Returns
- this function
Definition at line 219 of file JMathlib.hh.
221 for (
const auto& i : JF1_t::parameters) {
222 static_cast<JF1_t&
>(*this).*i +=
f1.*i;
225 return static_cast<JF1_t&
>(*this);
const JPolynome f1(1.0, 2.0, 3.0)
Function.
◆ sub()
Subtract function.
- Parameters
-
- Returns
- this function
Definition at line 235 of file JMathlib.hh.
237 for (
const auto& i : JF1_t::parameters) {
238 static_cast<JF1_t&
>(*this).*i -=
f1.*i;
241 return static_cast<JF1_t&
>(*this);
◆ mul()
Scale function.
- Parameters
-
- Returns
- this function
Definition at line 251 of file JMathlib.hh.
253 for (
const auto& i : JF1_t::parameters) {
254 static_cast<JF1_t&
>(*this).*i *= factor;
257 return static_cast<JF1_t&
>(*this);
◆ div()
Scale function.
- Parameters
-
- Returns
- this function
Definition at line 267 of file JMathlib.hh.
269 for (
const auto& i : JF1_t::parameters) {
270 static_cast<JF1_t&
>(*this).*i /= factor;
273 return static_cast<JF1_t&
>(*this);
◆ operator+=
template<class JF1_t >
JF1_t& operator+= |
( |
JF1_t & |
function, |
|
|
const JF1_t & |
value |
|
) |
| |
|
friend |
Add function.
- Parameters
-
function | this function |
value | value |
- Returns
- this function
Definition at line 284 of file JMathlib.hh.
286 return function.add(value);
◆ operator-=
template<class JF1_t >
JF1_t& operator-= |
( |
JF1_t & |
function, |
|
|
const JF1_t & |
value |
|
) |
| |
|
friend |
Subtract function.
- Parameters
-
function | this function |
value | value |
- Returns
- this function
Definition at line 297 of file JMathlib.hh.
299 return function.sub(value);
◆ operator*=
template<class JF1_t >
JF1_t& operator*= |
( |
JF1_t & |
function, |
|
|
const double |
factor |
|
) |
| |
|
friend |
Scale function.
- Parameters
-
function | this function |
factor | factor |
- Returns
- this function
Definition at line 310 of file JMathlib.hh.
312 return function.mul(factor);
◆ operator/=
template<class JF1_t >
JF1_t& operator/= |
( |
JF1_t & |
function, |
|
|
const double |
factor |
|
) |
| |
|
friend |
Scale function.
- Parameters
-
function | this function |
factor | factor |
- Returns
- this function
Definition at line 323 of file JMathlib.hh.
325 return function.div(factor);
The documentation for this struct was generated from the following file: