It is simply a std::vector with an interface designed for dealing with probability mass functions. It is a flattend version of an D dimensional propability table. More...
#include <FgPotential.h>
Public Member Functions | |
Potential () | |
Default constructor. More... | |
~Potential () | |
Destructor. More... | |
void | Add (double value) |
Adds a potential value. More... | |
void | Set (double value, int index) |
Sets a potential value at given index. More... | |
double | Get (int index) |
Gets a potential value using the given index. More... | |
Private Attributes | |
std::vector< double > | vP |
It is simply a std::vector with an interface designed for dealing with probability mass functions. It is a flattend version of an D dimensional propability table.
It is mainly used for representing measures on a finite outcome space, for example, the probability distribution of a discrete random variable. However, entries are not necessarily non-negative; it is also used to represent logarithms of probability mass functions.
Hmetal T, 11.08.2017.
T | Should be a scalar and should support elementary arithmetic operations. |
Definition at line 38 of file FgPotential.h.
NeuralEngine::MachineLearning::Potential::Potential | ( | ) |
Default constructor.
Admin, 8/29/2017.
NeuralEngine::MachineLearning::Potential::~Potential | ( | ) |
Destructor.
Admin, 8/29/2017.
void NeuralEngine::MachineLearning::Potential::Add | ( | double | value | ) |
Adds a potential value.
Admin, 8/29/2017.
value | The value to add. |
void NeuralEngine::MachineLearning::Potential::Set | ( | double | value, |
int | index | ||
) |
Sets a potential value at given index.
Admin, 8/29/2017.
value | The value. |
index | Zero-based index of the value. |
double NeuralEngine::MachineLearning::Potential::Get | ( | int | index | ) |
Gets a potential value using the given index.
Admin, 8/29/2017.
index | The index to get. |
|
private |
Definition at line 87 of file FgPotential.h.