Class MarkovTransformationResult
- java.lang.Object
-
- org.palladiosimulator.reliability.solver.pcm2markov.MarkovTransformationResult
-
public class MarkovTransformationResult extends Object
Aggregates the results of a PCM2MarkovTransformation.
-
-
Constructor Summary
Constructors Constructor Description MarkovTransformationResult(org.palladiosimulator.solver.runconfig.PCMSolverWorkflowRunConfiguration configuration, MarkovTransformationSource markovSource, org.palladiosimulator.pcm.usagemodel.UsageScenario scenario, List<MarkovFailureType> failureTypes)Creates a new Markov results aggregator.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddPhysicalStateResults(MarkovChain resultChain, double[][] markovProbabilityMatrix, double physicalStateProbability)Adds the results of the evaluation of a single physical system state during the PCM2Markov transformation.Map<MarkovFailureType,Double>getCumulatedFailureTypeProbabilities()Gets the overall failure type probabilities, accumulated over all considered physical system states.doublegetCumulatedPhysicalStateProbability()Gets the overall physical state probability, accumulated over all considered physical system states.longgetNumberOfPhysicalSystemStates()Retrieves the number of physical system states.longgetPhysicalStateEvaluationCount()Retrieves the current number of evaluated physical system states.MarkovChaingetResultChain()Retrieves the Markov chain that results from the transformation.org.palladiosimulator.pcm.usagemodel.UsageScenariogetScenario()Gets the usage scenario which has been evaluateddoublegetSuccessProbability()Retrieves the overall success probability.booleanhasRequiredAccuracy(int requiredAccuracy)Determines if the calculated success probability conforms to a given required accuracy.booleanisDoApproximate()Indicates if an approximation scheme shall be used for printing of probabilities.voidsetApproximate(boolean approximate)Method for setting a value responsible for telling if an approximation scheme shall be used for printing probabilities.
-
-
-
Constructor Detail
-
MarkovTransformationResult
public MarkovTransformationResult(org.palladiosimulator.solver.runconfig.PCMSolverWorkflowRunConfiguration configuration, MarkovTransformationSource markovSource, org.palladiosimulator.pcm.usagemodel.UsageScenario scenario, List<MarkovFailureType> failureTypes)Creates a new Markov results aggregator.- Parameters:
configuration- configuration options of the transformationmarkovSource- the Markov state holderscenario- the usage scenario to evaluatefailureTypes- the list of potential failure types
-
-
Method Detail
-
addPhysicalStateResults
public void addPhysicalStateResults(MarkovChain resultChain, double[][] markovProbabilityMatrix, double physicalStateProbability)
Adds the results of the evaluation of a single physical system state during the PCM2Markov transformation.- Parameters:
resultChain- the Markov chain resulting from the evaluation of the physical system statemarkovProbabilityMatrix- the matrix with the probabilities to get from state i to state j in the Markov chainphysicalStateProbability- the probability of the evaluated physical system state to occur
-
getCumulatedFailureTypeProbabilities
public Map<MarkovFailureType,Double> getCumulatedFailureTypeProbabilities()
Gets the overall failure type probabilities, accumulated over all considered physical system states.- Returns:
- the overall failure type probabilities
-
getCumulatedPhysicalStateProbability
public double getCumulatedPhysicalStateProbability()
Gets the overall physical state probability, accumulated over all considered physical system states.- Returns:
- the overall physical state probability
-
getNumberOfPhysicalSystemStates
public long getNumberOfPhysicalSystemStates()
Retrieves the number of physical system states.- Returns:
- the number of physical system states
-
getPhysicalStateEvaluationCount
public long getPhysicalStateEvaluationCount()
Retrieves the current number of evaluated physical system states.- Returns:
- the current number of evaluated physical system states
-
getResultChain
public MarkovChain getResultChain()
Retrieves the Markov chain that results from the transformation.- Returns:
- the Markov chain that results from the transformation
-
getScenario
public org.palladiosimulator.pcm.usagemodel.UsageScenario getScenario()
Gets the usage scenario which has been evaluated- Returns:
- the usage scenario
-
getSuccessProbability
public double getSuccessProbability()
Retrieves the overall success probability.- Returns:
- the success probability
-
hasRequiredAccuracy
public boolean hasRequiredAccuracy(int requiredAccuracy)
Determines if the calculated success probability conforms to a given required accuracy.- Parameters:
requiredAccuracy- the required accuracy in decimal places- Returns:
- true if the required accuracy has been reached
-
isDoApproximate
public boolean isDoApproximate()
Indicates if an approximation scheme shall be used for printing of probabilities.- Returns:
true, if an approximation scheme shall be used for printing probabilities,falseotherwise.
-
setApproximate
public void setApproximate(boolean approximate)
Method for setting a value responsible for telling if an approximation scheme shall be used for printing probabilities.- Parameters:
approximate- the value indicating if an approximation scheme shall be used for printing probabilities
-
-