mcrl2::lts::probabilistic_arbitrary_precision_fraction

Include file:

#include "mcrl2/lts/probabilistic_arbitrary_precision_fraction.h
class mcrl2::lts::probabilistic_arbitrary_precision_fraction

This class contains labels for probabilistic transistions, consisting of a numerator and a denominator as a string of digits.

Protected attributes

utilities::big_natural_number m_denominator
utilities::big_natural_number m_enumerator

Protected static member functions

static utilities::big_natural_number &buffer1()
static utilities::big_natural_number &buffer2()
static utilities::big_natural_number &buffer3()

Public static member functions

static utilities::big_natural_number greatest_common_divisor(utilities::big_natural_number x, utilities::big_natural_number y)
static void greatest_common_divisor_destructive(utilities::big_natural_number &x, utilities::big_natural_number &y, utilities::big_natural_number &buffer_divide, utilities::big_natural_number &buffer_remainder, utilities::big_natural_number &buffer)
static probabilistic_arbitrary_precision_fraction &one()

Constant one.

static void remove_common_factors(utilities::big_natural_number &enumerator, utilities::big_natural_number &denominator)
static probabilistic_arbitrary_precision_fraction &zero()

Constant zero.

Public member functions

const utilities::big_natural_number &denominator() const
const utilities::big_natural_number &enumerator() const
bool operator!=(const probabilistic_arbitrary_precision_fraction &other) const
probabilistic_arbitrary_precision_fraction operator*(const probabilistic_arbitrary_precision_fraction &other) const
probabilistic_arbitrary_precision_fraction operator+(const probabilistic_arbitrary_precision_fraction &other) const
probabilistic_arbitrary_precision_fraction operator-(const probabilistic_arbitrary_precision_fraction &other) const
probabilistic_arbitrary_precision_fraction operator/(const probabilistic_arbitrary_precision_fraction &other) const
bool operator<(const probabilistic_arbitrary_precision_fraction &other) const
bool operator<=(const probabilistic_arbitrary_precision_fraction &other) const
bool operator==(const probabilistic_arbitrary_precision_fraction &other) const
bool operator>(const probabilistic_arbitrary_precision_fraction &other) const
bool operator>=(const probabilistic_arbitrary_precision_fraction &other) const
probabilistic_arbitrary_precision_fraction()
probabilistic_arbitrary_precision_fraction(const utilities::big_natural_number &enumerator, const utilities::big_natural_number &denominator)
probabilistic_arbitrary_precision_fraction(const std::string &enumerator, const std::string &denominator)