Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default max battery charge percentage of 90% #133

Merged
merged 1 commit into from
Oct 5, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions src/opti-lib/src/BatterySimulation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,13 @@ double BatterySimulation::iter_get_load(double inp, double out, double hours)
//num_overvolted += 1 + diff * 2;
num_overvolted += 1 + diff;
//num_overvolted += GMat().Pow(1 + diff, 1.01);

// Warning: You may do this only AFTER the penalty was calculated.
// It will however impact the penalty in the NEXT iteration, which is very bad.
if (load > pars.MAX_CAPACITY_AMPH)
{
//load -= inp * m_mulPowerToCapacity;
}
}
if (load < pars.MIN_LOAD_AMPH)
{
Expand Down
1 change: 1 addition & 0 deletions src/opti-lib/src/ConfigSol.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ using namespace EnjoLib;
ConfigSol::~ConfigSol(){}
ConfigSol::ConfigSol()
{
BATTERY_CHARGE_MAX_PERCENTAGE = 0.90;
}

EnjoLib::Str ConfigSol::GetFileNameProt() const
Expand Down