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 354 of file JMath.hh.
356 return static_cast<JFirst_t&
>(*this) = JFirst_t().mul(static_cast<const JFirst_t&>(*
this),
object);
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 The output file must have the wildcard in the e g root fi eval JPrintDetector a $DETECTOR O IDENTIFIER eval JPrintDetector a $DETECTOR O SUMMARY JAcoustics sh $DETECTOR_ID source JAcousticsToolkit sh CHECK_EXIT_CODE typeset A EMITTERS get_tripods $WORKDIR tripod txt EMITTERS get_transmitters $WORKDIR transmitter txt EMITTERS 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: