OpenStudio SketchUp EnergyPlus - Misc. Tips October 24th, 2020

YouTube-Logo-1.png
 

1. OpenStudio SketchUp - Orphan Geometry and Boundary Conditions

In this video, we will show how to locate geometry with errors and eliminate orphaned objects.  We will also discuss how to fix boundary condition issues where surface matching does not work.

Today, I am going to show you how to resolve two common errors that you will encounter when modeling with OpenStudio and SketchUp.
Let us reload the model.
You will notice that there are two errors that pop up.
It says that the subsurface is not contained by its base surface. It cannot be drawn.
Face 65 and face 69. Let us remember what those are called.
We will go to the search surfaces filter tool at the top.
Search for it. Face 65.
I am going to drag this out of the way so you can see.
It looks like there is nothing there. I will unhide it and I will search again.
It looks like there's nothing there.
This is an orphaned piece of geometry.
Somehow, it is a left over from an artifact of editing the model.
It is still located in inside the OSM file, but it is not actually part of the model.
We need to go to the project file folder...I'm sorry...
Go to the OSM file and edit it with a text editor.
Search for that object. Face 65.
You can see that it shows up in our OSM file, but it is not showing up in SketchUp.
This is an orphaned piece of geometry that we can delete from the OSM file.
Let us do the same thing for the other object. Face 69.
We will delete this from the OSM file as well. Save it. Close the text editor.
We will reload the model.
There. You can see that it resolved those errors.
Another issue I will show you is boundary conditions.
Go up to the filter tool and render by boundary to condition at the top right.
Here. Click it. This shows you the boundary conditions of the surfaces.
We will use a section plane to take a look at it.
You can see that on this section plane, most of these interior surfaces are green.
That means they have an adjacent surface that they are connected to.
We will edit this space. (Double-Click) You can see that this surface is green.
If you edit the adjacent space, you can also see that this is green.
Let us take a look at the inspector tool at the top.
We will try to minimize this. Let us edit this space.
We will select this surface. This surface is called Face 84.
You can see that it's outside boundary condition object is Face 41.
If we edit the adjacent surface, you can see that adjacent surface is Face 84.
This is Face 41.
Let us take a look at these surfaces. You can see that this interior surface is blue.
So is this interior surface. These are two different spaces.
Let us take a look at this space here. Office 112.
You can see that the surface name is Face 89, but it doesn't have a boundary condition object. It is blank.
Let us remember that. Face 89.
Edit the adjacent space. The shower room. Edit this surface. Base 28.
You can also see that it doesn't have a boundary condition here..
Drop down this menu. Search for Face 89. Select Face 89.
You can see that it automatically turns green to show that it is now connected to the adjacent room. Face 89.
Face 89 is also linked to Face 28.
Likewise, you will note that we also have interior doors and interior windows.
We also have to link those interior doors and windows to adjacent surfaces to create boundary conditions.
This Face 89. Face 90. Excuse me.
We need to link this object to Face 90.
Now, you can see that the interior door is is linked to the adjacent space.
That is how you resolve those two issues.
Thank you. Please like and subscribe!

2. OpenStudio SketchUp - Separating Thermal Zones

In this video, we will show how to use SketchUp to separate large open spaces into thermal zones.

We have a building here that was modeled based on the floor plan.
We will hide the roof and take a look over the top.
We will hide this plenum here too. These are the rooms based on the architectural plans.
What we really have for HVAC zoning looks more like this.
We will work on RTU-2 zone, right here, for now.
You will notice that RTU-2 serves this entire space on this side of the building.
We only have these zones grouped up into rooms right now. Based on the architectural plans.
There is actually no wall here.vv
For our energy model we need to have a wall there to isolate this thermal zone.
We will edit the model to separate this room from this room. This thermal zone from this thermal zone.
First, we will go to camera and turn off perspective view.
Then we will select this space.
Use the Move tool: we will select a corner of it and we will hit the control button to copy.
Copy it up here.
This takes a minute for Sketchup.
Now we need to separate that out. Double click to edit this copied space.
Select everything up to this point to delete.
We can select this to delete and this to delete. This to delete. Delete.
We will just do this here. We will draw a line connecting this edge here.
This edge here. Then we need to draw a line down connecting these two to separate those.
That should split those off. We will go back to overhead view.
Now we should be able to delete this. We have an intact portion of the building.
Back to overhead view. We will select out of the active.
Likewise, we need to sever off this portion of the zone. Same procedure.
We will draw a line severing this portion.
We also need to sever the windows. You need to be very careful where you place your end points.
Make sure that it severs it properly. Now we can delete this.
Double check that we got everything.
Select out. Once you are done, you can just move the new zone into place.
Use the move tool.
Again, you need to make sure that you select the proper place.
You don't want to select this endpoint. We are selecting this endpoint to move.
You need to be very careful what points you are selecting and matching up.
Go back to overhead view. Now this space is severed from this space.
We have two thermal zones. Thank you. Please like and subscribe.

 

 

3. OpenStudio SketchUp - Boundary Conditions

In this video, we will discuss surface boundary conditions.  We will show how to use SketchUp to filter for and edit boundary conditions.

Quality control items for checking your model.
Check the boundary conditions of the surfaces.
Right now, I have this model set to render by surface type. This is pretty standard.
You can see that roofs are a dark red color.  Walls are yellow color.  Floors, gray.
Switch to render by boundary condition.
You can see that it changes the colors.
The floors are a dark beige.  Walls, light blue.  Roof, dark blue.
You can see that this one stands out. Inspect this item.
Go to the inspector tool...
Let us use the info tool. You can see that this is surface 47.
Let us click into this space. Click this surface 47.
You can see that the surface is specified as a roof/ceiling.
But, the outside boundary condition is set to ground.
This makes sense. It is a gray color.
You can see that the floors are gray color. Gray is a ground boundary condition.
So, we need to edit this. We will change it to an outdoor boundary condition.
We will change this to outdoors.
You will notice that it has changed to a light blue color.
That is because there are several other boundary conditions that we need to consider.
The Sun Exposed boundary condition...It says that there is no Sun, but this is a sun exposed roof.
It will be sun exposed to the sun.
It will be also wind exposed.
We will edit those conditions.
Do the same thing for the other surfaces that are wrong.
You will notice that this overhang is designated as a ground exposed, outside boundary condition.
This is actually exposed to the outdoors.
It is not sun exposed. It will be wind exposed.
We should change those boundary conditions.
We will do this for the other surfaces that are incorrect. Check those conditions that seem to be wrong.
Thank you. Please like and subscribe!

 

4. OpenStudio Tips - Quickly Edit Multiple Schedules

In this video, we will show how to quickly edit multiple schedules at the same time.

Today we will discuss how to quickly adjust multiple schedules.
Go to the schedules tab.
We have multiple different schedules. Lighting schedules. Occupancy schedules.
There are various different priorities throughout the year for these schedules.
For some of them, we want them to be the same.
We will look at this one here. You will note that it has the year starting on January 3rd.
But there are some schedules that start on January 1st.
If you look at January 1st, it is a a weekend: Sunday.
If we look at this schedule, you will note that this starts on the third.
We actually want to start it on the second. This is a weekend. This starts on the third as well.
We want to start it on the first. We will start all of these on the first of the year.
This issue is found in all of the other other schedules. They are starting on on the third instead of the first.
We want to open up the OSM file with NOTEPAD++.
We will search for this schedule rule. You can see that this schedule starts on the first month of the year. The third day of that month.
We want to change that to the first month of the year and the first day of that month.
Go to replace. We need to type in the new line code "\r\n".
We will select the third day. So, we are trying to find this and we will replace it with this.
You want to make sure to select "wrap around" and "extended search mode".
Click "replace all". It goes through the whole file and replaces all of those occurrences.
It says there were 29 schedules that were changed from January 3rd to January 1st.
Save the file. Go back to OpenStudio.  Click "Revert to Saved".
We will go to our schedules. Go to the library light schedule.
Check that it was corrected. You can see that it was changed to January 1st.
That is how you adjust multiple schedules at the same time using a text editor.
Thank you. Please like and subscribe.

 

5. OpenStudio EnergyPlus - Measure Writing 1

In this video, we will discuss what OpenStudio measures are, how they are used, and how to create your own measures by coding using Ruby programming language.

Today we will talk about OpenStudio Measures.
Take a look at the Measures tab.
First, let us discuss how OpenStudio creates your energy model.
OpenStudio gathers all of the inputs from each one of these tabs.
These input variables that you input into the model. And it creates an .OSM file. This file right here.
This is the input file for OpenStudio.  This input file has all of the schedules, all of the equipment, all of the zone assignments.
Basically, all of the inputs for the energy model.
Then OpenStudio runs it through a translator.
It translates that OSM input file into an EnergyPlus input file.
The EnergyPlus input file is very similar. You can find it by going to the project folder. Go to the run folder. Select the in.IDF file.
IDF is an EnergyPlus input file. If you open it up, it looks very similar to the OpenStudio input file.
But, OpenStudio does a lot of shortcuts.  Shortcuts that to make it easy for the user to create the energy model.
After you input the information using the OpenStudio graphical user interface (GUI), OpenStudio has to translate these inputs to EnergyPlus.
It has to expand those shortcuts.  Fill in missing information. That is what the translator does.
It changes the OpenStudio input file to an EnergyPlus input file.
EnergyPlus input file is very similar.
It has all of the object definitions. Walls, insulation, equipment, schedules, etc.
The IDF file is used strictly for the EnergyPlus simulation engine.
EnergyPlus uses that input file.  It does all the physics based calculations necessary to create your energy model simulation.
Then, it spits out an output file. The output file contains the information that you see when you go to the Reports tab.
Now, stepping back to Measures.
Energy modelers use measures to automatically edit some of the input variables on the input file.
And, they can edit some of those inputs  that the OpenStudio interface does not have.
You can download these measures from the building component library.
We will look at hvac-ventilation.Let us see. Whole system-distribution.
There are different measures that you can use. This measure right here. Air wall zone mixing creates an air wall on your OpenStudio model.
You can tell that it is an OpenStudio measure because it has the OpenStudio logo.
Conversely.  Add zone mixing object is an EnergyPlus measure.
This measure adds a zone mixing object on the EnergyPlus file.
This EnergyPlus measure is applied after the OpenStudio input file has been translated to the EnergyPlus input file.
So, there are two different measures that you can write. (Actually, three if you include reports)
Basically, these measures go into the input files and they change some of the parameters.
If you want to change all of the walls in your model to...maybe..."sun exposed".  The measure program goes into the input file and this parameter right here.
And it is automated.  It will change all of the walls in your model to have that input characteristic. (ie. Sun exposed)
Basically, a measure is a short script of program that opens up the input file and changes some of the input parameters.
It can also transform your model.
For example. Some of some of the measures are used to completely change the systems in your model.
For instance. If this model has a regular rooftop hvac system and you wanted to replace that entire system with a chilled water variable air volume.
You can use this advanced energy design guide measure.
You can you can download those from the building component library (BCL).
Today, we are going to show how to write a simple measure.
We are going to start with an input object that OpenStudio does not support.
It is an input object that EnergyPlus uses. We will go to our air loop.  We have a return fan here.
This return fan has a lot of inputs on it, but there is one particular input that OpenStudio does not have.
If we go to the EnergyPlus input output reference manual. You will see that one of those inputs is called Design Return Air Flow Fraction of Supply Air Flow.
You can look over on this...Oh, I am sorry. This is part of the air loop...yes, Air Loop HVAC.
If we select the air loop hvac; look at the inputs in this pane.
On the properties pane. You will not find that particular input. It is not available.
It is not supported by OpenStudio. So, we will create an EnergyPlus measure that inserts this particular input into the IDF file.
Essentially; after OpenStudio translates this to an EnergyPlus input file, this measure will insert this return airflow fraction of supply air flow variable.
This input variable limits the return fan to a maximum airflow.
A maximum airflow ratio of the supply fan.
The system will provide full supply airflow from the supply fan, but the return fan only returns a fraction of that flow.
This assumes that elsewhere in the building there are exhaust fans pulling some of that air.
So, the return fan is not returning the full flow of the supply fan.
To do this, we need to go to...
Let us go to measures. We are just going to copy one of the measures. We will modify it for our purposes.
I do know that this add zone mixing object has some of the items that we need to modify.
We will copy this and we will rename it to our own measure.
Select the object. Select x2; copy selected measure. Add to my measures.
We will rename this: "edit return air flow fraction".
This is just a description of what this measure does.
This modifies the design return air flow fraction of supply air flow from the default of one.
Next, we need to edit the modeler description. This describes any specific details the energy modeler needs to know. How how this measure might affect his / her energy model.
How it should be implemented.
This measure puts a maximum on the return air flow.
Next, we need to specify what type of measure it is.
This measure will be adjusting the EnergyPlus input file.
The taxonomy will be an EnergyPlus measure.
This is just HVAC-whole system measure.  Because it affects the whole HVAC system.
These are the intended tools. You can apply the measure now using the apply measure now tool.
You can run it in the OpenStudio measures tab.
Or, you can run it in the parametric analysis tool.
We will just keep these as they are.
This is...um yeah...we will just leave those as they are.
When you are done, click create measure and open for editing.
It automatically drops the measure into your personal OpenStudio measures folder.
The folder is located in your user folder. We want to open this.
I would recommend editing these with notepad++.
Notepad++ has additional features that are helpful for editing programming code.
It has some features that aren't available for just a regular notepad application.
This opens up the program. It is a Ruby program (Ruby programming language).
It has the typical disclaimer.  Free to use information. Basically saying that there is no legal liabilities or anything.
The code starts out with some of the stuff that has already been renamed based on the inputs that we just did.
This measure is “edit_return_airflow_fraction”.
It starts out with a class. All of this stuff has already been edited for us based on that that description we just typed.
Here is our description. Here is our modeler description.
All of this stuff has been automatically added to the program.
Then, the program starts with defining arguments.
Arguments are the inputs that the user will input in the OpenStudio GUI.
Let me show an example. We will drop this “add zone mixing object” measure into here.
We will click it. These are the arguments right here. They are the user’s inputs for the measure.
This is just an example.
We want to change some of these. Just looking at this one here.
This has zone name. We will replace this with airloop_name.
We will call this...call it...instead of calling this zone_name, we will call this loop_name.
We want to select it. You can see it highlights all of them.
Copy. We will find and replace zone_name with loop_name.
We will replace all of those in this program.
With the display name this is...this says...This variable is going to be zone with exhaust.
You can see that this is what the display name is right here. "Zone with exhaust"
Here we want to change this to something like “air loop with return fan”
That is what this does. This creates a variable called “loop_name” and it sets this this argument field right here so whatever the user puts in.
It will push that string to this variable loop_name.
We will edit some of these comments too. This is just a comment.
You can see all the comments. They are denoted by a hashtag.
That means they are not part of the programming code. It is just a comment by the programmer.
It tells who ever is reading the program what this part of the program is doing.
We will call this the name of the air loop to be edited.
We don't need any more names. We can delete this.
I do not need any more names. We can delete that.
The next thing we need is something like a variable. A number.
Like this design zone mixing cfm.  CFM is an airflow number, but we will be using a percentage.
It will operate the same as the airflow value. It is a number variable.
We will change this to...well...we will do this comment here.
This will be the design return air flow fraction of supply air flow.
It will be a ratio. A percentage. We will rename this variable here. Design...instead of design level.
Replace this with “return_fraction”. Replace all return_fraction.
And this...instead of a string. The loop name is a string, so that would be the name of the air loop.
This is a makeDoubleArgument. A double is any real number.
You can go to the measure writer's reference guide on the OpenStudio website.
It will give you a lot of pointers on how to do some programming.
We will find double...double is any real number. It is a decimal number. So, it is 1.0, -1.5, or 50.5, etc.
We are creating a variable return_fraction. It is a double.
This "true" here. I forgot to mention this "true" here.  It means that it is a necessary user input.
The user must fill out that field in order for the measure to run.
The user must supply this information in order for the measure to run.
If the user does not specify something in those fields, and it's marked true, then the measure will not run.
Sometimes you will have variables that are false. That means that it is optional.
The user can fill out those fields. Or not.
The next line down, return_fraction.setDisplayName. Again, this is the display name.
We will call the display name "Return Air Flow Fraction".
That will be what is displayed on the GUI.
It will be what is displayed right here. It will be "Return Air Flow Fraction".
The next line down is the variable that the user will set and...oh i'm sorry. The units.
For this example it has units of CFM.  In our case, it will be a percentage.  From zero to one.
We will put percent symbol here. That is all for the arguments part.
Now, we will go down and define what happens when the measure is run.
This sets up the actual run for the measure. This is where the program modifies the input file.
This is all the operations that the program does to change your input files.
Since we are editing an EnergyPlus input file, we are working in "workspace".
If we were working on an OpenStudio measure, it would be called "model space" I believe...It is either model space or model...
Sorry. Here we go. Yeah. Every measure needs a "model" or "workspace". Workspace is for editing the EnergyPlus IDF files.
Model is for editing the OpenStudio OSM files. We are working on an EnergyPlus model, so we will be using "workspace".
Next, there is a default "built-in" error checking. This just checks the program or the arguments for errors. We will just leave this as it is.
Next, this assigns the user inputs to variables within this run loop.
This is the run, so we need to take these variables up here and assign them to variables within this loop here.
We have already renamed some of these. loop_name. We have that. We can delete the schedule_name.
return_fraction. We have that. We do not need this source_loop_name.
We only had two variables. The loop_name and the return_faction value.
We have taken our argument variables and we have assigned them variable names within this run loop.
Let us look at the next one. Reporting initial condition of model.
This is going out into the IDF file and it is compiling all of the ZoneMixing objects into an array called zone_mixing_objects.
We will not use that here. We need to create our own array.
We need to create an array of AirLoopHVAC objects...let us go back to the input output reference.
What is the object name for this one. The object name is AirLoopHVAC.
We can verify that by looking at the air loop. Click on it. Yes. The object name is AirLoopHVAC.
We will go back to our program. We will just simplify this by calling it "air_loops".
Let us do a find and replace. air_loops. This will be an array of all the AirLoopHVAC objects in the IDF file.
It is going into the workspace, which is the IDF file, and it is getting all the objects by type.
The type that it is looking for is "AirLoopHVAC".
It is finding all the AirLoopHVAC objects in the file and putting them into the air_loop array.
Then there is a runner. A runner is a little piece of information that it returns to the GUI while the program is running.
When you run the file...when you run the model, you click the run button. There is a lot of...we can just click it.
There is a lot of information here that pops up onto this window.  These messages are called runners.
That is what these are. The messages are telling the user about key progress steps while running the program code.
This failed because of our zone mixing object measure.  We did not fill in that necessary information on the measure.
Anyway.  That is what a runner is. This runner is registering the initial condition.
The building started with so-and-so air loops. Size. It is taking this array of air loops.
It is finding what the size of the array is. How many air loop objects are in that IDF file.
We can just replace this.
This is not very important, but we can just leave that in there for now.
At least we'll have a runner that says something while the code is running.
We will know that it is actually doing something.
The next piece of code. Get all thermal zones in the starting model. We don't need that.
We are not worried about thermal zones for this program.
Validate input names and get zones. We don't we don't need to validate these names.
We might come back to this reuse this later.  Right now, we will just comment out all of this code to simplify things.
Then, error if it didn't find zones. Again, let us just comment this out.
Humm...I think there is a single line comment. Here we go. We will comment that out.
...do you validate schedule name? Yeah. We don't need to worry about that.
This is just some programmer’s comment from the code we copied. It is not applicable here.
Validate design level input. We will just comment this out. We will come back to this later.
This is just...here we go...calc method. We don't need these variables for zone mixing object.
Let us delete those. Those are not applicable to our program.
This adds a new mixing object to the model, but we do not want to add a new mixing object.
We do not want to add a new air loop to the model. So, we can delete this.
We can actually delete all of this. We want to set up a "do" loop.
If you want to find out more about measure writing, as I mentioned before, you can go to the measure writing guide on the OpenStudio website.
Let us look for "do". We want to look for an example of a "do" loop.
Let us set up our do air_loop.
Our array is air_loops, so we want to cycle through air_loops and...
Let us see, air_loops.each do. For each instance in that array I will assign it a variable called air_loop.
That is the the instance that the program is looking at in each cycle of the "do" loop.
Then, we want to put: if loop_name is equal to air_loop get string at position zero of the array.
One thing you want to realize is, these EnergyPlus objects are arrays.
The object name is AirLoopHVAC. The first field in the array is the name of the air loop.
This name is at position zero of the array. Controller List Name is at position one of the array.
Availability Manager List Name is at position 2 of the array...
If we want to look at that, we can take a look at the IDF file.  The EnergyPlus input file.
We will search for airloophvac. You can see...here it is.
Position zero of the array is the name, position one is the controller list name, position two is the availability manager list name.
That is what we saw in the  input output reference manual. Name. Controller List Name. Availability Manager List Name.
It keeps going on. All the way down to node names.
The one we are looking for is all the way down at the bottom: Design Return Air Flow Fraction.
That comes after node names, but you can see that in this IDF file it does not exist.
So, we are writing this measure to insert this field into the object array.
We need to find out what position this field is in.
We can count them 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10. This field is in position ten of the array.
With that in mind, let us go back to our measure program.
The program is looping through the energy model air loops. It is searching for the loop name that the user specified in the arguments section above.
Looping through the array and trying to find that particular air loop name.
Once it finds that particular air loop, we want it to write that position 10 string to that object.
It finds the air loop and we will write: air_loop.setString.
Again, please visit the measure writer's guide to find out more about these functions.
Go to the top and SDK documentation. All the syntax is located in this SDK documentation.
I have found it easier just to do a search for it. If we search for openstudio .setstring...
Yeah. It looks like it brings me back to the measure writer's reference guide...Here is an example of how to use .setstring.
It is important to try to find examples of code. Where it is used. Try to understand how it is being used.
Once you get familiar with that, you will start to understand it better.
And how to find that information. For this instance, we will do .setstring.
We want position 10. return_fraction to string.
We will just write a comment here. What this is doing. Overwrite return air flow fraction.
This is overriding the return airflow fraction if it is already in the IDF file. Or, writing it there if it does not exist.
It is just writing the return airflow fraction. If that was already in the IDF file, we would be overwriting it.
Again, we are doing a "do" loop. We are looking for the loop name that that matches the loop that we are interested in.
At position zero as the loop name. Then, once it finds that loop it sets the string in position 10 of the array to the variable that the user specified in the arguments.
Then...um...we probably want to have a runner just to tell the user that it was successful.
runner.registerFinalCondition
The runner says the return air flow fraction of supply air flow was changed to return_fraction.
At the very end of the if loop we want to put "end". We also need to end the "do" loop.
This is just some runners from the old code. We can get rid of these. And that is the end of the code.
So, if all goes well, we should be able to execute this code and hopefully it runs.
Let us go back to our energy model. We can just get rid of this...um...oh
We want to make sure to save the code. Go back to our energy model and let us see...
Whole system-edit return airflow fraction. There is the measure we were just editing.
We will drop it into our measures and you will notice that there is an exclamation mark here.
It is saying that these are required inputs. We need to fill out that information in order for the measure to run properly.
We need to figure out what the air loop name is. We can go back to the HVAC systems tab.
Select the air loop. We will copy the name here. Go back to measures.
Paste the name here. We will say return air flow fraction of supply air flow is going to be...maybe 60 percent.
Let us say sixty percent. Save our model. Go to run...and just...uh...real quick.
We will take a look at our OSM file, just real quick.
I know it's not there, but I just wanted to show you. Search for airloophvac.
You can see that return airflow fraction of supply air is missing. It should be right here. But, it is not.
We already looked at the IDF file. Same thing. It is not there.
Go ahead and hit run. We should see some of those runners pop up...oh...
It looks like our code failed...so...we did have a runner. The building started with one air loop hvac object...yes.
This says undefined method 'getstring'...We can go back to our program.
Yes, we have "getstring" here, but this came before the runner. The runner had executed successfully.
But, we have a "getstring" here and I think I know what is wrong. This is case sensitive.
We need to write a capital "S" for "getString". I bet this is probably case sensitive as well. "setString"
Okay, we will save it. We will go back. Try to run the simulation again.
...um...let us revert to saved. Maybe we need to refresh this...
Nope, still getting "getstring" error...So it seems like it is still working off an old copy of our program.
That should be capitalized, even if it wasn't still error.
Let us go back to measures. Go ahead and delete this out of here...make sure that...
Save...oops...just make sure this is saved. I thought we changed that. Okay.
Let us go back to our library return airflow fraction...0.6.
We will save it. We will just try to run it again.
There it is. Final condition return airflow faction was changed.
Success! All right. We should be able to...we will let this finish.
We should be able to go to the IDF file.  The EnergyPlus input file. Open it up.
We will search for "return air flow". There it is. Design Return Air Flow Fraction of Supply Air Flow.
It was added to our air loop called "Packaged Rooftop Air Conditioner". Success!
That is how you write a measure for OpenStudio. In particular, writing a measure to edit the EnergyPlus input file.
Thank you. Please like and subscribe.

 

6. OpenStudio EnergyPlus - Input Output Objects

In this video, we will discuss EnergyPlus objects and how to find information about how they function.  This will help you understand how OpenStudio / EnergyPlus functions to simulate your energy model.  It will also help you to know what inputs are important, what inputs can be left default, and how they might affect your energy simulation.

Today we are going to discuss what an EnergyPlus object is.
EnergyPlus objects are programming pieces inside the EnergyPlus program that execute certain calculations.
For example: this fan is an EnergyPlus object. This DX cooling coil is an EnergyPlus object.
This air loop is an EnergyPlus object. All of these are objects.
Objects have certain programming code associated with them that includes inputs.
The inputs are the items that you adjust on the side here, for this object.
There are outputs as well.
We are going to discuss how to figure out what each one of these objects do.
Let us look at this fan here. You can see right here. On the right-hand pane.
It says OS:Fan:ConstantVolume.
If you want to find out what any one of these inputs does for simulating the object, you can go to the EnergyPlus input-output reference.
Go to the EnergyPlus website: EnergyPlus.net/documentation
There is a lot of documentation for EnergyPlus.
In particular, we will look at the input/output reference.
This document here.
We are looking at Fan:ConstantVolume.
Let us type that in the search here. Fan:ConstantVolume
It finds the Fan:ConstantVolume object in the table of contents.
We will just click the link to go directly to it. Here is where it describes this object.
This object models a constant air volume fan that is intended to operate continuously based on a time schedule.
This fan will not cycle on and off based on cooling / heating load or other control signals.
It goes on to tell you what the inputs are. The name of the fan.
The availability schedule name. It describes what that schedule is used for.
The fan total efficiency. Pressure rise. Maximum flow rate.
It keeps going down to the end and use subcategory.
It tells you what each one of these inputs does.
Also, it tells you what the outputs are for the object.
Outputs for this constant volume fan are: electric power, fan rise in air temperature, and fan electric energy.
You can look at any object and you will see the EnergyPlus object name up in the top of the properties pane.
Look at Coil:Heating:Gas.
We can look up Coil:Heating:Gas to find out how this object is used by EnergyPlus.
I am sorry. It is not opening the link.
We will just click here.
It will tell you exactly what all of the inputs are for that particular object.
Same thing with the outdoor air system object.
If you are interested to find out what all of these inputs are in the properties pane on the side.
Just look up this keyword in the EnergyPlus input-output reference.
For the OutdoorAirSystem, it has one input. Name.
For the Controller:OutdoorAir, there is a lot of different inputs and outputs.
If you want to know what any one of these is used for, look at the EnergyPlus input-output reference.
Thank you. Please like and subscribe.

 

 
 

7. OpenStudio EnergyPlus- AirLoopHVAC Autosizing

In this video, we will show discuss how EnergyPlus autosizes air loop fans.  We will also discuss how EnergyPlus balances airflows with zone level exhaust systems and use DView to verify the fans and Outdoor Air System are working together.

A user on YouTube asked a question.
Can you do an example of an air handling unit with 6000 CFM supply 5000 CFM return.
1,000 CFM fresh air with zero exhaust, unless it's economizing.
There is a exhaust fan at the zone level at 1,000 CFM.
The exhaust fan is separately ducted from the system. This is how the building stays neutral.
The auto-sizing always makes the supply and exhaust fans the same size, which is wrong.  Issue 1.
I am not sure how to tell the fresh air and exhaust air dampers to work with this 1,000 CFM offset.
It doesn't seem to have much for configuration.
Let us do a an example of this.
We will go to apply measure now. We will create a prototype building.
This is just a measure you can download from the building component library.
Click this measure.
We will just stick with small office. All the default stuff. Apply measure.
This has created a prototype office building for our simulation.
Go to the thermal zones tab. We have got five thermal zones and an attic.
None of them have an exhaust fan. We will just put an exhaust fan on zone 4.
We will set this to always on. Pressure. For flow rate: maybe 100 CFM.
Yeah, we can probably do more than that based on the building size. We will use 250 CFM.
You will note that the exhaust fan comes defaulted to Decoupled.
There are different ways to control exhaust fans at the zone level. By default, it come in Decoupled.
Decoupled means it is not reliant on the air loop HVAC system, that serves that zone, to turn it on and off.
Decoupled means that it it runs on its own schedule. But we want to use Coupled.
Coupled (with Always On availability schedule) means it is always available, and the Air Loop System turns it on and off.
Whenever this air loop system is turned on, then it will turn this exhaust fan on. That is what the Coupling does.
Go to the air loops tab. We will just take a look at this real quick.
We have got a unitary heat pump system, but for this we actually need to have a return fan.
We will put in a constant volume fan on the return side of the system.
This serves zone 4 (with the exhaust fan that we just placed).
Let us take a look at these. It looks like the whole system is set to Autosized.
...Flow rate when no cooling or heating is needed...
We will just leave that as AutoSized.
Autosized. OK.
We will run the simulation. It looks like the simulation has completed successfully.
Go to reports and select Air Loops. We will scroll down to zone 4.
OpenStudio results come in sequence of the equipment that is on the air loop.
It starts with the return side of the air loop. This would be the return fan.
It is sizing the return fan for 744 CFM and the unitary heat pump fan was sized for 744 CFM.
Despite us having an exhaust fan that is scheduled always on when the Air Loop is operating.
That is because EnergyPlus does Autosizing based on the loop only.
It does not take into account any external air balancing.
That is an important part to remember about EnergyPlus.
It does some select air balancing, but it doesn't do all air balancing.
So, you need to make sure that your system is balanced.
EnergyPlus does account for Air Loop balancing during the simulation because of that Coupled toggle switch that we selected on the exhaust fan.
See EnergyPlus Input Output Reference- Field: Balanced Exhaust Fraction Schedule Name
Let us take a look at the air flows on some of the system nodes.
Go to output variables. Go to system nodes...to far...system nodes.
We want to look for...here we go. Current density volume flow rate.
We will set the increment to time step. The time step of the simulation. Click Save.
Run the simulation again. Success. Go to results summary.
Scroll back down to zone 4. You will see the supply and return fans are sized the same.
Go to DView to view the output reports on this.
We will go back to the air loop so we can figure out what nodes to look at. Let us see here...
We want to take a look at the return node.
This is actually the supply inlet node and the supply outlet node. This is the supply side of the system.
Select perimeter zone 4 supply outlet node and supply inlet node.
You can see that the return air flow is quite a bit less than the supply side.
This is another important point to make. The way EnergyPlus calculates air flows and system size is based upon the zone level sizing.
EnergyPlus figures out zone level sizing first. Zone level mass flow rates.
Then, everything propagates out from that.
If the zone requires a certain amount of airflow, then you will follow the loop back to the first fan.
That fan will have to supply that amount of airflow at the specified pressure.
Likewise, there is a certain amount of return mass flow rate.
The the next fan in the loop has to flow that amount of flow rate (at the specified pressure).
These are not actually fans.  They are not pushing air as in real life.
EnergyPlus calculates fan energy use based on the airflow that the fan theoretically should have been flowing.
So, these fans don't actually push air into the zone and the zone receives it.
EnergyPlus back calculates from the zone and it tells the fan: you have to supply this amount of airflow at this pressure.
Based on the fan power curve, this is how much energy will be used.
You can see that the return air flow is lower than the supply air flow for that zone.
You can also check to see how the economizer dampers are operating.
We will select relief air and outdoor air and mixed air.
We would have to find these on here.
Here is the outdoor air node.
The outdoor air is flowing a little over 250 CFM.
That corresponds to the 250 CFM exhaust fan that we applied to the zone.
If we turn that exhaust fan off, you would probably see this ventilation air flow rate dropping lower than the 250 CFM.
But that exhaust fan is on and it is operating with the air loop.
The outdoor air flow rate in this outdoor air system has to flow a minimum of the 250 CFM. For that exhaust fan.
We can simulate this, if we wanted to. We will rerun the simulation with the exhaust fan turned off.
We can see what that outdoor air flow rate is.
Let us go back to the zone exhaust fan...
...better yet...we can turn the exhaust fan on and off in the middle of the schedule.
We will just create a new schedule. We will turn it off in the middle of the day.
So, we will see the difference. Go back to the exhaust fan. EF schedule. Save. Run.
Success. Let us open up DView again.
Take a look at the zone 4 outdoor air flow rate.
Select inlet node.
Outlet node. OK.
You can see that in the middle of the day the exhaust fan turns off.
The return air flow jumps right back up.
You can see: during the the first part of the day the exhaust fan is on and it is returning less air to the air handler.
Let us look at the outdoor air node.
Same thing.
You can see. During during the first part of the day, when the exhaust fan is on, the outdoor air system supplies extra air flow.
Then, when the exhaust fan turns off, the air flow drops down to minimum outdoor air.
Or, if it is economizing, it might drop down to a different setting.
That is how you know that the outdoor air system is operating correctly.
That is how you ensure that your exhaust fans are balanced with your air loop.
This is this is how you toggle that on and off.
If you want that exhaust fan to operate independently of the air loop, you can put it on decoupled.
Then, it will run on its own schedule, but it will still affect that return air flow to the loop.
So, going back to the original question.
The bottom line is: the auto sizing will size the system for the maximum airflow.
You may have a return fan that is actually sized for less.
Which, could important for energy calculations. You will have to hard size that to the supply air flow minus that exhaust air flow.
For this instance, we would have input Hard Sized maximum flow rate...
I believe the system airflow was...supply air flow is about 750 CFM.
We would size this for 500 CFM.
That is how you ensure that your return fan is sized properly.
Thank you. Please like and subscribe.

 

8. OpenStudio SketchUp Tips - Project Geometry Tool

We discuss how to use the project geometry tool in the OpenStudio SketchUp Plugin.  This tool is helpful for applying sub-surfaces to multiple spaces at one time.  

I will show you how to use the project geometry tool.  This action will help reduce computing time on the simulation .
We are looking at some windows. There are multiple windows that are very close together.
The divider in-between them really doesn't affect the energy simulation very much.
Draw some rectangles over the windows (external to the spaces).
Now, enter the spaces and delete these windows. Go through and delete all of these windows in the spaces.
Now, go up to the project loose geometry tool. We will project selected loose geometry.
Select these rectangles that we just created. Click the button. Yes.
It was successful. You can see that the windows have been applied to the individual spaces.
Thank you. Please like and subscribe.

 

9. OpenStudio Tips - Assign Space Type to Multiple Spaces

We discuss how to use the Building Component Library measure "AssignSpaceTypeBySpaceName" to quickly assign space types to spaces with a common string in the name.

Transcript:
If you have a lot of spaces that you want to assign a specific space type, you can use this measure on the building component library.
Go to "whole building", "space types". Search for "assign space type by space name".
You can download the measure. Go to "components and measures", "apply measure now".
Search for the measure under the "whole building" category. It is right here.
Please note: this string search is case specific. We can not search for both upper and lowercase "c" in corridor.
So, you want to make sure that your spaces are named consistently.
This check box does not seem to work, so don't use it.
The measure was successful. It assigned space types to 21 of our spaces.
Thank you. Please like and subscribe.

10. OpenStudio SketchUp Tips - Vertex Size Mismatch

 

We discuss how to resolve the common error "Vertex size mismatch between base surface".

We are going to discuss a common error, a severe error, that terminates your simulation.
We will go to the error output file. We are looking at this error in particular. Vertex size mismatch between base surface.
It is saying there is a mismatch between this surface 4840 and the surface 149.
You can see that it repeats itself. There is a 4840 here and then further down it shows the same error.
It is just reversed. So, it looks like there is a lot of errors. There is really only half of them.
Once you resolve one, then the other one will be resolved.
We will be looking at this surface 4830 and surface 4897.
It is saying that there are 11 vertices on surface 4830. There are 7 vertices on surface 4897.
We can go to the OSM file and verify that. We will search for surface 4830.
You can see that this surface 4830 has eleven vertices. The other one was surface 4897...This one has seven vertices.
Let us go to the OpenStudio SketchUp plugin. Open up the OpenStudio inspector tool.
We will adjust this a little bit...Select the “Surfaces” category.
It says that our model has 8,576 surfaces.
We want to search for surface 4830. Right here. It says that this surface 4830 is associated with the Space “Hallway 4-3”.
The surface 4897...let us look for that 4897...right here.
This is associated with the Space “Plenum 3-4-N”.
Let us go to our spaces. Search for that “Hallway 4-3”.
It is right there. Let us search for the “Plenum 3-4”. It is right there. It is right below “Hallway 4-3”.
Let us go back to the “Hallway 4-3”.  We will use the shift key, and click to add the “Plenum 4-3” to our selection.
Now, let us do a top view.  We are going to right-to-left drag while holding the shift key.
This will select everything else. It will also deselect those two spaces that we had selected.
Now, use the Hide function. That hides all the other geometry.
We have now narrowed down our search to these two spaces that have the matching surfaces.
Then, we can double-click into one of the spaces.
Now, search for the surface again. 4830...it is not that one...4830 must be associated with...
Oh, there it is. Right there. So, it is this surface here. 4830.
I am sorry. It must be associated with the other space. This is 4897, which is the matching surface to 4830.
It had selected the 4830 in the other, inactive space.
We can see that it is located on the top of this plenum. We will do a side view...
Maybe like this...
or like this...
We will do a right-to-left drag select.  We will hide these surfaces. This will make it easier for us to identify the surfaces.
We can see that this is one of the problem surfaces.  4897.
Click out of this space. Now, double click into this space. We see that it is associated with this surface 4830.
We will click out. You can see that those surfaces are matched.
EnergyPlus thinks that these two surfaces do not have the same number of vertices.
We can select the surface and double click to highlight it. Count the vertices: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11.
This is surface 4897, so it should have 11 vertices.
If we look at our error output...4897...the error output file is saying that it only has seven vertices.
I do not know why. I suspect that it has something to do with SketchUp.
I think SketchUp is simplifying. It is defining this surface based on some of these other surfaces that are attached.
So...there is a vertex that is shared with these other surfaces.
Instead of outputting all of the vertices for this surface, it is just out outputting the the minimum number of vertices to define the surface.
Some of these other surfaces have that vertex in in their definition.
Somehow this confuses OpenStudio. I have discovered. The solution is to divide the surface.
We can draw a line from this vertex to this vertex. That divides the surface in half.
Now we have two surfaces. 4898 and 4897.
Now we have to divide the surface on on the matching surface.
We will just draw a line to connect these vertices. That divides the surface in half.
Oh...looks like I messed up on something here.  Let us go back to this one here.
You have to be very careful when you are adding this geometry.
Divide that surface into two. We can see that it is now two surfaces.
So, this is surface 4899 and this is surface 4898.
We need to make sure that it is matched with 4899. Same thing for the other surface that was created. 4897.
It should be matched with 4830. Yes. 4897. That is how you solve vertex mismatch issues.
You may have to further subdivide the surfaces.
Once you get down to about four vertices, there is fewer problems.
You may find that you still have a persistent problem.
A rough workaround: make the surface adiabatic. Select the surface. Go to boundary condition. Click adiabatic.
Sorry. You will have to unmatch the surface first. Unmatch it. Then select “adiabatic”.
It turns it pink. Make the matching surface adiabatic as well.
It got unmatched but it is still looking for a boundary condition.
This says it defaulted to “ground”. We want to make it adiabatic also.
Adiabatic tells EnergyPlus that there will be no heat transfer in between these two surfaces.
If it is a small surface, it may not be a big problem.  The energy model results will not be significantly affected.
If the the room temperatures between the two spaces are similar, there is little heat transfer anyway.
But, if there is a large temperature difference, you might consider trying to further subdivide the surfaces.
That is the workaround for solving the vertex mismatch severe error.
If you like these videos, please like and subscribe.
Thank you.

11. OpenStudio Tips - How to lodge issues on GitHub

We discuss OpenStudio and the SketchUp plugin open-source project and how users can contribute by lodging issues on GitHub.

The OpenStudio application is supported by the OpenStudio Coalition.
They are a group of volunteers and paid programmers that keep up and maintain the OpenStudio application.
They rely on feedback from users to help resolve issues with the software.
I will show you how to lodge an issue on GitHub; If you discover issues with the OpenStudio application or the OpenStudio SketchUp plug-in.
You would need to sign up for an account on github.com.
Then, you can follow the the two programs.
We will be lodging an issue on the OpenStudio application today.
We will go to issues. Create a new issue.
This is a categorized as a bug report.
If you have an enhancement request, you can also do that.
Let us do a bug report. Give it a title.
This is basically where you describe what the issue is.
We will just say “The application crashes when the user tries to delete an HVAC Airloop.”
There is not really much more to it.
I did capture a screenshot or actually a gif video of what happens when this problem occurs.
You can see here that the user selects the Airloop and tries to delete it.  It crashes the program.
We will upload this gif to the current behavior section.
There is not much more info I have.
If there is additional information you think might be necessary, you can describe the steps to reproduce the issue.
If you have any suggestions for solutions, you can add that information in there.  Or, additional details that narrow down the problem.
We are running windows 10.
The version of the application is OpenStudio 110r3.
Yeah. That is pretty much it.
Now, just scroll down to the bottom and submit new issue.
Now, it is submitted as a new issue.  If needed, you can always add more info later.
The programmers will eventually see it and hopefully address it.
Thank you. Please like and subscribe.

 
 
  • Fb

Copyright© 2016 by Helix Energy Partners LLC  Helix, Oregon | Terms & Conditions | Privacy Policy