# DEVS Solver

The actual DEVS solvers containing the main DEVS implementation

class pypdevs.solver.Solver(listeners={})

  A unified DEVS solver, containing all necessary functions

  __init__(listeners={})

    Constructor

  atomicInit(aDEVS, time)

    AtomicDEVS function to initialise the model

    Parameters

      aDEVS – the model to initialise

  atomicOutputGeneration(aDEVS, time)

    AtomicDEVS function to generate output, invokes the outputFnc function of the model.

    Parameters

      - aDEVS – the AtomicDEVS model that generates the output

      - time – the time at which the output must be generated

    Returns

      dict – the generated output

  atomicOutputGenerationEventTracing(aDEVS, time)

    Wrapper for the AtomicDEVS output function, which will save event counts

    Parameters

      - aDEVS – the AtomicDEVS model that generates the output

      - time – the time at which the output must be generated

    Returns

      dict – the generated output

  coupledInit()

    CoupledDEVS function to initialise the model, calls all its _local_ children too.

  coupledOutputGeneration(time)

    CoupledDEVS function to generate the output, calls the atomicDEVS models where necessary. Output is routed too.

    Parameters

      time – the time at which output should be generated

    Returns

      the models that should be rescheduled

  coupledOutputGenerationClassic(time)

    CoupledDEVS function to generate the output, calls the atomicDEVS models where necessary. Output is routed too.

    Parameters

      time – the time at which output should be generated

    Returns

      the models that should be rescheduled

  massAtomicTransitions(trans, clock)

    AtomicDEVS function to perform all necessary transitions, does so on a collection of models for performance.

    Parameters

      - trans – iterable containing all models and their requested transition

      - clock – the time at which the transition must happen

  performDSDEVS(transitioning)

    Perform Dynamic Structure detection of the model

    Parameters

      transitioning – iteratable to be checked for a dynamic structure transiton