Antares Simulator
Power System Simulator
loldCsr.h
1 /*
2 ** Copyright 2007-2023 RTE
3 ** Authors: Antares_Simulator Team
4 **
5 ** This file is part of Antares_Simulator.
6 **
7 ** Antares_Simulator is free software: you can redistribute it and/or modify
8 ** it under the terms of the GNU General Public License as published by
9 ** the Free Software Foundation, either version 3 of the License, or
10 ** (at your option) any later version.
11 **
12 ** There are special exceptions to the terms and conditions of the
13 ** license as they are applied to this software. View the full text of
14 ** the exceptions in file COPYING.txt in the directory of this software
15 ** distribution
16 **
17 ** Antares_Simulator is distributed in the hope that it will be useful,
18 ** but WITHOUT ANY WARRANTY; without even the implied warranty of
19 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 ** GNU General Public License for more details.
21 **
22 ** You should have received a copy of the GNU General Public License
23 ** along with Antares_Simulator. If not, see <http://www.gnu.org/licenses/>.
24 **
25 ** SPDX-License-Identifier: licenceRef-GPL3_WITH_RTE-Exceptions
26 */
27 #pragma once
28 
29 #include "lold_base.h"
30 
31 namespace Antares::Solver::Variable::Economy
32 {
33 
35 {
36  static std::string Caption()
37  {
38  return "LOLD CSR";
39  }
40 
41  static std::string Description()
42  {
43  return "LOLD for CSR";
44  }
45 
46  static bool checkCondition(const State& state)
47  {
48  return state.hourlyResults->ValeursHorairesDeDefaillancePositiveCSR[state.hourInTheWeek]
49  > 0.5;
50  }
51 };
52 
54 
55 template<class NextT = Container::EndOfList>
57 
58 } // namespace Antares::Solver::Variable::Economy
Base class for economy variables like LOLP and LOLD.
Definition: economy_base.h:100
Definition: state.h:71
unsigned int hourInTheWeek
Current hour in the week (zero-based)
Definition: state.h:150