simulate_mc
Perform Monte-Carlo simulation with various methods
Description
Repeat to simulate a scenario drawn from a specific distribution with oracle/centralized receding horizon/distributed receding horizon schemes.
Syntax
MC_out = simulate_mc(scenario_generator,N_sim)
MC_out = simulate_mc(scenario_generator,N_sim,Name=Value)
Input Arguments
Name |
Type |
Description |
|---|---|---|
|
AbstractScenarioGenerator |
Scenario generator that generates scenarios |
|
positive integer |
Number of repeated simulations |
Name-Value Arguments
Name |
Type |
Description |
|---|---|---|
|
12 (default) | positive integer |
Number of time slots comprising the prediction horizon |
|
5000 (default) | nonnegative scalar |
Penalty parameter |
|
1 (default) | positive scalar |
Coupling gain (proportional) for distributed PI algorithm (Only for “dist”) |
|
1 (default) | positive scalar |
Coupling gain (integral) for distributed PI algorithm (Only for “dist”) |
|
400 (default) | positive scalar |
Length of time interval on which PI dynamics is executed (Only for “dist”) |
|
0.0005 (default) | positive scalar |
Stepsize for the Euler discritization of PI dynamics (Only for “dist”) |
|
0.05 (default) | positive scalar |
Cost function scaling factor for PI dynamics (Only for “dist”) |
|
40 (default) | positive integer |
Number of iterations for the distributed algorithm (Only for “dist”) |
|
30 (default) | positive integer |
Number of fractional iterations for the distributed algorithm (Only for “dist”) |
|
0.1 (default) | positive scalar |
Parameter for the distributed algorithm (Only for “dist”) |
|
0 (default) | scalar |
Parameter for the distributed algorithm (Only for “dist”) |
|
false (default) | logical |
On/off solver messages |
|
true (default) | logical |
Whether to perform oracle scheduling |
|
false (default) | logical |
Whether to perform centralized receding horizon scheduling |
|
false (default) | logical |
Whether to perform distributed receding horizon scheduling |
Output Arguments
Name |
Type |
Description |
|---|---|---|
|
struct |
Results including number of repetitions, charging schedules, cost, scenario information for each repetition, etc. |