Loading [MathJax]/extensions/tex2jax.js
Antares Simulator
Power System Simulator
All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Modules Pages Concepts
Antares::Data::Parameters Class Referencefinal

General data for a study. More...

#include <parameters.h>

Classes

struct  Compatibility
 
struct  IncludeOptions
 
struct  RenewableGeneration
 
struct  UCMode
 

Public Member Functions

Simulation mode
bool economy () const
 Get if the simulation is in economy mode.
 
bool adequacy () const
 Get if the simulation is in adequacy mode.
 
void resetPlaylist (uint nbOfYears)
 Reset the playlist (played years and associated years)
 
bool loadFromFile (const std::filesystem::path &filename, const StudyVersion &version)
 Load data from a file.
 
bool loadFromINI (const IniFile &ini, const StudyVersion &version)
 Load data from an INI file.
 
void prepareForSimulation (const StudyLoadOptions &options)
 Prepare all settings for a simulation.
 
bool saveToFile (const AnyString &filename) const
 Save data to an ini file.
 
bool isTSGeneratedByPrepro (const TimeSeriesType ts) const
 Get if a time-series must be generated by the preprocessor.
 
void reset ()
 Reset to default all values in a structure for general data.
 
void resetSeeds ()
 Reset to default all seeds.
 
void resetThresholdsAdqPatch ()
 Reset to default all threshold values in adequacy patch.
 
void resetAdqPatchParameters ()
 Reset to default all adequacy patch values.
 
void handleOptimizationOptions (const StudyLoadOptions &options)
 Handle priority between command-line option and configuration file.
 
void fixBadValues ()
 Try to detect then fix any bad value.
 
void validateOptions (const StudyLoadOptions &)
 
void fixRefreshIntervals ()
 Try to detect then fix refresh intervals.
 
void fixGenRefreshForNTC ()
 Try to detect then fix TS generation/refresh parameters for NTC.
 
void resetYearsWeigth ()
 Reset MC year weight to 1 for all years.
 
std::vector< float > getYearsWeight () const
 Get MC years weight dependending on playlist configuration.
 
float getYearsWeightSum () const
 Get MC years weight sum dependending on playlist configuration.
 
void setYearWeight (uint year, float weight)
 Define weight for a MC year.
 
bool haveToImport (int tsKind) const
 
void saveToINI (IniFile &ini) const
 Save the internal settings into an INI file.
 

Public Attributes

Mode
SimulationMode mode
 Mode of the study (adequacy, economy...)
 
Horizon
Yuni::String horizon
 Horizon year, not used by the solver.
 
Calendar
uint nbYears
 Number of years to study.
 
Date::DayInterval simulationDays
 Simulation days interval.
 
DayOfTheWeek dayOfThe1stJanuary
 Day of the 1st january.
 
DayOfTheWeek firstWeekday
 First day in the week.
 
MonthName firstMonthInYear
 The first month of the simulation year.
 
bool leapYear
 Leap year.
 
Additional
bool yearByYear
 Export results each year.
 
bool derated
 Derated.
 
bool useCustomScenario
 Custom scenario.
 
bool userPlaylist
 Custom playlist (each year will be manually selected by the user)
 
std::vector< bool > yearsFilter
 Flag to perform the calculations or not from the solver.
 
bool thematicTrimming
 Custom variable selection (each variable will be manually selected for print by the user)
 
AllVariablesPrintInfo variablesPrintInfo
 List of all output variables print info.
 
uint effectiveNbYears
 The number of years that will be really performed.
 
bool geographicTrimming
 
TimeSeries
uint nbTimeSeriesLoad
 Nb of timeSeries : Load.
 
uint nbTimeSeriesHydro
 Nb of timeSeries : Hydro.
 
uint nbTimeSeriesWind
 Nb of timeSeries : Wind.
 
uint nbTimeSeriesThermal
 Nb of timeSeries : Thermal.
 
uint nbTimeSeriesSolar
 Nb of timeSeries : Solar.
 
Time-series refresh
uint timeSeriesToRefresh
 Time series to refresh on-line.
 
uint refreshIntervalLoad
 Refresh interval (in years) for timeSeries : Load.
 
uint refreshIntervalHydro
 Refresh interval (in years) for timeSeries : Hydro.
 
uint refreshIntervalWind
 Refresh interval (in years) for timeSeries : Wind.
 
uint refreshIntervalThermal
 Refresh interval (in years) for timeSeries : Thermal.
 
uint refreshIntervalSolar
 Refresh interval (in years) for timeSeries : Solar.
 
Archives
uint timeSeriesToArchive
 TimeSeries to archive.
 
Pre-Processor
uint timeSeriesToGenerate
 TimeSeries to generate.
 
Import Time-Series to HardDrive
uint exportTimeSeriesInInput
 TimeSeries to Import.
 
Correlated draws
uint intraModal
 TimeSeries where the draws are correlated.
 
uint interModal
 Inter-modal.
 
Timeseries numbers
bool storeTimeseriesNumbers
 Store the sampled timeseries numbers.
 
bool readonly
 Read-only mode.
 
bool synthesis
 Write the simulation synthesis into the output.
 
Optimization
bool spillageBound
 Spillage bound.
 
bool improveUnitsStartup
 Improve units startup.
 
uint timeSeriesAccuracyOnCorrelation
 Accuracy on correlation.
 
Optimization preferences
struct Antares::Data::Parameters::IncludeOptions include
 
Compatibility compatibility
 
struct { 
 
   SheddingPolicy   policy 
 Shedding policy.
 
shedding 
 
struct { 
 
   PowerFluctuations   fluctuations 
 Power fluctuations.
 
power 
 
UCMode unitCommitment
 
struct { 
 
   NumberOfCoresMode   ncMode 
 Number of Cores Mode.
 
nbCores 
 
RenewableGeneration renewableGeneration
 
struct { 
 
   HydroHeuristicPolicy   hhPolicy 
 Hydro heuristic policy.
 
hydroHeuristicPolicy 
 
struct { 
 
   HydroPricingMode   hpMode 
 Hydro Pricing Mode.
 
hydroPricing 
 
GlobalTransmissionCapacities transmissionCapacities
 Transmission capacities.
 
SimplexOptimization simplexOptimizationRange
 Simplex optimization range (day/week)
 
AdequacyPatch::AdqPatchParams adqPatchParams
 
Scenariio Builder - Rules
RulesScenarioName activeRulesScenario
 The current active rules for building scenarios (useful if building mode == custom)
 
Output
bool noOutput = false
 No output.
 
bool hydroDebug
 

Seeds

uint seed [seedMax]
 Seeds.
 
ResultFormat resultFormat = legacyFilesDirectories
 
bool namedProblems
 
Antares::Solver::Optimization::OptimizationOptions optOptions
 

Detailed Description

General data for a study.

Those data are located into the file generalData.ini

Member Function Documentation

◆ getYearsWeight()

std::vector< float > Antares::Data::Parameters::getYearsWeight ( ) const

Get MC years weight dependending on playlist configuration.

Returns
std::vector<float> with weight for each MC year

◆ getYearsWeightSum()

float Antares::Data::Parameters::getYearsWeightSum ( ) const

Get MC years weight sum dependending on playlist configuration.

Returns
weigth sum (nbYears if playlist disabled). If playlist is enabled and years weight sum is null, 1.0 is returned to avoid division by 0

◆ isTSGeneratedByPrepro()

bool Antares::Data::Parameters::isTSGeneratedByPrepro ( const TimeSeriesType ts) const

Get if a time-series must be generated by the preprocessor.

Parameters
maskThe time-serie to test
Returns
True if the time-series must be generated by the preprocessor, false otherwise

◆ loadFromFile()

bool Antares::Data::Parameters::loadFromFile ( const std::filesystem::path & filename,
const StudyVersion & version )

Load data from a file.

This routine ensures that the structure is properly initialized with default values, whatever is the result. If the filename is empty, or it does not exists, or the file can not be opened, the routine will return 0.

Parameters
filenameThe file to load
versionCurrent study version
Returns
True if the settings have been loaded, false if at least one error has occured

◆ prepareForSimulation()

void Antares::Data::Parameters::prepareForSimulation ( const StudyLoadOptions & options)

Prepare all settings for a simulation.

The solver must be able to rely on all variables for performance reasons. The first case scenario can be the user who might not have disabled all settings, like the refresh, that can have a non-zero value even if the ts-generator is disabled. Another case would be the directives given by the command line.

Note
This method is automatically called from loadFromFile() if the flag options.usedByTheSolver is set.
See also
loadFromFile()

◆ saveToFile()

bool Antares::Data::Parameters::saveToFile ( const AnyString & filename) const

Save data to an ini file.

Parameters
filenameThe target filename
Returns
True if the file has been successfully saved, false otherwise

◆ setYearWeight()

void Antares::Data::Parameters::setYearWeight ( uint year,
float weight )

Define weight for a MC year.

Parameters
yearMC year index
weightMC year weight

Member Data Documentation

◆ exportTimeSeriesInInput

uint Antares::Data::Parameters::exportTimeSeriesInInput

TimeSeries to Import.

This value is a mask bits for timeSeries. All generated timeseries will be re-written into the input

See also
TimeSeries

◆ geographicTrimming

bool Antares::Data::Parameters::geographicTrimming

Enable/Disable filtering by files : for an area or a link, print (or not) a file associated to :

  • a time division (hourly results, daily results, weekly results, ...),
  • a kind of result (year by year result or a synthesis result).

◆ intraModal

uint Antares::Data::Parameters::intraModal

TimeSeries where the draws are correlated.

This value is a mask bits for timeSeries.

See also
TimeSeries This is the historical correlation mode

◆ readonly

bool Antares::Data::Parameters::readonly

Read-only mode.

This value can only be set by the property read-only in the generaldata.ini. The default value is false.

◆ timeSeriesToArchive

uint Antares::Data::Parameters::timeSeriesToArchive

TimeSeries to archive.

Only generated timeSeries will be archived. This value is a mask bits for timeSeries.

See also
TimeSeries

◆ timeSeriesToGenerate

uint Antares::Data::Parameters::timeSeriesToGenerate

TimeSeries to generate.

This value is a mask bits for timeSeries.

See also
TimeSeries

◆ timeSeriesToRefresh

uint Antares::Data::Parameters::timeSeriesToRefresh

Time series to refresh on-line.

This value is a mask bits for timeSeries

See also
TimeSeries

The documentation for this class was generated from the following files: