Skip to content

Commit

Permalink
Remove unused class computeTimeStepLevel
Browse files Browse the repository at this point in the history
  • Loading branch information
flomnes committed Sep 11, 2024
1 parent de425d1 commit 8c4508b
Showing 1 changed file with 0 additions and 66 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -324,72 +324,6 @@ struct ENERGIES_ET_PUISSANCES_HYDRAULIQUES
bounding constraint on final level*/
};

class computeTimeStepLevel
{
private:
int step;
double level;

double capacity;
std::vector<double>& inflows;
std::vector<double>& ovf;
std::vector<double>& turb;
double pumpRatio;
std::vector<double>& pump;
double excessDown;

public:
computeTimeStepLevel(const double& startLvl,
std::vector<double>& infl,
std::vector<double>& overfl,
std::vector<double>& H,
double pumpEff,
std::vector<double>& Pump,
double rc):
step(0),
level(startLvl),
capacity(rc),
inflows(infl),
ovf(overfl),
turb(H),
pumpRatio(pumpEff),
pump(Pump),
excessDown(0.)
{
}

void run()
{
excessDown = 0.;

level = level + inflows[step] - turb[step] + pumpRatio * pump[step] - ovf[step];

if (level > capacity)
{
level = capacity;
}

if (level < 0)
{
excessDown = -level;
level = 0.;
inflows[step] += excessDown;
}
}

void prepareNextStep()
{
step++;

inflows[step] -= excessDown;
}

double getLevel()
{
return level;
}
};

struct RESERVE_JMOINS1
{
std::vector<double> ReserveHoraireJMoins1;
Expand Down

0 comments on commit 8c4508b

Please sign in to comment.