Skip to content

Add DesignSpecification:OutdoorAir field and control to terminal units and fix DOA airflow distribution to ZoneHVAC units#6223

Merged
rraustad merged 15 commits intodevelopfrom
148704793-Improvements-to-Ventilation-Control-for-DOAS-AirLoop-#6205
Aug 16, 2017
Merged

Add DesignSpecification:OutdoorAir field and control to terminal units and fix DOA airflow distribution to ZoneHVAC units#6223
rraustad merged 15 commits intodevelopfrom
148704793-Improvements-to-Ventilation-Control-for-DOAS-AirLoop-#6205

Conversation

@lgu1234
Copy link
Copy Markdown
Contributor

@lgu1234 lgu1234 commented Jul 26, 2017

Pull request overview

Address #6205, add DesignSpecification:OutdoorAir field and control to AirTerminal:SingleDuct:Uncontrolled and AirTerminal:SingleDuct:Mixer.

And address #6020 to correct the distribution of DOA primary air to ZoneHVAC units when using AirTerminal:SingleDuct:Mixer.

Address #6225, add more choices of Outdoor Air Method in DesignSpecification:OutdoorAir

Work Checklist

Add to this list or remove from it as applicable. This is a simple templated set of guidelines.

  • Title of PR should be user-synopsis style (clearly understandable in a standalone changelog context)
  • At least one of the following appropriate labels must be added to this PR to be consumed into the changelog:
    • Defect: This pull request repairs a github defect issue. The github issue should be referenced in the PR description
    • Refactoring: This pull request includes code changes that don't change the functionality of the program, just perform refactoring
    • NewFeature: This pull request includes code to add a new feature to EnergyPlus
    • Performance: This pull request includes code changes that are directed at improving the runtime performance of EnergyPlus
    • DoNoPublish: This pull request includes changes that shouldn't be included in the changelog

Review Checklist

This will not be exhaustively relevant to every PR.

  • Code style (parentheses padding, variable names)
  • Functional code review (it has to work!)
  • If defect, results of running current develop vs this branch should exhibit the fix
  • CI status: all green or justified
  • Performance: CI Linux results include performance check -- verify this
  • Unit Test(s)
  • C++ checks:
    • Argument types
    • If any virtual classes, ensure virtual destructor included, other things
  • IDD changes:
    • Verify naming conventions and styles, memos and notes and defaults
    • Open windows IDF Editor with modified IDD to check for errors
    • If transition, add rules to spreadsheet
    • If transition, add transition source
    • If transition, update idfs
  • If new idf included, locally check the err file and other outputs
  • Documentation changes in place
  • Changed docs build successfully
  • ExpandObjects changes?
  • If output changes, including tabular output structure, add to output rules file for interfaces

@lgu1234 lgu1234 changed the title 148704793 Add DesignSpecification:OutdoorAir field and control to terminal units #6205#6205 148704793 Add DesignSpecification:OutdoorAir field and control to terminal units #6205 Jul 27, 2017
@mjwitte mjwitte changed the title 148704793 Add DesignSpecification:OutdoorAir field and control to terminal units #6205 Add DesignSpecification:OutdoorAir field and control to terminal units Jul 27, 2017
Copy link
Copy Markdown
Contributor

@mjwitte mjwitte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lgu1234 @EnergyArchmage Some initial comments on the code.

//Load the maximum volume flow rate
DirectAir( DirectAirNum ).MaxAirVolFlowRate = rNumericArgs( 1 );

//TRANE BEG : load OA design spec
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lgu1234 I think these types of comments should be removed before final merge.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte Done.


if ( ControlledZoneNum > 0 ) { //TRANE
if ( DataZoneEquipment::ZoneEquipConfig( ControlledZoneNum ).AirLoopNum > 0 ) { //TRANE
DirectAir( DirectAirNum ).AirLoopNum = DataZoneEquipment::ZoneEquipConfig( ControlledZoneNum ).AirLoopNum; //TRANE
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@EnergyArchmage Are we sure AirLoopNum has been set yet at this point?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte Yes.

if ( DirectAir( DirectAirNum ).ZoneEqNum > 0) {
airLoopNum =ZoneEquipConfig( DirectAir( DirectAirNum ).ZoneEqNum ).AirLoopNum;
}
if ( airLoopNum > 0 ) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not use DirectAir.AirLoopNum directly here instead of getting it from ZoneEquipConfig?
Why test for airLoopNum>0 every iteration? A terminal unit doesn't make any sense without an airloop, so that should be tested up front in an init and be a fatal error if it's zero.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte The call of CalcDesignSpecificationOutdoorAir in InitDirectAir can be before the AirLoopNum is assigned after sizing. Therefore, the check is necessary during sizing.

mDotFromOARequirement = min( mDotFromOARequirement , DirectAir( DirectAirNum ).AirMassFlowRateMax );
} else {
mDotFromOARequirement = DirectAir( DirectAirNum ).AirMassFlowRateMax;
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure this is what users will expect to happen if the OA damper is shut off and the airloop is still running, then it goes to max flow. I haven't looked at the doc changes yet - this can stay as long as it's documented well, but we should check with TW to see if this meets expectations.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte It may happen occasionally. Line 514 may not be necessary, Line 500 is:

		mDotFromOARequirement = DirectAir( DirectAirNum ).AirMassFlowRateMax;

However, I am not sure if the value should be Max or Min. If we assume it is DOAS, then it should be min.

Node( ZoneNode ).MassFlowRateMaxAvail = DirectAir( DirectAirNum ).AirMassFlowRateMax;
} else { //TRANE DCV
Node( ZoneNode ).MassFlowRate = mDotFromOARequirement; //TRANE DCV
Node( ZoneNode ).MassFlowRateMaxAvail = mDotFromOARequirement; //TRANE DCV
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't MaxAvail always be AirMassFlowRateMax at this point?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte MassFlowRateMaxAvail is used in InitATMixer. In order to be consistent, we may use the same.

Node( ZoneNode ).MassFlowRate = min( Node( ZoneNode ).MassFlowRate, Node( ZoneNode ).MassFlowRateMax ); //TRANE DCV
Node( ZoneNode ).MassFlowRate = max( Node( ZoneNode ).MassFlowRate, Node( ZoneNode ).MassFlowRateMinAvail ); //TRANE DCV
Node( ZoneNode ).MassFlowRate = max( Node( ZoneNode ).MassFlowRate, Node( ZoneNode ).MassFlowRateMin ); //TRANE DCV
} //TRANE DCV
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If nothing else, this could be simplified by setting Node.MassFlowRate to either MassFlowRateMax or mDotFromOARequirement, and then apply all the constraints with a single block of code.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte Here is my thought:

					Node( ZoneNode ).MassFlowRate = min( mDotFromOARequirement, Node( ZoneNode ).MassFlowRateMaxAvail, Node( ZoneNode ).MassFlowRateMax );
					Node( ZoneNode ).MassFlowRate = max( Node( ZoneNode ).MassFlowRate, Node( ZoneNode ).MassFlowRateMin, Node( ZoneNode ).MassFlowRateMinAvail );

if ( MyEnvrnFlag( ATMixerNum ) ) {
if ( ZoneEquipConfig( SysATMixer( ATMixerNum ).ZoneEqNum ).AirLoopNum > 0 ) {
SysATMixer( ATMixerNum ).AirLoopNum = ZoneEquipConfig( SysATMixer( ATMixerNum ).ZoneEqNum ).AirLoopNum;
MyEnvrnFlag( ATMixerNum ) = false;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like this would be a place to check if AirLoopNum == 0 then throw a fatal error, then the later if AirlloopNum > 0 tests can all be removed.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte The InitATMixer is called before AirLoopNum is assigned. This check may be needed.

if ( airLoopOAFrac > 0.0 ) {
Real64 vDotOAReq = CalcDesignSpecificationOutdoorAir( SysATMixer( ATMixerNum ).OARequirementsPtr, SysATMixer( ATMixerNum ).ZoneNum, true, true );
Real64 rhoAir = PsyRhoAirFnPbTdbW( Node( SysATMixer( ATMixerNum ).PriInNode ).Press, Node( SysATMixer( ATMixerNum ).PriInNode ).Temp, Node( SysATMixer( ATMixerNum ).PriInNode ).HumRat );
mDotFromOARequirement = vDotOAReq * rhoAir / airLoopOAFrac;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be StdRhoAir, no? Most places that call CalcDesingSpecificationOutdoorAir apply StdRhoAir, but only one does not. That maybe should be fixed.
StdRhoAir - DualDuct, PurchasedAir, SingleDuct VAV, ZoneEquipmentManager (sizing)
local density - FanCoil

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte I agree as long as @EnergyArchmage is OK.

if ( airLoopOAFrac > 0.0 ) {
Real64 vDotOAReq = DataZoneEquipment::CalcDesignSpecificationOutdoorAir( DirectAir( DirectAirNum ).OARequirementsPtr, DirectAir( DirectAirNum ).ZoneNum, true, true );
Real64 rhoAir = PsyRhoAirFnPbTdbW( Node( DirectAir( DirectAirNum ).ZoneSupplyAirNode ).Press, Node( DirectAir( DirectAirNum ).ZoneSupplyAirNode ).Temp, Node( DirectAir( DirectAirNum ).ZoneSupplyAirNode ).HumRat );
mDotFromOARequirement = vDotOAReq * rhoAir / airLoopOAFrac;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be StdRhoAir (see more detailed comment below).

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte Agree. The Controller:MechanicalVentilation uses StdRhoAIr to get mass flow rate. It will be consistent everywhere. @EnergyArchmage What do you think?


if ( FirstHVACIteration ) {
Node( SysATMixer( ATMixerNum ).PriInNode ).MassFlowRate = mDotFromOARequirement; //TRANE DCV
Node( SysATMixer( ATMixerNum ).PriInNode ).MassFlowRateMaxAvail = mDotFromOARequirement; //TRANE DCV
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think MassFlowRateMaxAvail should be DesignPrimaryAirVolRate*StdRhoAir here.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte I found differences. I am going to do more testing.

@mjwitte
Copy link
Copy Markdown
Contributor

mjwitte commented Jul 28, 2017

@Myoldmopar When running units tests with this branch serially on Win64-debug, I'm getting a failure from the #6209 unit test:

[----------] 1 test from ZoneIdealLoadsTest
[ RUN      ] ZoneIdealLoadsTest.IdealLoads_PlenumTest
Assertion failed: contains( i ), file C:\MJW-Work\EnergyPlus Git\EnergyPlus-ReviewBranch\third_party\ObjexxFCL\src\ObjexxFCL/Array1.hh, line 1172

Suspect develop may have the same issue.

@mjwitte
Copy link
Copy Markdown
Contributor

mjwitte commented Jul 28, 2017

@Myoldmopar @jasondegraw Found the problem with the ZoneIdealLoadsTest unit test. Will add it to #6216

@mjwitte mjwitte changed the title Add DesignSpecification:OutdoorAir field and control to terminal units Add DesignSpecification:OutdoorAir field and control to terminal units and fix DOA mixer airflow distribution Jul 31, 2017
@mjwitte mjwitte changed the title Add DesignSpecification:OutdoorAir field and control to terminal units and fix DOA mixer airflow distribution Add DesignSpecification:OutdoorAir field and control to terminal units and fix DOA airflow distribution to ZoneHVAC units Jul 31, 2017
@mjwitte mjwitte added Defect Includes code to repair a defect in EnergyPlus NewFeature Includes code to add a new feature to EnergyPlus IDDChange Code changes impact the IDD file (cannot be merged after IO freeze) labels Jul 31, 2017
@mjwitte mjwitte added this to the EnergyPlus 8.8.0 milestone Jul 31, 2017
Copy link
Copy Markdown
Member

@Myoldmopar Myoldmopar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall this seems good. The only real work I can spot from looking over the code is to clean up some comments. I'll do some testing if it is otherwise ready to go.

Node( ZoneNode ).MassFlowRate = Node( ZoneNode ).MassFlowRateMinAvail;
} else {
Node( ZoneNode ).MassFlowRate = Node( ZoneNode ).MassFlowRateMaxAvail;
}
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent question. I'm going to guess they are very close to each other.

Alright so I took a couple simple functions, one with an if and one with a max() call. I compiled both with -O3, and reported the assembly. They are identical.

That said, I prefer the min/max.

NoOAFlowInputFromUser( true ), //TRANE
OARequirementsPtr( 0 ), //TRANE
AirLoopNum( 0 ), //TRANE
CtrlZoneNum( 0 ) //TRANE
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove these comments.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Myoldmopar: Done.

MixedAirOutNode = SysATMixer( SysNum ).MixedAirOutNode;
int PriInNode = SysATMixer( SysNum ).PriInNode;
int SecInNode = SysATMixer( SysNum ).SecInNode;
int MixedAirOutNode = SysATMixer( SysNum ).MixedAirOutNode;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 for declaring and initializing at the same time here.

@lgu1234
Copy link
Copy Markdown
Contributor Author

lgu1234 commented Aug 7, 2017

@Myoldmopar: Here are my conversion:

Original:
if ( Node( ZoneNode ).MassFlowRateMaxAvail < Node( ZoneNode ).MassFlowRateMax ) {
Node( ZoneNode ).MassFlowRate = Node( ZoneNode ).MassFlowRateMaxAvail;
} else if ( Node( ZoneNode ).MassFlowRateMinAvail > Node( ZoneNode ).MassFlowRateMin ) {
Node( ZoneNode ).MassFlowRate = Node( ZoneNode ).MassFlowRateMinAvail;
} else {
Node( ZoneNode ).MassFlowRate = Node( ZoneNode ).MassFlowRateMaxAvail;
}
Shall I use the following conversion?:

Node( ZoneNode ).MassFlowRate = min(Node( ZoneNode ).MassFlowRateMaxAvail, Node( ZoneNode ).MassFlowRateMax )
Node( ZoneNode ).MassFlowRate = max(Node( ZoneNode ).MassFlowRate , Node( ZoneNode ).MassFlowRateMinAvail, Node( ZoneNode ).MassFlowRateMin )

lgu1234 added 4 commits August 8, 2017 15:10
…trol-for-DOAS-AirLoop-#6205

Conflicts:
	doc/input-output-reference/src/overview/group-zone-controls-thermostats.tex
	src/EnergyPlus/DataSizing.hh
	src/EnergyPlus/SingleDuct.cc
@rraustad
Copy link
Copy Markdown
Collaborator

rraustad commented Aug 9, 2017

@lgu1234 why are the 2 example files, DOAToFanCoil*, failing? It looks like a null index issue.

Both show:
EnergyPlus::DataSizing::ZoneSizingInputData]: Assertion `contains( i )' failed.

@lgu1234
Copy link
Copy Markdown
Contributor Author

lgu1234 commented Aug 11, 2017

@rraustad A mistake of wrong index in ZoneSizingInputData was found. I am going to upload the code.

\note If Outdoor Air Flow per Person is non-zero, then the outdoor air requirement will
\note be computed based on the current number of occupants in the zone, as for demand controlled ventilation.
\note If this field is blank, then the terminal unit will still receive outdoor air from the DOA system but
\note the flow is not controlled on zone-by-zone basis.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not correct. Should be:
\note If this field is blank, then the terminal unit will be controlled using the DesignSpecification:OutdoorAir objec referenced in the Sizing:Zone object.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte A good catch. Done.

Copy link
Copy Markdown
Contributor

@mjwitte mjwitte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested all of the DOATo* example files and confirmed that the OA is distributed correctly.

Files with direct air terminal units are showing some unexpected eio diffs, for example, from ZoneVSWSHP_wDOAS

  • Component Sizing Information, AirTerminal:SingleDuct:Uncontrolled, ZONE1DIRECTAIR, Design Size Maximum Air Flow Rate [m3/s], 1.47878
  • Component Sizing Information, AirTerminal:SingleDuct:Uncontrolled, ZONE1DIRECTAIR, User-Specified Maximum Air Flow Rate [m3/s], 6.25000E-002

\paragraph{Field: Design Specification Outdoor Air Object Name}\label{field-DSOA-object-name}

This field allows modifying the behavior of this air terminal so that it is modulated to supply the required outdoor air to the zone. This field is optional. When the name of an DesignSpecification:OutdoorAir object is entered, the model is changed to adjust the flow rate to provide the volume of outdoor air described by that object. This feature allows modeling demand controlled ventilation on a zone-by-zone basis using the Outdoor Air Flow per Person rate (specified in the DesignSpecification:OutdoorAir object) and the number of occupants (specified in the People object schedules). If the outdoor air fraction of the supply air is 1.0, as for a dedicated outdoor air system, the air flow rate will match the outdoor air requirement. When the outdoor air fraction is less than 1.0, as for a recirculating air system, the terminal air flow will be modulated upward to account for the increased total air flow needed to provide the required flow rate of outdoor air. The total air flow rate will not exceed the Maximum Air Flow Rate specified above. The volume flow rate is converted to mass flow rate using the current density of air (function of drybulb and humidity ratio) at the supply air node.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lgu1234 @EnergyArchmage Down in the code, I made an earlier comment to use StdRhoAir instead of evaluating the current density, and that change has been made in the code. The docs need to be changed to match.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte Done.

\paragraph{Field: Design Specification Outdoor Air Object Name}\label{field-DSOA-object-name}

This field allows modifying the behavior of this air terminal so that it is modulated to supply the required outdoor air to the zone. This field is optional. When the name of an DesignSpecification:OutdoorAir object is entered, the model is changed to adjust the flow rate to provide the volume of outdoor air described by that object. This feature allows modeling demand controlled ventilation on a zone-by-zone basis using the Outdoor Air Flow per Person rate (specified in the DesignSpecification:OutdoorAir object) and the number of occupants (specified in the People object schedules). If the outdoor air fraction of the supply air is 1.0, as for a dedicated outdoor air system, the air flow rate will match the outdoor air requirement. When the outdoor air fraction is less than 1.0, as for a recirculating air system, the terminal air flow will be modulated upward to account for the increased total air flow needed to provide the required flow rate of outdoor air. The total air flow rate will not exceed the Maximum Air Flow Rate specified above. The volume flow rate is converted to mass flow rate using the current density of air (function of drybulb and humidity ratio) at the supply air node.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same comment about density here. Also, this needs to say that the DSAO object from Sizing:Zone will be used if this field is blank. And if neither is present, then the OA flow will be zero.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte Done.

\paragraph{Field: Outdoor Air Method}\label{field-outdoor-air-method}

The input must be either \emph{Flow/Person}, \emph{Flow/Area}, \emph{Flow/Zone, AirChanges/Hour}, \emph{Sum}, or \emph{Maximum}. \emph{Flow/Person} means the program will use the input from the field \emph{Outdoor Air Flow per Person} and the actual zone occupancy to calculate a zone outdoor air flow rate. \emph{Flow/Area} means that the program will use the input from the field \emph{Outdoor Air Flow per Zone Floor Area} and the actual zone floor area as the zone outdoor air flow rate. \emph{Flow/Zone} means that the program will use the input of the field \emph{Outdoor Air Flow per Zone} as the zone outdoor air flow rate. \emph{AirChanges/Hour} means that the program will use the input from the field \emph{Air Changes per Hour} and the actual zone volume (divided by 3600 seconds per hour) as the zone outdoor air flow rate. \emph{Sum} means that the flows calculated from the fields \emph{Outdoor Air Flow per Person,} \emph{Outdoor Air Flow per Area, Outdoor Air Flow per Zone}, and \emph{Air Changes per Hour} (using the associated conversions to m\(^{3}\)/s for each field) will be added to obtain the zone outdoor air flow rate. \emph{Maximum} means that the maximum flow derived from \emph{Outdoor Air Flow per Person,} \emph{Outdoor Air Flow per Area, Outdoor Air Flow per Zone,} and \emph{Air Changes per Hour} (using the associated conversions to m\(^{3}\)/s for each field) will be used as the zone outdoor air flow rate. The default is \emph{Flow/Person}.
The input must be either \emph{Flow/Person}, \emph{Flow/Area}, \emph{Flow/Zone, AirChanges/Hour}, \emph{Sum}, \emph{Maximum}, \emph{IndoorAirQualityProcedure}, \emph{ProportionalControlBasedOnDesignOccupancy}, or \emph{ProportionalControlBasedonOccupancySchedule}. \emph{Flow/Person} means the program will use the input from the field \emph{Outdoor Air Flow per Person} and the actual zone occupancy to calculate a zone outdoor air flow rate. \emph{Flow/Area} means that the program will use the input from the field \emph{Outdoor Air Flow per Zone Floor Area} and the actual zone floor area as the zone outdoor air flow rate. \emph{Flow/Zone} means that the program will use the input of the field \emph{Outdoor Air Flow per Zone} as the zone outdoor air flow rate. \emph{AirChanges/Hour} means that the program will use the input from the field \emph{Air Changes per Hour} and the actual zone volume (divided by 3600 seconds per hour) as the zone outdoor air flow rate. \emph{Sum} means that the flows calculated from the fields \emph{Outdoor Air Flow per Person,} \emph{Outdoor Air Flow per Area, Outdoor Air Flow per Zone}, and \emph{Air Changes per Hour} (using the associated conversions to m\(^{3}\)/s for each field) will be added to obtain the zone outdoor air flow rate. \emph{Maximum} means that the maximum flow derived from \emph{Outdoor Air Flow per Person,} \emph{Outdoor Air Flow per Area, Outdoor Air Flow per Zone,} and \emph{Air Changes per Hour} (using the associated conversions to m\(^{3}\)/s for each field) will be used as the zone outdoor air flow rate. \emph{IndoorAirQualityProcedure} means that the program will use the other procedure defined in ASHRAE Standard 62.1-2007 to calculate the amount of outdoor air necessary in order to maintain the levels of indoor air carbon dioxide at or below the setpoint defined in the ZoneControl:ContaminantController object. Appendix A of the ASHRAE 62.1-2010 user’s manual discusses another method for implementing CO2-based DCV in a single zone system. The last two methods of Proportional Control calculate the required outdoor air flow rate which varies in proportion to the percentage of the CO2 signal range and has two choices to calculate occupancy-based outdoor air rate. \emph{ProportionalControlBasedonOccupancySchedule} uses the real occupancy at the current time step to calculate outdoor air rate, while the \emph{ProportionalControlBasedonDesignOccupancy} uses the design occupancy level to calculate outdoor air rate. The former choice is a good approach to estimate outdoor air rate. However, for practical applications, the zone controller usually does not have the real time occupancy information, and the design occupancy level is assumed. The latter choice is used in the design stage. The default is \emph{Flow/Person}.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This has become so long that it is difficult to read. Would be better formatted as an itemized list, similar to AvailabilityManager:NightCycle "Control Type".

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte Done.

This alpha field specifies the name of a DesignSpecification:OutdoorAir object which specifies the design outdoor air flow rate for the zone.

When a choice of IndoorAirQualityProcedure is entered in the Outdoor Air Method field of the DesignSpecification:OutdoorAir object, the design outdoor airflow rate is calculated based on the choice of Sum in the same field.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What if the method is ProportionalControlBasedOnDesignOccupancy or ProportionalControlBasedonOccupancySchedule?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte I added a paragraph:

When a choice of ProportionalControlBasedOnDesignOccupancy or ProportionalControlBasedonOccupancySchedule is entered, the design outdoor airflow rate is calculated based on equations specified in the "Proportional Control" section in the Engineering Reference.


If this DesignSpecification:OutdoorAir object is referenced by a Controller:MechanicalVentilation object (either directly or indirectly through Sizing:Zone), the schedule will be applied to all types of outdoor air calculations for the corresponding zone, regardless of the System Outdoor Air Method selected. If the schedule value is zero, then the zone will be completely removed from the system outdoor air calcaulations.
If this DesignSpecification:OutdoorAir object is referenced by a Controller:MechanicalVentilation object (either directly or indirectly through Sizing:Zone), the schedule will be applied to all types of outdoor air calculations for the corresponding zone, regardless of the System Outdoor Air Method selected. If the schedule value is zero, then the zone will be completely removed from the system outdoor air calculations.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What happens if the choice made here is ProportionalControlBasedonOccupancySchedule and this is referenced in a Controller:MechanicalVentilation object where the system-level method is different? Who wins?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte This scenario is similar to Method of Sum, and others. I think Terminal wins.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was not asking about Terminal vs OA Controller. Rather, within Controller:MechanicalVentilation, if the system method is, say, Sum, but the DesignSpec:OA object that is referenced in the Controller;MechanicalVentilation object says ProportionalControlBasedonOccupancySchedule, then what method will be used by the Controller:MechanicalVentilation object to calculate the min OA flow? I think the system method will be used. Yes, that's what the code shows in MixedAir::VentilationMechanicalProps::CalcMechVentController. The method there is controlled by this->SystemOAMethod. I don't know if we should mention that here or not.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte Let me remove the paragraph I just added. Here is an issue I think. The Controller;MechanicalVentilation for a system and DesignSpecification:OutdoorAir for a terminal should be interlocked. We should not let these objects fight each other internally and give users a clear picture how to make correct inputs of OA.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte I think we don't need to mention here.

"Let me remove the paragraph I just added" should not be in the above comment.

Node( ZoneNode ).MassFlowRate = Node( ZoneNode ).MassFlowRateMinAvail;
} else {
Node( ZoneNode ).MassFlowRate = Node( ZoneNode ).MassFlowRateMaxAvail;
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Upon further inspection, this section is slightly different from the min/maxs below, so leave well enough alone (it's identical to existing logic).

if ( ZoneSizingInput.allocated( ) ) {
for ( int SizingInputNum = 1; SizingInputNum <= NumZoneSizingInput; ++SizingInputNum ) {
if ( ZoneSizingInput( SizingInputNum ).ZoneNum == SysATMixer( ATMixerNum ).ZoneNum ) {
SysATMixer( ATMixerNum ).SizingInputNum = SizingInputNum;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This works, but you don't really need to store SysATMixer.SizingInputNum. Just set SysATMixer.OARequirementsPtr = ZoneSizingInput( SizingInputNum ).ZoneDesignSpecOAIndex.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte Good idea.

if ( SysATMixer( ATMixerNum ).OARequirementsPtr > 0 ) {
vDotOAReq = CalcDesignSpecificationOutdoorAir( SysATMixer( ATMixerNum ).OARequirementsPtr, SysATMixer( ATMixerNum ).ZoneNum, true, true );
} else {
vDotOAReq = CalcDesignSpecificationOutdoorAir( ZoneSizingInput( SysATMixer( ATMixerNum ).SizingInputNum ).ZoneDesignSpecOAIndex, SysATMixer( ATMixerNum ).ZoneNum, true, true );
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will fail if SizingInputNum is zero. If OARequirementPtr is set earlier (as suggested) then this if block isn't necessary. Just keep line 4970.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte Done.

int OARequirementsPtr; // - Index to DesignSpecification:OutdoorAir object
int AirLoopNum; //System sizing adjustments
Real64 DesignPrimaryAirVolRate; //System sizing adjustments, filled from design OA spec using sizing mode flags.
int SizingInputNum; // ZoneSizingInput index
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't need SizingINputNum.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mjwitte Done.

@mjwitte
Copy link
Copy Markdown
Contributor

mjwitte commented Aug 15, 2017

More testing of the new features, and review of results from @lgu1234 test files. All is working as expected, except a couple of small things posted as new issues, #6242 and #6243. This can go in once the other comments are addressed.

@lgu1234
Copy link
Copy Markdown
Contributor Author

lgu1234 commented Aug 15, 2017

@mjwitte
I ran the example file of ZoneVSWSHP_wDOAS and looked at eio difference between autosize results and user inputs. The value is from TermUnitFinalZoneSizing( CurZoneEqNum ).DesHeatVolFlow. I plotted the mass flow rate and the maximum value matches autosize. Therefore, the user input value is too small. That is why large differences occur.

massflowrate

@mjwitte
Copy link
Copy Markdown
Contributor

mjwitte commented Aug 15, 2017

@lgu1234 I was not clear about the diffs for ZoneVSWSHP_wDOAS and other files with AirTerminal:SingleDuct:Uncontrolled. There are new component sizing lines in the eio output file. They did not report before, but now they do. Wondering why that would change here. @rraustad ? See eio diffs for
1ZoneEvapCooler and
ZoneVSWSHP_wDOAS

@Myoldmopar
Copy link
Copy Markdown
Member

OK, if I recall correctly, from mere moments ago, @rraustad was doing one more look at some results. Once done, go ahead and merge it @rraustad.

@rraustad
Copy link
Copy Markdown
Collaborator

rraustad commented Aug 16, 2017

Is anyone looking at the get_bucket, head_bucket failures on the Linux box?

@rraustad
Copy link
Copy Markdown
Collaborator

rraustad commented Aug 16, 2017

  • Noting that DOAToFanCoilInlet and DOAToFanCoilSupply example files have new warnings for HX average air volume flow rate <50% or >100%, 623 total times, also DOAToVRF with 425 warnings, also DOAToWaterToAirHPSupply with 107 warnings
  • Noting that DOAToPTHP example file changes caused lower air flow rate and cooling/heating capacities during sizing (in the eio file).
  • Noting that DOAToUnitVentilator example file removed 161 total warnings of SimHVAC max iteration warning and added a new warning for "Air volume flow rate ratio", whatever that is.
  • Noting DOAToUnitarySystem example file changes resulted in lower OA controller flow rates, yet similar air flow and capacities for HVAC equipment (some heating coil sized were reduced).
  • Noting DOAToWaterToAirHPInlet example file showed fewer Air volume flow rate ratio warnings, from 170 to 107.
  • Noting ZoneWSHP_wDOAS added 1 unused schedule warning.

@lgu1234
Copy link
Copy Markdown
Contributor Author

lgu1234 commented Aug 16, 2017

@rraustad

•Noting that DOAToFanCoilInlet example file has new warnings for HX average air volume flow rate <50% or >100%, 623 total times

The new warning is caused by lower outdoor airflow rate.

•Noting that DOAToPTHP example file changes caused lower air flow rate and cooling/heating capacities

The file uses IAQP, so that the OA rate is calculated based on CO2 setpoint.

@rraustad
Copy link
Copy Markdown
Collaborator

Looked at results for DOAToPTHP since it had the largest change (reduction) in sizing results for air flow and coil capacity. The zone temperatures are still maintained and the OA amount follows the people schedule (i.e., the people schedule looks much like the OA flow rate profile).

doatopthp

@rraustad
Copy link
Copy Markdown
Collaborator

Reviewed results and merged. Issue #6205 closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Defect Includes code to repair a defect in EnergyPlus IDDChange Code changes impact the IDD file (cannot be merged after IO freeze) NewFeature Includes code to add a new feature to EnergyPlus

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants