nikhilgupta10 / GridLAB-D

Other
1 stars 0 forks source link

#844 house and triplex meter power inconsistent, #2572

Closed nikhilgupta10 closed 7 years ago

nikhilgupta10 commented 7 years ago

Hello, I am running a simple model with one house which only contains a water heater (physical model) and implicit end uses are turned off. The triplex meter upstream of the house (with the house being the only child to that meter), reports measured real power that is lower than the total_load output of the house when the water heater is on. For example, when only the water heater is on, i.e., HVAC system not running in the house, the water heater and the house both report 4.5kW, but the triplex meter reports only 3.96kW. When only the HVAC system is running, the house and meter both report 3.021kW, so it seems to be related to the water heater. I am running GridLAB-D 3.0.0-4711 (Hatwai) 64-bit MACOSX RELEASE. Thank you for your help.

Files attached.,

nikhilgupta10 commented 7 years ago

nikhilgupta10 imported these comments from Sourceforge: The user was set to null. Therefore assigning this to afisher1. "dchassin":(Copied from forum thread https://sourceforge.net/p/gridlab-d/discussion/842562/thread/e9db73c4)

I traced the power updates from house to recorder and make the following preliminary observations.

The value of \panel.power\ (called total.power in house_e.cpp) seems to be always correct (complex value has non-zero imaginary part), so internally the computations appear correct.

However when the value is sampled by the recorder it has been changed so that the real power looks like a magnitude and the imaginary part is zero. This makes me suspect that there is an assignment operation somewhere between when house_e::sync runs and recorder::sync runs that is casting the complex to a double.

What I don't understand is what would be doing that. No other object is supposed to write the panel power value except house and after the house sync returns the value seems correct. Recorder only reads the value and by the time it sees it, the damage is done.

One candidate to exclude is the enduse property itself which is the container for the panel power value. It has code for a sync pass that does some power manipulations for shaped enduses (which the HVAC enduse load certainly is not). I checked and only presync is running in this case (which is correct), so that's probably not the cause.

That leaves me to suspect that triplex_meter is changing the value, which seems highly unlikely. I know triplex_meter does some polar conversions but I think only for voltages and not powers, and then only for its own copies. Besides, the behavior looks much more like casting than polar conversion because the imaginary part is zero after the conversion. If it were polar, it would still have a non-zero angle (reactive power is non-zero) and the notation would no longer be \j.,

"andyfisher":I took the file given and have determined that the reason that there has been a misinterpretation of the properties being compared. The HVAC and the waterheater are both contained on the 240 circuit. The values represented by panel.power, hvac_load, and total_load all either represent the magnitude of all the enduse loads in the house (panel.power, total_load) or the magnitude of just the HVAC (hvac_load) at nominal voltage (120/240 V). None of these properties take into account the actual voltage seen at the meter and the zip components of each enduse. For example, The constant current and constant impedance portions of the load will rise and fall as the voltage rises and falls. The waterheater is modeled as a constant impedance load. The HVAC ZIP fractions vary between auxiliary, heatpump, and electric.Before being passed to the meter each ZIP component of the load is calculated based off of the meter voltage and passed to the the meter internally. The one property inside of house that does take these factors into account is hvac_power. I took the liberty of rerunning the example provided in this ticket showing the different outputs from the meter, house, and waterheater. Please note that panel.constant_power, panel.constant_admittance, and panel.constant_current are the ZIP portions of the complex load of the house and other enduse loads at (120/240 V).,

"andyfisher":- status: new --> closed ,

"jcfuller":- Resolution: none --> documented ,