Storm 1.13.0.1
A Modern Probabilistic Model Checker
Loading...
Searching...
No Matches
Smg.h
Go to the documentation of this file.
1#pragma once
2
7
8namespace storm {
9namespace models {
10namespace sparse {
11
15template<class ValueType, typename RewardModelType = StandardRewardModel<ValueType>>
16class Smg : public NondeterministicModel<ValueType, RewardModelType> {
17 public:
25
26 Smg(Smg<ValueType, RewardModelType> const& other) = default;
28
31
32 std::vector<storm::storage::PlayerIndex> const& getStatePlayerIndications() const;
33 storm::storage::PlayerIndex getPlayerOfState(uint64_t stateIndex) const;
34 storm::storage::PlayerIndex getPlayerIndex(std::string const& playerName) const;
35 std::map<std::string, storm::storage::PlayerIndex> const& getPlayerNamesToIndex() const;
37 uint64_t getNumberOfPlayers() const;
38
39 private:
40 // Assigns the controlling player to each state.
41 // If a state has storm::storage::INVALID_PLAYER_INDEX, it shall be the case that the choice at that state is unique
42 std::vector<storm::storage::PlayerIndex> statePlayerIndications;
43 // A mapping of player names to player indices.
44 std::map<std::string, storm::storage::PlayerIndex> playerNameToIndexMap;
45};
46
47} // namespace sparse
48} // namespace models
49} // namespace storm
NondeterministicModel(ModelType modelType, storm::storage::sparse::ModelComponents< ValueType, RewardModelType > const &components)
Constructs a model from the given data.
std::vector< storm::storage::PlayerIndex > const & getStatePlayerIndications() const
Definition Smg.cpp:34
storm::storage::PlayerIndex getPlayerOfState(uint64_t stateIndex) const
Definition Smg.cpp:39
storm::storage::BitVector computeStatesOfCoalition(storm::logic::PlayerCoalition const &coalition) const
Definition Smg.cpp:62
std::map< std::string, storm::storage::PlayerIndex > const & getPlayerNamesToIndex() const
Definition Smg.cpp:52
Smg & operator=(Smg< ValueType, RewardModelType > &&other)=default
Smg(storm::storage::sparse::ModelComponents< ValueType, RewardModelType > const &components)
Constructs a model from the given data.
Definition Smg.cpp:15
Smg(Smg< ValueType, RewardModelType > const &other)=default
storm::storage::PlayerIndex getPlayerIndex(std::string const &playerName) const
Definition Smg.cpp:45
Smg(Smg< ValueType, RewardModelType > &&other)=default
Smg & operator=(Smg< ValueType, RewardModelType > const &other)=default
uint64_t getNumberOfPlayers() const
Definition Smg.cpp:57
A bit vector that is internally represented as a vector of 64-bit values.
Definition BitVector.h:16
uint64_t PlayerIndex
Definition PlayerIndex.h:7