Polynome model.
More...
#include <JPolynome.hh>
Polynome model.
Definition at line 28 of file JPolynome.hh.
JMATH::JPolynome_t::JPolynome_t |
( |
| ) |
|
|
inline |
bool JMATH::JPolynome_t::equals |
( |
const JPolynome_t & |
P, |
|
|
const double |
eps = std::numeric_limits<double>::min() |
|
) |
| const |
|
inline |
Equality.
- Parameters
-
P | polynome |
eps | numerical precision |
- Returns
- true if polynomes identical; else false
Definition at line 47 of file JPolynome.hh.
50 if (this->size() == P.size()) {
52 for (const_iterator p = this->begin(), q = P.begin(); p != this->end(); ++p, ++q) {
53 if (fabs(*p - *q) > eps) {
Add polynome.
- Parameters
-
- Returns
- this polynome
Definition at line 73 of file JPolynome.hh.
75 while (this->size() < polynome.size()) {
79 for (
size_t i = 0; i != this->size(); ++i) {
80 (*this)[i] += polynome[i];
Subtract polynome.
- Parameters
-
- Returns
- this polynome
Definition at line 93 of file JPolynome.hh.
95 while (this->size() < polynome.size()) {
99 for (
size_t i = 0; i != this->size(); ++i) {
100 (*this)[i] -= polynome[i];
JPolynome_t& JMATH::JPolynome_t::mul |
( |
const double |
factor | ) |
|
|
inline |
Scale polynome.
- Parameters
-
factor | multiplication factor |
- Returns
- this polynome
Definition at line 113 of file JPolynome.hh.
115 for (iterator i = begin(); i != end(); ++i) {
Multiply with object.
- Parameters
-
- Returns
- result object
Definition at line 357 of file JMath.hh.
Auxiliary class for arithmetic operations on objects.
std::istream& operator>> |
( |
std::istream & |
in, |
|
|
JPolynome_t & |
object |
|
) |
| |
|
friend |
Read polynome from input.
- Parameters
-
in | input stream |
object | polynome |
- Returns
- input stream
Definition at line 130 of file JPolynome.hh.
132 for (
double x;
in >> x; ) {
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 CHECK_EXIT_CODE typeset A TRIPODS get_tripods $WORKDIR tripod txt TRIPODS for EMITTER in
std::ostream& operator<< |
( |
std::ostream & |
out, |
|
|
const JPolynome_t & |
object |
|
) |
| |
|
friend |
Write polynome to output.
- Parameters
-
out | output stream |
object | polynome |
- Returns
- output stream
Definition at line 147 of file JPolynome.hh.
149 for (JPolynome_t::const_iterator i =
object.begin(); i !=
object.end(); ++i) {
150 out <<
' ' <<
FIXED(9,3) << *i;
Auxiliary data structure for floating point format specification.
The documentation for this struct was generated from the following file: