![]() |
Documentation of UrbanFireXDT
Documentation of UrbanFireXDT
|
Functions | |
| bool | oneStep (const unsigned long ts, const double totalBatteryCapacity_kWh, CUControllerThreadGroupManager *thread_manager=NULL, const char *output_prefix="", std::vector< ControlUnit * > *subsection=NULL) |
| bool | runSimulationForOneParamSetting (CUControllerThreadGroupManager *thread_manager=NULL, std::vector< ControlUnit * > *subsection=NULL, const char *output_prefix="") |
| bool | runSimulationForAllVariations (const unsigned long scenario_id, CUControllerThreadGroupManager *thread_manager=NULL) |
| bool | runSimulationFAVsAndSAC (float expansion_matrix_rel_freq[16][16], unsigned long expansion_matrix_abs_freq[16][16], const unsigned long scenario_id) |
| Runs the complete simulation for all parameter variations and add sim. added components to the CUs. | |
| bool | runCompleteSimulation (float expansion_matrix_rel_freq[16][16], unsigned long expansion_matrix_abs_freq[16][16], const unsigned long scenario_id) |
| bool simulation::oneStep | ( | const unsigned long | ts, |
| const double | totalBatteryCapacity_kWh, | ||
| CUControllerThreadGroupManager * | thread_manager = NULL, |
||
| const char * | output_prefix = "", |
||
| std::vector< ControlUnit * > * | subsection = NULL |
||
| ) |
Runs one step of the simulation. Should only be called by simulation::runSimulationForOneParamSetting().
Attention: If a thread_manager is given, the subsection-argument is ignored! Thus, the thread manager must be initialized with the subsection!
| ts | current time step (starting from 1) |
| totalBatteryCapacity_kWh | Total capacity over all batteries in kWh; required for computation of overall BS SOC |
| thread_manager | If multi-threading is active, an existing thread manager can be passed. |
| output_prefix | (optional, default "") A prefix that should be added to the output file names |
| subsection | (optional, default NULL) Execut the simulation for the current step only for a given sub-set of all known control units |
| bool simulation::runCompleteSimulation | ( | float | expansion_matrix_rel_freq[16][16], |
| unsigned long | expansion_matrix_abs_freq[16][16], | ||
| const unsigned long | scenario_id | ||
| ) |
Run the complete simulation for a given scenario. If cmd-line argument 'repetitions' is set to a value higher 1, this function will handel this point. It will call runSimulationFAVsAndSAC(...). It also initializes the global output directory.
| expansion_matrix_rel_freq | reference to the exp. matrix with relative values |
| expansion_matrix_abs_freq | reference to the exp. matrix with absolute values |
| scenario_id | scenario id to use |
| bool simulation::runSimulationFAVsAndSAC | ( | float | expansion_matrix_rel_freq[16][16], |
| unsigned long | expansion_matrix_abs_freq[16][16], | ||
| const unsigned long | scenario_id | ||
| ) |
Runs the complete simulation for all parameter variations and add sim. added components to the CUs.
This function is called by simulation::runSimulationFAVsAndSAC(). It starts the SAC (simulatively added components) planning and then run the simulation for all parameter variations (FAVs). It also initializes the thread group manager for the main run of the simulation (i.e., NOT for the SAC planning, this is done by the SAC planning function itselfe) if multi-processing is selected.
| bool simulation::runSimulationForAllVariations | ( | const unsigned long | scenario_id, |
| CUControllerThreadGroupManager * | thread_manager = NULL |
||
| ) |
Runs the simulation for all parameter variations. If no variations as selected, it will only call simulation::runSimulationForOneParamSetting() once. This function also handels the correct initialization of the output folders.
| bool simulation::runSimulationForOneParamSetting | ( | CUControllerThreadGroupManager * | thread_manager = NULL, |
| std::vector< ControlUnit * > * | subsection = NULL, |
||
| const char * | output_prefix = "" |
||
| ) |
Runs the simulation for the complete defined time span for one parameter setting and one repetition. It can be either called by simulation::runSimulationForAllVariations() or during the initialization phase for the SAC planning. This function creates a a thread manager object, if multi-threading is selected and no existing thread manager instance is passed.
| thread_manager | If multi-threading is active, an existing thread manager can be passed. |
| subsection | If not NULL, the simulation is only executed for the given control units |
| output_prefix | The prefix for stdout information. If not empty, if changes the writing to stdout. |