Class LalCore

java.lang.Object
jline.lang.lal.LalCore

public final class LalCore extends Object
Validation and finite CTMC compilation of LAL models (Python lal/core.py).

A synchronized active transition is blocked when any passive partner has no matching transition. Passive alternatives use positive weights, normalized within each partner's current state. Unsynchronized active actions are local.

Immediate actions fire in zero time with maximal progress: in a state where any immediate event is enabled only the immediate events of the highest priority fire, chosen in proportion to their weights, and such vanishing states are eliminated by stochastic complementation in compileModel(jline.lang.lal.LalModel).

  • Method Details

    • validateModel

      public static void validateModel(LalModel model)
      Validate with unbounded queues refused.
    • validateModel

      public static void validateModel(LalModel model, boolean allowUnbounded)
      Validate the common agent model used by both frontends (Python validate_model).
    • parse

      public static LalModel parse(String source)
      Parse LAL source, throwing IllegalArgumentException on invalid input.
    • modelFeatures

      public static SortedSet<String> modelFeatures(LalModel model)
      Features of a model that only the extended kernel interprets (Python model_features): embedded, immediate, functional and multilabel, in sorted order.
    • joinFeatures

      public static String joinFeatures(Collection<String> features)
      Comma-joined sorted feature names, as Python joins them in refusal messages.
    • events

      public static EventKernel events(LalModel model)
      Return the extended event kernel of a validated model (Python events).
    • eventKernel

      public static EventKernel eventKernel(LalModel model)
      Return the legacy timed kernel of a validated model (Python event_kernel). Models with immediate actions, embedded LINE objects or multi-label events need the extended interface and are refused, so a solver path built on this kernel cannot misread them.
    • compileModel

      public static LalCompiled compileModel(LalModel model)
      Compile the full Cartesian state space.
    • compileModel

      public static LalCompiled compileModel(LalModel model, boolean reachableOnly, Long maxStates, Long maxDenseBytes)
      Compile the finite state space and labelled event matrices (Python compile_model).

      Matrices contain nonnegative event rates, including observable self-events. The generator excludes those self-events. Vanishing states (an immediate event enabled, or a vanishing state of an embedded LINE model) are eliminated by stochastic complementation: the generator and the label matrices are returned over the tangible states, and each label matrix credits the firings made inside vanishing excursions to the tangible state the excursion started from and the one it ends in. A model embedding a LINE object is always enumerated from its initial support.

      Parameters:
      reachableOnly - enumerate only states reachable from the initial support
      maxStates - reachable-state cap, or null
      maxDenseBytes - dense storage cap in bytes, or null