26 #ifndef GUM_MULTI_DIM_SPARSE_H 27 #define GUM_MULTI_DIM_SPARSE_H 47 template <
typename GUM_SCALAR >
98 virtual void fill(
const GUM_SCALAR& d)
const;
102 virtual void set(
const Instantiation& i,
const GUM_SCALAR& value)
const;
104 virtual const std::string&
name()
const;
138 #ifndef GUM_NO_EXTERN_TEMPLATE_CLASS GUM_SCALAR _default
The default value.
void erase(const DiscreteVariable &v)
Removes a var from the variables of the multidimensional matrix.
virtual ~MultiDimSparse()
Copy operator.
Headers of the MultiDimWithOffset class.
Base class for discrete random variable.
gum is the global namespace for all aGrUM entities
Abstract base class for all multi dimensionnal containers.
virtual MultiDimContainer< GUM_SCALAR > * newFactory() const
Class constructor.
Abstract class for Multidimensional matrix stored as an array in memory and with an offset associated...
Implementation of MultiDimSparse.
virtual void _commitMultipleChanges()
Synchronise content after MultipleChanges.
void add(const DiscreteVariable &v)
Adds a new var to the variables of the multidimensional matrix.
virtual const std::string & name() const
Returns the real name of the multiDim implementation.
Class for assigning/browsing values to tuples of discrete variables.
MultiDimSparse(const GUM_SCALAR &default_value)
Default constructor: creates an empty null dimensional matrix.
virtual GUM_SCALAR & _get(const Instantiation &i) const
HashTable< Size, GUM_SCALAR > _params
The true data : the values is mutable since we can change the value in a const multiDimArray.
std::size_t Size
In aGrUM, hashed values are unsigned long int.
virtual void _replace(const DiscreteVariable *x, const DiscreteVariable *y)
Replace variable x by y.
virtual void fill(const GUM_SCALAR &d) const
Fill the table with d.
virtual Size realSize() const
Returns the real number of parameters used for this table.
Multidimensional matrix stored as a sparse array in memory.