示例#1
0
 public void RunMultipleStepByStep(SignalProgram signalProgram, int numberOfSimulations)
 {
     for (int i = 0; i < numberOfSimulations; i++)
     {
         RunStepByStep(signalProgram);
     }
     //
 }
示例#2
0
 /// <summary>
 /// Runs entire simulation step by step
 /// </summary>
 /// <param name="signalProgram">Current signal program</param>
 public void RunStepByStep(SignalProgram signalProgram)
 {
     simulationPeriod = COM.getSimulationPeriod(currentSimulation);
     simulationTime   = 0;
     for (int i = 0; i < (simulationPeriod * simulationResolution); i++)
     {
         SimulationStep(signalProgram);
         simulationTime = simulationTime + (1 / simulationResolution);
     }
     //GET SIMULATION RESULTS HERE
 }
示例#3
0
 /// <summary>
 /// Performs one sigle simulation step, and checks possible algorithms and implemenations
 /// </summary>
 public void SimulationStep(SignalProgram signalProgram)
 {
     try
     {
         currentSimulation.RunSingleStep();
         SensorCheck();
         signalProgram.Step(this.simulationResolution, vissimConnection.GetVissimInstance());
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }