forked from MWSL-UnB/HERMES
-
Notifications
You must be signed in to change notification settings - Fork 0
/
hermesMain.m
45 lines (37 loc) · 1.38 KB
/
hermesMain.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
function statistics = hermesMain( SETTINGS, rnd )
%HERMESMAIN function implements the main simulator drops loop
% syntax 1: statistics = hermesMain( SETTINGS, rnd )
%
% Inputs:
% SETTINGS: struct that contains all simulation parameters
% rnd: cell of randomStreams objects
%
% Outputs:
% statistics: object that contains all simulation statistics
%
% Author: Erika Portela Lopes de Almeida (EA), Fadhil Firyaguna (FF),
% Andre Noll Barreto (AB)
% Work Address: INDT Brasília
% E-mail: <erika.almeida>@indt.org.br,
% <fadhil.firyaguna, andre.noll>@indt.org
% History:
% v1.0 11 Feb 2015 - created (EA/FF)
% v2.0 28 Apr 2015 - added parameter check (AB)
%
% Copyright (c) 2015 INDT - Institute of Technology Development.
%
% The program may be used and/or copied only with the written
% permission of INDT, or in accordance with the terms and conditions
% stipulated in the agreement/contract under which the program has been
% supplied.
% verify if parameters are valid
parameterCheck.generalCheckParameters( SETTINGS );
% creates scenario object
scenario = scenario.Scenario( SETTINGS, rnd );
% creates the statistic object
statistics = simulatorCore.Statistics( SETTINGS );
% initializes the DropLoop object
simulationLoop = simulatorCore.DropLoop( SETTINGS );
% runs simulation loop
simulationLoop.runLoop( statistics, scenario );
end