Skip to content

voltage_table_t::calculate_max_discharge_w breaks dispatch constraints #565

@brtietz

Description

@brtietz

Lead acid batteries using the voltage table can export to grid, since the dispatch current can be greater than the load. The root cause of the issue is that voltage_table_t::calculate_max_discharge_w specifies unreasonably high output currents, and this is the last constraint that is enforced.

Unclear whether this is a units issue with qmax, or something else. A brute force solution would be to enforce dod is >0 and <100 in the function.

To Reproduce
Steps to reproduce the behavior:

  1. Create a PV-Battery residential case with a lead acid battery that uses the voltage table
  2. Run the model with any dispatch
  3. Note that (a) the SOC goes well below the SOC limits specified on the dispatch page, and (b) the electricity from the battery is greater than the load, meaning this constraint is violating other constraints.

Expected behavior
voltage_table_t::calculate_max_discharge_w should respect charge limits specified in the dispatch functions.

Screenshots
Peak shaving:

image

Specified limits:

image

Desktop (please complete the following information):

  • Version 2020.11.29 r1 - problem exists on patch, and the code is the same on develop.

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions