Skip to content

Make dtmc model checker throw on unreachable condition when checking conditional probabilities.#946

Open
lukovdm wants to merge 2 commits into
stormchecker:masterfrom
lukovdm:conditional-dtmc-fix
Open

Make dtmc model checker throw on unreachable condition when checking conditional probabilities.#946
lukovdm wants to merge 2 commits into
stormchecker:masterfrom
lukovdm:conditional-dtmc-fix

Conversation

@lukovdm

@lukovdm lukovdm commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

Includes fix and added tests for this case.

@volkm volkm left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.
Maybe use a different type of exception such as InvalidPropertyException?

@lukovdm

lukovdm commented Jul 1, 2026

Copy link
Copy Markdown
Contributor Author

I was being consistent the the conditional MDP case, but I agree it is a bit weird. I will change both the DTMC and the MDP one to InvalidPropertyException.


if (transformedModel.noTargetStates) {
storm::utility::vector::setVectorValues(result, transformedModel.beforeStates, storm::utility::zero<ValueType>());
STORM_LOG_THROW(!conditionStates.empty(), storm::exceptions::InvalidPropertyException,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we have to check that conditionStates are reachable from all relevant (i.e. initial) states?

Something like

auto const conditionGreaterZeroStates = storm::utility::graph::performProbGreater0(backwardTransitions, allStates, conditionStates);
STORM_LOG_THROW(goal.hasRelevantStates && goal.getRelevantStates().isSubsetOf(conditionGreaterZeroStates), ...);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants