From f22bab577b1b1c6a6ec40935dd589490e20a989e Mon Sep 17 00:00:00 2001 From: Sebastian Junges Date: Sat, 26 Sep 2020 12:33:43 -0700 Subject: [PATCH] extend example --- examples/highlevel_models/01-highlevel-models.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/examples/highlevel_models/01-highlevel-models.py b/examples/highlevel_models/01-highlevel-models.py index 46e2f41..ed0e99b 100644 --- a/examples/highlevel_models/01-highlevel-models.py +++ b/examples/highlevel_models/01-highlevel-models.py @@ -11,6 +11,13 @@ def example_highlevel_models(): for c in prism_program.constants: print("constant {} with type {} is {} defined".format(c.name, c.type, "" if c.defined else "not")) + path = stormpy.examples.files.prism_dtmc_brp + prism_program = stormpy.parse_prism_program(path) + for module in prism_program.modules: + for v in module.integer_variables: + print(f"Variable {v.name} has bounds {v.lower_bound_expression} and {v.upper_bound_expression}") + for v in module.boolean_variables: + print(f"Variable {v.name} is Boolean") if __name__ == '__main__':