|
Storm 1.14.0.1
A Modern Probabilistic Model Checker
|
Constructs a belief. More...
#include <BeliefBuilder.h>
Public Types | |
| using | ValueType = typename BeliefType::ValueType |
Public Member Functions | |
| void | reserve (uint64_t size) |
| Reserves space to build the belief more efficiently. | |
| void | addValue (BeliefStateType const &state, ValueType const &value) |
| Adds a probability value to the given state. | |
| void | setObservation (BeliefObservationType const &observation) |
| Sets the observation of the belief. | |
| ValueType | normalize () |
| Normalizes the belief, i.e., if the sum of the values is not 1, it divides all values by the sum. | |
| BeliefType | build () |
| Builds the belief and returns it. | |
| void | reset () |
| Resets the builder to its initial state. | |
Constructs a belief.
| BeliefType | the type of belief to construct |
Definition at line 13 of file BeliefBuilder.h.
| using storm::pomdp::beliefs::BeliefBuilder< BeliefType >::ValueType = typename BeliefType::ValueType |
Definition at line 15 of file BeliefBuilder.h.
| void storm::pomdp::beliefs::BeliefBuilder< BeliefType >::addValue | ( | BeliefStateType const & | state, |
| ValueType const & | value ) |
Adds a probability value to the given state.
If a value for the state already exists, its new value is the sum of the existing one and the given value.
Definition at line 18 of file BeliefBuilder.cpp.
| BeliefType storm::pomdp::beliefs::BeliefBuilder< BeliefType >::build | ( | ) |
Builds the belief and returns it.
Definition at line 47 of file BeliefBuilder.cpp.
| BeliefBuilder< BeliefType >::ValueType storm::pomdp::beliefs::BeliefBuilder< BeliefType >::normalize | ( | ) |
Normalizes the belief, i.e., if the sum of the values is not 1, it divides all values by the sum.
Hence, after calling this, the sum of the values is 1.
Definition at line 31 of file BeliefBuilder.cpp.
| void storm::pomdp::beliefs::BeliefBuilder< BeliefType >::reserve | ( | uint64_t | size | ) |
Reserves space to build the belief more efficiently.
| size | the number of states in the support of the belief |
Definition at line 13 of file BeliefBuilder.cpp.
| void storm::pomdp::beliefs::BeliefBuilder< BeliefType >::reset | ( | ) |
Resets the builder to its initial state.
After build() has been called, this method must be called before building another belief with this builder.
Definition at line 60 of file BeliefBuilder.cpp.
| void storm::pomdp::beliefs::BeliefBuilder< BeliefType >::setObservation | ( | BeliefObservationType const & | observation | ) |
Sets the observation of the belief.
| observation | the observation to set |
Definition at line 26 of file BeliefBuilder.cpp.