18 shared_ptr<const NucleicAlphabet> alphabet,
30 double f = alpha + beta + gamma + delta;
55 beta_ = betaP * (1 - theta);
92 for (
unsigned int i = 0; i < 4; i++)
170 for (
size_t i = 0; i <
size_; i++)
172 for (
size_t j = 0; j <
size_; j++)
Specialisation abstract class for nucleotide substitution model.
void addParameter_(Parameter *parameter)
void setParameterValue(const std::string &name, double value) override
double getParameterValue(const std::string &name) const override
RowMatrix< double > generator_
The generator matrix of the model.
bool isDiagonalizable_
boolean value for diagonalizability in R of the generator_
bool isNonSingular_
boolean value for non-singularity of rightEigenVectors_
std::vector< RowMatrix< double > > vPowGen_
vector of the powers of generator_ for Taylor development (if rightEigenVectors_ is singular).
Vdouble eigenValues_
The vector of eigen values.
bool computeFrequencies() const
RowMatrix< double > exchangeability_
The exchangeability matrix of the model, defined as . When the model is reversible,...
RowMatrix< double > leftEigenVectors_
The matrix made of left eigen vectors (by row) if rightEigenVectors_ is non-singular.
virtual bool isScalable() const
returns if model is scalable
RowMatrix< double > rightEigenVectors_
The matrix made of right eigen vectors (by column).
void setScale(double scale)
Multiplies the current generator by the given scale.
size_t size_
The number of states.
Vdouble freq_
The vector of equilibrium frequencies.
This class implements a state map where all resolved states are modeled.
static const std::shared_ptr< IntervalConstraint > PROP_CONSTRAINT_EX
void setFreq(std::map< int, double > &) override
This method takes the average value between observed and .
void updateMatrices_() override
Diagonalize the matrix, and fill the eigenValues_, iEigenValues_, leftEigenVectors_ and rightEigenVe...
RN95s(std::shared_ptr< const NucleicAlphabet > alphabet, double alpha=0.25, double beta=0.25, double gamma=0.25, double delta=0.25)
Defines the basic types of data flow nodes.
ExtendedFloat abs(const ExtendedFloat &ef)