12#include "IException.h"
13#include "NthOrderPolynomial.h"
41 QString mess =
"Number of variables given (" + QString::number(vars.size())
42 +
") does not match expected (" + QString::number(
Variables()) +
")!";
43 throw IException(IException::Programmer, mess, _FILEINFO_);
49 for (
int i = p_degree; i >= 1; i--) {
50 p_terms.push_back(pow(t1, i) - pow(t2, i));
BasisFunction(const QString &name, int numVars, int numCoefs)
Creates a BasisFunction object.
std::vector< double > p_terms
A vector of the terms in the equation.
int Variables() const
Returns the number of variables in the equation.
void Expand(const std::vector< double > &vars)
This is the the overriding virtual function that provides the expansion into the nth order polynomial...
NthOrderPolynomial(int degree)
Create an NthOrderPolynomial.
This is free and unencumbered software released into the public domain.
Namespace for the standard library.