Simulation phases details

Simulation time-step phases

The steps below outline the phases of execution in a standard Source run. 

Note the colouring convention used to represent the various Source phases:

River Operations

Plugins

Functions

Resource Assessment

       Environmental Flow Manager

Ordering phase

Run network

Ownership

Flow phase

The phases of execution followed in a standard run are:

  1. Start the simulation time-step.
  2. Read and Assign input values from a time series for the current time-step. For example, if the data source for an inflow node is a time series, then a value is read from the time series corresponding to the current time-step and assigned to the inflow node.
  3. Start River Operations: This overrides the values assigned from the input time series from the tabular view.
  4. Start the forecasting phase: Run the forecast models which do not use functions.
  5. Evaluate functions and modelled variables - where Time of Evaluation equals Start Of TimeStep
  6. River Operations override functions and forecast values: If River Operations is used, then:
    1. Override the values generated by functions.
    2. Override the values generated by forecast models.
  7. Plugins: All valid Source plugins will be notified before each simulation time-step is run.
  8. Resource Assessment Phase
    1. For each Resource Assessment System
      1. Evaluate functions and modelled variables - where Time of Evaluation equals Resource Assessment.  
      2. Process Resource Assessment System.
  9. Environmental Flow Manager Phase
  10. Water User and Constraint Phase
    1. Evaluate functions and modelled variables - where Time of Evaluation equals Water User & Constraint Phase and where the function is not used at a network element.
    2. Process Water Users: 
      1. Water User order calculations can be run in Parallel at this point in the ordering phase with the option enabled: "Process Water User Orders in Parallel": Scenario Options \ Performance
      2. For each Water User:
        1. Evaluate functions and modelled variables - where Time of Evaluation equals Water User and Constraints Phase, and where the function is used at this Water User.
        2. Calculate and distribute the demands of each Water user.
    3. Constraint Phase:
      1. For each Network Element:
        1. Evaluate functions and modelled variables - where Time of Evaluation equals Order Phase, and where the function is used at this network element.
        2. Calculate minimum and maximum constraints at each element and pass the constraints downstream.
  11. Ordering phase:
    1. Evaluate functions and modelled variables - where Time of Evaluation equals Order Phase and where the function is not used at a network element or is used at a Water User.
    2. Ordering Phase:
      1. For each Network Element:
        1. Evaluate functions and modelled variables - where Time of Evaluation equals Order Phase, and where the function is used at this network element.
        2. Calculate regulated orders and pass upstream.
        3. Calculate off allocation orders and pass upstream.
  12. Continue forecasting phase: Run the forecast models which do use functions.
  13. Flow Phase
    1. Evaluate functions and modelled variables - where Time of Evaluation equals Flow Phase and where the function is not used at a network element.
    2. Catchments can be all run in Parallel at this point in the flow phase with the option enabled: "Run Catchments in Parallel": Scenario Options \ Performance
    3. For each Network Element:
      1. Evaluate functions and modelled variables - where Time of Evaluation equals Flow Phase, and where the function is used at this network element
      2. Water Ownership - pre-timestep calculations
      3. Off Allocation: Generate storage release requests to distribute allocated volume to according to shares
      4. The wetland cluster that the element belongs to is solved for this time-step.
      5. Execute element flow phase calculations
      6. Water Ownership - post-timestep calculations, and colouring of water
      7. Calculate Constraint Factors for element
      8. Constituent modeling is executed.
  14. Evaluate functions and modelled variables - where Time of Evaluation equals Post Flow Phase.
  15. Resource Assessment Post TimeStep Phase.
  16. Finalise constituent modeling (marker routing)
  17. End of the forecasting phase.
  18. Evaluate functions and modelled variables - where Time of Evaluation equals End of TimeStep.
  19. Evaluate modelled variables - where Time of Evaluation equals Post Function Evaluation.
  20. Recording phase: Writes the current time-step results to the requested recorders.
  21. Plugins: All valid Source plugins will be notified after every simulation time-step is run.
  22. End of the simulation time-step.