A finite possibly non-deterministic state machine with dwell durations


after posting a <a href="https://stackoverflow.com/questions/35440220/probabilistic-automata-finite-state-machines-in-clojure?lq=1" rel="nofollow">somewhat ambiguous question</a>, I believe I have nailed that what I am wondering (I am a complete novice in FSMs).

I would like to simulate a state space using finite state machines (possibly non-deterministic automata i.e. multiple next-state transitions allowed) in clojure.

This is essentially my problem:

Suppose we have these states Q={flying,cycling,running,driving} and we have the state durations for each during an average day D={120,30,30,60} - where for the sake of argument those are in minutes. How can one then create a possibly non-deterministic FSM (multiple destination states allowed) using clojure? I have looked at e.g. <a href="https://github.com/cdorrat/reduce-fsm" rel="nofollow">https://github.com/cdorrat/reduce-fsm</a> and <a href="https://github.com/ztellman/automat" rel="nofollow">https://github.com/ztellman/automat</a> but I do not believe it is quite what I want.

My end goal is to get a simulation looking something like S = {flying,flying,flying,flying,flying,cycling,cycling,running,driving,driving,driving}.

Effectively inducing heavy self-transition bias in the state machine. End and start state are not important.


The problem is not completely formulated to be answered unequivocally. Anyway: If you just want to recognize a specific sequence of states, you can use a finite automaton, and you will have to write them in that order, like:

flying -> flying -> flying -> flying -> flying -> cycling -> cycling -> running -> driving -> driving -> driving

where I'm considering that the transitions are caused by the durations you refer.

However, I suspect that you possibly need something more elaborated. That, can not be elaborated here. In my opinion if this is for programming purposes, I suggest that you use state machine diagrams from UML. They are powerful enough for your problem.


  • What is the meaning of `16 longs` and `110 words`, when reads the bits from a file
  • Formatting seconds duration into DD:HH:mm format by using moment.js
  • DataTables warning: table id=big_table - Requested unknown parameter '0' for row 0.
  • Elaborating on Polymorphism
  • MKMapView overlapping MKAnnotations only allow showing two of the callouts
  • vue two computed properties depending on each other
  • For loop returns same value repeatedly in Ajax call [duplicate]
  • Is it required that a C Variable Length Array is allocated from the stack?
  • Why does mapply repeat the same list multiple times?
  • Why did Windows use the FAT structure instead of a conventional linked list with a next pointer for
  • Reducing global variables and maintaining function flow
  • Load testing a Java/Mysql application, where to begin?
  • collecting table data from a .asp webpage over with a for loop using RSelenium
  • Difference between osrm route and match service
  • MSI Uninstall issue: Error 1001 -> The saved State dictionary contains inconsistent data and migh
  • How to decode route points from the JSON Output Data?
  • Getting a line that has the coordinates defined by the mouse location
  • Read stdin in chunks in Bash pipe
  • TypeError: 'builtin_function_or_method' object has no attribute '__getitem__'
  • Safari PHP form submission -file upload hangs
  • How do I obtain a list of files that changed from svn over a date range?
  • Embedding a Google map
  • How to force Composer to download a local package?
  • Is it possible to send skype chat messages from a linux server without X?
  • How to get value from merged-cells in Excel document using OpenXML and C#
  • Quick Question About Get and Set
  • Find VMID for running instance
  • Can I have a variable number of URI parameters or key-value pairs in Laravel 4?
  • Clarification on min distance on LocationManager.requestLocationUpdates method, min Distance paramet
  • as3-flash: any way to access all the instances placed in different frames from document class?
  • Does it make sense to call System.gc() and Thread.sleep() when working on Bitmaps?
  • Caching attributes in superclass
  • How to run “Deployd” on port 80 instead of port 5000 in webserver.
  • Join two tables and save into third-sql
  • How to model a transition system with SPIN
  • ActionScript 2 vs ActionScript 3 performance
  • ORA-29908: missing primary invocation for ancillary operator
  • How can I estimate amount of memory left with calling System.gc()?
  • Apache 2.4 - remove | delete | uninstall
  • Converting MP3 duration time