carl  24.04
Computer ARithmetic Library
carl::MultivariateRoot< Poly > Class Template Reference

#include <MultivariateRoot.h>

Collaboration diagram for carl::MultivariateRoot< Poly >:

Public Types

using Number = typename UnderlyingNumberType< Poly >::type
 
using RAN = typename Poly::RootType
 

Public Member Functions

 MultivariateRoot (const Poly &poly, std::size_t k, Variable var)
 
 MultivariateRoot ()
 
std::size_t k () const noexcept
 Return k, the index of the root. More...
 
const Poly & poly () const noexcept
 
Poly & poly () noexcept
 
Variable var () const noexcept
 
bool is_univariate () const
 

Private Attributes

Poly m_poly
 Polynomial defining this root. More...
 
std::size_t m_k
 Specifies which root to consider. More...
 
Variable m_var
 The main variable. More...
 

Friends

template<typename P >
std::optional< typename MultivariateRoot< P >::RANevaluate (const MultivariateRoot< P > &mr, const carl::Assignment< typename MultivariateRoot< P >::RAN > &m)
 

Detailed Description

template<typename Poly>
class carl::MultivariateRoot< Poly >

Definition at line 32 of file MultivariateRoot.h.

Member Typedef Documentation

◆ Number

template<typename Poly >
using carl::MultivariateRoot< Poly >::Number = typename UnderlyingNumberType<Poly>::type

Definition at line 34 of file MultivariateRoot.h.

◆ RAN

template<typename Poly >
using carl::MultivariateRoot< Poly >::RAN = typename Poly::RootType

Definition at line 35 of file MultivariateRoot.h.

Constructor & Destructor Documentation

◆ MultivariateRoot() [1/2]

template<typename Poly >
carl::MultivariateRoot< Poly >::MultivariateRoot ( const Poly &  poly,
std::size_t  k,
Variable  var 
)
inline
Parameters
polyMust mention the root-variable "_z" and should have a at least 'rootIdx'-many roots in "_z" at each subpoint where it is intended to be evaluated.
kThe index of the root of the polynomial in "_z". The first root has index 1, the second has index 2 and so on.

Definition at line 51 of file MultivariateRoot.h.

◆ MultivariateRoot() [2/2]

template<typename Poly >
carl::MultivariateRoot< Poly >::MultivariateRoot ( )
inline

Definition at line 55 of file MultivariateRoot.h.

Member Function Documentation

◆ is_univariate()

template<typename Poly >
bool carl::MultivariateRoot< Poly >::is_univariate ( ) const
inline

Definition at line 86 of file MultivariateRoot.h.

◆ k()

template<typename Poly >
std::size_t carl::MultivariateRoot< Poly >::k ( ) const
inlinenoexcept

Return k, the index of the root.

Definition at line 60 of file MultivariateRoot.h.

Here is the caller graph for this function:

◆ poly() [1/2]

template<typename Poly >
const Poly& carl::MultivariateRoot< Poly >::poly ( ) const
inlinenoexcept
Returns
the raw underlying polynomial that still mentions the root-variable "_z".

Definition at line 67 of file MultivariateRoot.h.

Here is the caller graph for this function:

◆ poly() [2/2]

template<typename Poly >
Poly& carl::MultivariateRoot< Poly >::poly ( )
inlinenoexcept
Returns
the raw underlying polynomial that still mentions the root-variable "_z".

Definition at line 74 of file MultivariateRoot.h.

◆ var()

template<typename Poly >
Variable carl::MultivariateRoot< Poly >::var ( ) const
inlinenoexcept
Returns
The globally-unique distinguished root-variable "_z" to allow you to build a polynomial with this variable yourself.

Definition at line 82 of file MultivariateRoot.h.

Here is the caller graph for this function:

Friends And Related Function Documentation

◆ evaluate

template<typename Poly >
template<typename P >
std::optional<typename MultivariateRoot<P>::RAN> evaluate ( const MultivariateRoot< P > &  mr,
const carl::Assignment< typename MultivariateRoot< P >::RAN > &  m 
)
friend

Field Documentation

◆ m_k

template<typename Poly >
std::size_t carl::MultivariateRoot< Poly >::m_k
private

Specifies which root to consider.

Definition at line 40 of file MultivariateRoot.h.

◆ m_poly

template<typename Poly >
Poly carl::MultivariateRoot< Poly >::m_poly
private

Polynomial defining this root.

Definition at line 38 of file MultivariateRoot.h.

◆ m_var

template<typename Poly >
Variable carl::MultivariateRoot< Poly >::m_var
private

The main variable.

Definition at line 42 of file MultivariateRoot.h.


The documentation for this class was generated from the following file: