17template<
typename ValueType>
19template<
typename ValueType>
21template<
typename ValueType>
26template<
typename ValueType>
30template<
typename ValueType>
39 std::vector<size_t> mUsedRepresentants;
43 bool mTransient =
false;
72 std::shared_ptr<DFTState<ValueType>>
copy()
const;
84 void setId(
size_t id);
147 return failableElements;
156 uint_fast64_t
uses(
size_t id)
const;
181 bool isUsed(
size_t child)
const;
188 void setUses(
size_t spareId,
size_t child);
287 return a.mStatus == b.mStatus;
291 void propagateActivation(
size_t representativeId);
293 int getElementStateInt(
size_t id)
const;
302template<
typename ValueType>
303struct hash<
storm::dft::storage::DFTState<ValueType>> {
305 return hash<storm::storage::BitVector>()(s.mStatus);
Represents a Dynamic Fault Tree.
void letBEFail(std::shared_ptr< storm::dft::storage::elements::DFTBE< ValueType > const > be)
Sets the next BE as failed.
void setFailed(size_t id)
void setDependencyDontCare(size_t id)
bool dependencyUnsuccessful(size_t id) const
friend bool operator==(DFTState const &a, DFTState const &b)
std::shared_ptr< DFTState< ValueType > > copy() const
ValueType getBERate(size_t id) const
Get the current failure rate of the given BE.
void setFailsafe(size_t id)
bool isPseudoState() const
bool claimNew(size_t spareId, size_t currentlyUses, std::vector< std::shared_ptr< storm::dft::storage::elements::DFTElement< ValueType > > > const &children)
Claim a new spare child for the given spare gate.
void beNoLongerFailable(size_t id)
void activate(size_t repr)
DFTDependencyState getDependencyState(size_t id) const
void letDependencyTrigger(std::shared_ptr< storm::dft::storage::elements::DFTDependency< ValueType > const > dependency, bool successful=true)
Trigger the dependency and set it as successful/unsuccessful.
storm::dft::storage::FailableElements & getFailableElements()
void setDontCare(size_t id)
bool hasFailed(size_t id) const
uint_fast64_t uses(size_t id) const
This method returns the id of the used child for a spare.
bool isUsed(size_t child) const
Checks whether an element is currently used.
bool isActive(size_t id) const
bool hasOperationalRelevantEvent()
Check whether at least one relevant event is still operational.
bool updateFailableDependencies(size_t id)
Sets all failable BEs due to dependencies from newly failed element.
ValueType getFailableBERate(size_t index) const
Get the failure rate of the currently failable BE on the given index.
bool dependencySuccessful(size_t id) const
bool isEventRelevantInRestriction(size_t id) const
Check whether the event is still relevant for any restriction.
void finalizeUses(size_t spareId)
Sets the use for the spare to a default value to gain consistent states after failures.
bool orderBySymmetry()
Order the state in decreasing order using the symmetries.
uint_fast64_t extractUses(size_t from) const
This method is commonly used to get the usage information for spares.
bool dontCare(size_t id) const
bool isOperational(size_t id) const
bool updateFailableInRestrictions(size_t id)
Sets all failable BEs due to restrictions from newly failed element.
bool isEventDisabledViaRestriction(size_t id) const
Check whether the event cannot fail at the moment due to a restriction.
void setDependencyUnsuccessful(size_t id)
DFTElementState getElementState(size_t id) const
storm::storage::BitVector const & status() const
void updateDontCareDependencies(size_t id)
Sets all dependencies dont care whose dependent event is the newly failed BE.
void setUses(size_t spareId, size_t child)
Sets for the spare which child is now used.
bool isFailsafe(size_t id) const
bool dependencyTriggered(size_t id) const
void construct()
Construct concrete state from pseudo state by using the underlying bitvector.
void setDependencySuccessful(size_t id)
static uint_fast64_t usesIndex(storm::storage::BitVector const &state, DFTStateGenerationInfo const &stateGenerationInfo, size_t id)
Returns the index of the used child for a spare gate.
Handling of currently failable elements (BEs) either due to their own failure or because of dependenc...
Abstract base class for basic events (BEs) in DFTs.
Dependency gate with probability p.
Abstract base class for DFT elements.
A bit vector that is internally represented as a vector of 64-bit values.