Joachim Klein
a325400ba2
Sampler.createSampler: For reward properties, catch the new case of a co-safety path formula properly
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@11446 bbc10eb1-c90d-0410-af57-cb519fbb1720
10 years ago
Dave Parker
48147aa4ad
Improvements to the SamplerDouble class: revised approach to variance estimation for better numerical stability (contributed by Marcin Copik), plus some further tidying/documentation.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@11413 bbc10eb1-c90d-0410-af57-cb519fbb1720
10 years ago
Joachim Klein
73a4ccf44f
SimulatorEngine: fix broken display of updates a path (GUI, regression) [with Linda Leuschner]
When a path is loaded in the simulator view of the GUI, selecting any step
but the last step can produce erroneous display of the update in the
"Manual exploration" field. The problem is that the updates are computed for
display relative to the variables values of the last state of the whole path
instead of relative to the state where the step originates.
This fix keeps the information about the correct state available for computing
the update display. This was a regression, introduced in SVN 10939 and should only
affect the GUI display, not computations.
To reproduce, use e.g.:
dtmc
module one
x: [0..3] init 0;
[] true -> (x' = min(3, x+1));
endmodule
Simulate for a few steps. The update information for the non-last steps of the path will
display incorrect values. This also occurs for display of CTL counterexamples.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@11281 bbc10eb1-c90d-0410-af57-cb519fbb1720
10 years ago
Joachim Klein
faa8e1e51f
ModulesFileModelGenerator: fix constant evaluation in explicit engine when built from GUI [with Steffen Maercker]
When building a model from the GUI with the explicit engine, constant were sometimes not
updated correctly:
(1) Open xprism, switch to explicit engine
(2) Load a model with undefined constants, e.g., brp.pm
(3) Build the model, setting constants (e.g., 2 and 3)
(4) Build the model again, setting *other* constants (e.g., 22 and 3)
In step (4), the log file reflects the changed constants,
but the generated model has the same number of states as
in step (3) and is fact built with the constants of step (3).
The cause:
If the PRISM file is not reloaded, then the currentModelGenerator
remains the same. In ModulesFileModelGenerator.initialise(), called
from setSomeUndefinedConstants() in step (3), the modulesFile is
overwritten with the modulesFile where the constants set in step (3)
have been replaced in the AST with the concrete values.
In step (4), there are no more AST-elements with undefined constants
and hence the modules file does not reflect the changed constants when
the constants in the constant list are changed.
The fix is to keep a copy of the original modules file in the
ModulesFileModelGenerator which is freshly deepCopyied and
processed in the subsequent calls to initialise().
Regression introduced in SVN r10996 when switching to the
ModulesFileModelGenerator infrastructure.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@11159 bbc10eb1-c90d-0410-af57-cb519fbb1720
10 years ago
Dave Parker
0f2bbbc7b6
Add some (syntactic) reward info to the ModelInfo interface and use this where possible in explicit model checking. Can now use ModulesFileModelGenerator for reward property model checking. Also push constant info from ModelGenerator up to ModelInfo.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@11006 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
2fe6c5d762
Add basic variable info to ModelInfo interface.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@11003 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
d4a86d5c2d
Remove ModelExplorer interface and replace with ModelGenerator.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10992 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
9e18844a26
Bug fix in ModulesFileModelGenerator: need to make sure model constants are expanded in labels.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10977 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
a959beb7a7
Create ModelGenerator class for a ModulesFile object. Base code on existing stuff in SimulatorEngine, but do not remove anything from there.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10973 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
557695e82b
Small refactor in SimulatorEngine.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10946 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
6a4e44b8ab
Small refactor in SimulatorEngine.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10939 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
b1cab85663
Code tidy.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10936 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
99fa6cf81b
Some commenting in SimulatorEngine.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10930 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
400fcfcc45
Some refactoring in SimulatorEngine.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10928 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
7557171b82
Auto-format.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10918 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
d4c5fd4fd5
Remove accidental commits
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10816 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
ff05caf158
Code tidy.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10815 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
9b039439c2
Bug fix in export of simulation path (to a file): file should be closed on completion.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10520 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
a76b3c73bd
Remove (most) usage of R_F in temporal operators.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10344 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
5238c76c4c
Optimisation in the simulator for models with very large numbers of actions (from Marcus Daum + Joachim Klein).
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10057 bbc10eb1-c90d-0410-af57-cb519fbb1720
11 years ago
Dave Parker
2690b87ff5
Bug fix in simulator: in DTMCs with local nondeterminism, random transitions can be wrongly chosen due to the distributions not being normalised.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@9352 bbc10eb1-c90d-0410-af57-cb519fbb1720
12 years ago
Dave Parker
caf5a0e50b
Bugfix: statistical model checking of discrete-time bounded untils with strict bounds (from Joachim Klein).
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@9163 bbc10eb1-c90d-0410-af57-cb519fbb1720
12 years ago
Dave Parker
8e2bc361cd
Improve simulation Sampler classes to handle deadlocks (in some cases). Deadlocks still not properly handled by the simulator.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@9147 bbc10eb1-c90d-0410-af57-cb519fbb1720
12 years ago
Dave Parker
dfce095d45
Make sure that some PrismFileLogs are close()ed after use - spotted as a bug by Bruno.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@8168 bbc10eb1-c90d-0410-af57-cb519fbb1720
12 years ago
Dave Parker
06e4c5fee1
Move normalisation of DTMC probabilities from SimulatorEngine into Updater class.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@7801 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Dave Parker
99d4873c47
Code tidy.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@7800 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Dave Parker
d128da069b
Bug fix: simulator was normalising DTMC bu dividing by number of choices (which was inconsistent with symbolic construction when using -noprobchecks).
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@7797 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Dave Parker
928a44101d
Make simulator.Updater objects extract settings more cleanly. And respect doProbChecks option.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@7795 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Dave Parker
02c26dbf53
Update simulator to allow path lengths over 2^31.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@7785 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Dave Parker
8291b5984c
Refactoring wrt the way that relational operators are stored for P/R/S operators (String -> RelOp).
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@7766 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Dave Parker
8ebc511308
Code tweaks: make Updater independent of PRISM/sim + make SimEngine into PrismComponent.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@7639 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Dave Parker
1a49d8d30f
svn:ignore on lib.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@7549 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Mateusz Ujma
e3f120815f
Changing visibility in Updater
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@7278 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Dave Parker
8784323e6e
Some code auto-formatting (for branch purposes).
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@6865 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Dave Parker
9a658794b1
Additional -help xxx messages.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@6833 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Ernst Moritz Hahn
78ed924305
reintegrated fau
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@6782 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Dave Parker
8833a6ef1d
Option 'snaphot' for -simpath also displays state/step indices.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@6726 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Dave Parker
bca442ee59
In -simpath, specifying the vars=(...) option automatically triggers the changes=true option (to match behaviour in previous versions of PRISM), unless overridden by setting changes=false).
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@6725 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Dave Parker
ec422e5c90
Bug fix in -simpath: state/step indices were not being displayed correctly when changes=true was set.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@6724 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Dave Parker
e8eb82d8ff
Added probs option to -simpath switch allow displaying of transition probabilities/rates (+ addition of this info to underlying path data structures, interfaces, etc.)
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@6629 bbc10eb1-c90d-0410-af57-cb519fbb1720
13 years ago
Dave Parker
db928a3402
Tweak/move error messages for non-supported R[C] operator.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@6222 bbc10eb1-c90d-0410-af57-cb519fbb1720
14 years ago
Dave Parker
9b5aae301f
Patch in current version of multi-objective model checking (from prism-multi branch). Still need to copy across etc/ directory containing lpsolve libraries. Also contains a few JDD fixes via Christian von Essen.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@6211 bbc10eb1-c90d-0410-af57-cb519fbb1720
14 years ago
Dave Parker
b2f33e44a7
Fixed "changed" setting in graph display of simulation paths.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@5482 bbc10eb1-c90d-0410-af57-cb519fbb1720
14 years ago
Dave Parker
5131fb407f
Some useful code (commented out) for getting variance etc. from simulation results.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@5425 bbc10eb1-c90d-0410-af57-cb519fbb1720
14 years ago
Dave Parker
0245cf77b4
Bug fix: crash on invalid integer reward struct indices.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@5420 bbc10eb1-c90d-0410-af57-cb519fbb1720
14 years ago
Dave Parker
19b18a0c3f
Bugfix in approximate simulation: property error was causing null ptr.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@5419 bbc10eb1-c90d-0410-af57-cb519fbb1720
14 years ago
Dave Parker
e1e6267210
Move path plot thread to GUI to allow display of warnings/errors.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@5412 bbc10eb1-c90d-0410-af57-cb519fbb1720
14 years ago
Dave Parker
6d502769be
GUI simulation path plot and can show vars and/or rewards.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@5400 bbc10eb1-c90d-0410-af57-cb519fbb1720
14 years ago
Dave Parker
a28c14715c
Simulation path generation handles empty vars=().
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@5399 bbc10eb1-c90d-0410-af57-cb519fbb1720
14 years ago
Dave Parker
6d9806ad16
PathToText respects new "change" option + bugfixes.
git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@5397 bbc10eb1-c90d-0410-af57-cb519fbb1720
14 years ago