Message Boards Message Boards

GROUPS:

DiscreteMarkovProcess and FirstPassageTimeDistribution "don't" work?

Posted 6 months ago
363 Views
|
0 Replies
|
0 Total Likes
|

Hello there, I have two examples who hopefully sum my problem up. Why does

(* markov bauen*)
mark = {{1, 0, 0, 0, 0, 0, 0}, {0.528, 0.132, 0.34, 0, 0, 0, 0}, {0.8,
     0, 0.2, 0, 0, 0, 0}, {0.528, 0, 0.34, 0.132, 0, 0, 0}, {0, 1/3, 
    1/3, 1/3, 0, 0, 0}, {0, 1/3, 1/3, 1/3, 0, 0, 0}, {0, 1/3, 1/3, 
    1/3, 0, 0, 0}};
markov = DiscreteMarkovProcess[5, mark];
gr = Graph[markov, GraphLayout -> "LayeredDrawing"]
test = FirstPassageTimeDistribution[markov, 1];
PDF[test, k];
DiscretePlot[%, {k, 1, 15}, ExtentSize -> 1/2]
MarkovProcessProperties[markov, "AbsorbingClasses"]

have a correct plot for my "exit time" (time untill I reach 1) but when I change field 5 such that a "particle" can stay there, thus I get

(* markov bauen*)
mark = {{1, 0, 0, 0, 0, 0, 0}, {0.528, 0.132, 0.34, 0, 0, 0, 0}, {0.8,
     0, 0.2, 0, 0, 0, 0}, {0.528, 0, 0.34, 0.132, 0, 0, 0}, {0, 1/4, 
    1/4, 1/4, 1/4, 0, 0}, {0, 1/3, 1/3, 1/3, 0, 0, 0}, {0, 1/3, 1/3, 
    1/3, 0, 0, 0}};
markov = DiscreteMarkovProcess[5, mark];
gr = Graph[markov, GraphLayout -> "LayeredDrawing"]
test = FirstPassageTimeDistribution[markov, 1];
PDF[test, k];
DiscretePlot[%, {k, 1, 15}, ExtentSize -> 1/2]
MarkovProcessProperties[markov, "AbsorbingClasses"]

where I changed the fiths entry, I get as a propability 0, I am totally confused because the probability isn't 0! Why does mathematica get's an calculation error? Or do I missunderstand something?

thank you in advance

Attachments:
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract