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

Support negative start time in EnergyPlus #1938

Open
mwetter opened this issue May 12, 2020 · 10 comments
Open

Support negative start time in EnergyPlus #1938

mwetter opened this issue May 12, 2020 · 10 comments
Assignees
Labels
spawn Development for Spawn of EnergyPlus
Projects

Comments

@mwetter
Copy link
Member

mwetter commented May 12, 2020

The following command

simulateModel("Buildings.ThermalZones.EnergyPlus.Validation.OneZone", startTime=-864000, stopTime=864000, method="Cvode", tolerance=1e-06, resultFile="OneZone");

produces
image

@mwetter mwetter added the spawn Development for Spawn of EnergyPlus label May 12, 2020
@kbenne
Copy link
Contributor

kbenne commented May 13, 2020

What are the outside conditions when a simulation is started in a scenario like this with a negative start time? I need to correlate with a time in the weather file.

@mwetter
Copy link
Member Author

mwetter commented May 13, 2020

If the E+ weather file is from t=0 to t=365 days, then you can look up the outside conditions at t-365 days.

@kbenne
Copy link
Contributor

kbenne commented May 13, 2020

Yikes!

@mwetter
Copy link
Member Author

mwetter commented Jul 15, 2020

In FY21 AOP for NREL.

@mwetter mwetter added this to the Release 8.0 milestone Jul 29, 2020
@mwetter
Copy link
Member Author

mwetter commented Jul 29, 2020

Todo for the release:

  • On the Modelica side, issue an error if the simulation time is negative.

@mwetter mwetter removed this from the Release 8.0 milestone Jul 30, 2020
@mwetter mwetter changed the title Wrong results in Spawn if simulation starts at a negative time Support negative start time in EnergyPlus Jan 12, 2021
@mwetter mwetter added this to To do in Spawn Dec 1, 2021
@mwetter mwetter added this to the Release 9.0 milestone Feb 9, 2022
kbenne added a commit to NREL/Spawn that referenced this issue Apr 15, 2022
mwetter added a commit that referenced this issue May 2, 2022
mwetter added a commit that referenced this issue May 2, 2022
@mwetter
Copy link
Member Author

mwetter commented May 2, 2022

@kbenne : This issue is not yet fixed in the latest build that is merged through #2984

Commit 06cc58d on branch issue1938_spawn_negative_startTime adds the validation case Buildings/Resources/Scripts/Dymola/ThermalZones/EnergyPlus_9_6_0/Validation/RunPeriod/NegativeStartTime.mos which produces the following output:
image

@kbenne
Copy link
Contributor

kbenne commented May 2, 2022

Hmm. That's interesting. I can't perceive why it is doing this, although the testing I'm doing at my level doesn't attempt actual simulation. Take a look at the unit test in this commit.

I'll have to dig a bit deeper.

@mwetter
Copy link
Member Author

mwetter commented May 2, 2022

You may need to check if E+ does internally the right thing, for example by verifying that it picks the same weather data for t=-1 days as it does for t=364 days; or whether the simulations for these two day specifications produce the same indoor temperatures.

@kbenne
Copy link
Contributor

kbenne commented May 2, 2022

Yeah I certainly have some investigation to do. But the whole point of the strategy was that EnergyPlus would never actually see a negative time. I probably need to rig up a test that actually does simulation for day 364 and day -1, which will be a bit more involved.

Note how this so closely relates to #2453 because simulating day 364 actually requires EnergyPlus to simulate through the first 363 days to arrive at the start time.

@mwetter
Copy link
Member Author

mwetter commented May 4, 2022

Delay for later, not part of release 9.0.

Problem is that if simulation starts at -1 day, then week-day of Jan 1 must be the same as if it were to start on Jan 1.

@mwetter mwetter removed this from the Release 9.0 milestone May 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
spawn Development for Spawn of EnergyPlus
Projects
Spawn
To do
Development

No branches or pull requests

2 participants