OpenStudio:model
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Pages
Public Member Functions | Related Functions | List of all members
openstudio::model::Surface Class Reference

#include <Surface.hpp>

+ Inheritance diagram for openstudio::model::Surface:

Public Member Functions

boost::optional< FoundationKivaadjacentFoundation () const
 
boost::optional< SurfaceadjacentSurface () const
 Returns the adjacent Surface, if it exists. More...
 
boost::optional
< AirflowNetworkSurface
airflowNetworkSurface () const
 
std::vector< SubSurfaceapplyViewAndDaylightingGlassRatios (double viewGlassToWallRatio, double daylightingGlassToWallRatio, double desiredViewGlassSillHeight, double desiredDaylightingGlassHeaderHeight, double exteriorShadingProjectionFactor, double interiorShelfProjectionFactor, const boost::optional< ConstructionBase > &viewGlassConstruction, const boost::optional< ConstructionBase > &daylightingGlassConstruction)
 Applies banded view and daylighting windows to the surface with optional exterior shading and interior light shelf. More...
 
void assignDefaultBoundaryCondition ()
 Assign default boundary condition. More...
 
void assignDefaultSunExposure ()
 Assign default sun exposure. More...
 
void assignDefaultSurfaceType ()
 Assign default surface type based on vertices. More...
 
void assignDefaultWindExposure ()
 Assign default wind exposure. More...
 
boost::optional
< SurfaceIntersection
computeIntersection (Surface &otherSurface)
 
boost::optional< SurfacecreateAdjacentSurface (const Space &otherSpace)
 Creates an adjacent Surface in another Space, also create adjacent SubSurface objects if needed. More...
 
std::vector< SubSurfacecreateSubSurfaces (const std::vector< std::vector< Point3d >> &faces, double inset, const boost::optional< ConstructionBase > &construction)
 Moves all of the surfaces vertices towards the centroid by inset then intersects each face with the inset polygon. More...
 
boost::optional
< SurfacePropertyExposedFoundationPerimeter
createSurfacePropertyExposedFoundationPerimeter (const std::string &exposedPerimeterCalculationMethod, double exposedPerimeter)
 
double exposedPerimeter (const Polygon3d &buildingPerimeter) const
 
double filmResistance () const
 Returns the default film thermal resistance (m^2*K/W) for this surface. More...
 
AirflowNetworkSurface getAirflowNetworkSurface (const AirflowNetworkDetailedOpening &surfaceAirflowLeakage)
 
AirflowNetworkSurface getAirflowNetworkSurface (const AirflowNetworkSimpleOpening &surfaceAirflowLeakage)
 
AirflowNetworkSurface getAirflowNetworkSurface (const AirflowNetworkCrack &surfaceAirflowLeakage)
 
AirflowNetworkSurface getAirflowNetworkSurface (const AirflowNetworkEffectiveLeakageArea &surfaceAirflowLeakage)
 
AirflowNetworkSurface getAirflowNetworkSurface (const AirflowNetworkHorizontalOpening &surfaceAirflowLeakage)
 
AirflowNetworkSurface getAirflowNetworkSurface (const AirflowNetworkSpecifiedFlowRate &surfaceAirflowLeakage)
 
bool intersect (Surface &otherSurface)
 Intersect with other Surface in other Space. More...
 
bool isPartOfEnvelope () const
 Returns true if the Surface is part of the building envelope. More...
 
void resetAdjacentFoundation ()
 
void resetAdjacentSurface ()
 Resets the adjacent Surface. More...
 
void resetSurfacePropertyExposedFoundationPerimeter ()
 
void resetSurfacePropertyOtherSideCoefficients ()
 Resets the SurfacePropertyOtherSideCoefficients. More...
 
void resetSurfacePropertyOtherSideConditionsModel ()
 Resets the SurfacePropertyOtherSideConditionsModel. More...
 
bool setAdjacentFoundation (const FoundationKiva &kiva)
 
bool setAdjacentSurface (Surface &surface)
 Sets the adjacent Surface, will clear adjacent surface on other surface. More...
 
bool setSpace (const Space &space)
 Sets the parent Space. More...
 
bool setSurfacePropertyOtherSideCoefficients (const SurfacePropertyOtherSideCoefficients &otherSideCoefficients)
 Sets the SurfacePropertyOtherSideCoefficients. More...
 
bool setSurfacePropertyOtherSideConditionsModel (const SurfacePropertyOtherSideConditionsModel &otherSideModel)
 Sets the SurfacePropertyOtherSideConditionsModel. More...
 
boost::optional< SubSurfacesetWindowToWallRatio (double wwr)
 Sets the window to wall ratio for this surface using a single banded window. More...
 
boost::optional< SubSurfacesetWindowToWallRatio (double wwr, double desiredHeightOffset, bool heightOffsetFromFloor)
 Same as setWindowToWallRatio but with extra parameters desiredHeightOffset and heightOffsetFromFloor. More...
 
std::vector< ShadingSurfaceGroupshadingSurfaceGroups () const
 Returns any shading surface groups associated with this surface. More...
 
double skylightToProjectedFloorRatio () const
 Get the skylight to projected floor ratio for this surface. More...
 
double skylightToRoofRatio () const
 Get the skylight to roof ratio for this surface. More...
 
std::vector< SurfacesplitSurfaceForSubSurfaces ()
 Splits this surface vertically surrounding any sub surfaces. More...
 
std::vector< SubSurfacesubSurfaces () const
 Returns all child SubSurfaces . More...
 
boost::optional
< SurfaceControlMovableInsulation
surfaceControlMovableInsulation () const
 Returns the SurfaceControlMovableInsulation, if it exists. More...
 
boost::optional
< SurfacePropertyConvectionCoefficients
surfacePropertyConvectionCoefficients () const
 Returns the SurfacePropertyConvectionCoefficients, if it exists. More...
 
boost::optional
< SurfacePropertyExposedFoundationPerimeter
surfacePropertyExposedFoundationPerimeter () const
 
boost::optional
< SurfacePropertyLocalEnvironment
surfacePropertyLocalEnvironment () const
 Returns the SurfacePropertyLocalEnvironment, if it exists. More...
 
boost::optional
< SurfacePropertyOtherSideCoefficients
surfacePropertyOtherSideCoefficients () const
 Returns the adjacent SurfaceSurfacePropertyOtherSideCoefficients, if it exists. More...
 
boost::optional
< SurfacePropertyOtherSideConditionsModel
surfacePropertyOtherSideConditionsModel () const
 Returns the adjacent SurfacePropertyOtherSideConditionsModel, if it exists. More...
 
double windowToWallRatio () const
 Get the window to wall ratio for this surface. More...
 
Constructors and Destructors
 Surface (const std::vector< Point3d > &vertices, const Model &model)
 
virtual ~Surface ()=default
 
 Surface (const Surface &other)=default
 
 Surface (Surface &&other)=default
 
Surfaceoperator= (const Surface &)=default
 
Surfaceoperator= (Surface &&)=default
 
Getters
std::string surfaceType () const
 
std::string outsideBoundaryCondition () const
 
bool isGroundSurface () const
 Returns true if the surface has outsideBoundaryCondition of Ground, GroundFCfactorMethod GroundSlabPreprocessorAverage, GroundSlabPreprocessorCore, GroundSlabPreprocessorPerimeter, GroundBasementPreprocessorAverageWall, GroundBasementPreprocessorAverageFloor, GroundBasementPreprocessorUpperWall, GroundBasementPreprocessorLowerWall, or Foundation. More...
 
std::string sunExposure () const
 
bool isSunExposureDefaulted () const
 
std::string windExposure () const
 
bool isWindExposureDefaulted () const
 
boost::optional< double > viewFactortoGround () const
 
bool isViewFactortoGroundDefaulted () const
 
bool isViewFactortoGroundAutocalculated () const
 
boost::optional< double > numberofVertices () const
 
bool isNumberofVerticesDefaulted () const
 
bool isNumberofVerticesAutocalculated () const
 
Setters
bool setSurfaceType (const std::string &surfaceType)
 
bool setOutsideBoundaryCondition (const std::string &outsideBoundaryCondition)
 
bool setSunExposure (const std::string &sunExposure)
 
void resetSunExposure ()
 
bool setWindExposure (const std::string &windExposure)
 
void resetWindExposure ()
 
bool setViewFactortoGround (boost::optional< double > viewFactortoGround)
 
bool setViewFactortoGround (double viewFactortoGround)
 
void resetViewFactortoGround ()
 
void autocalculateViewFactortoGround ()
 
bool setNumberofVertices (boost::optional< double > numberofVertices)
 
bool setNumberofVertices (double numberofVertices)
 
void resetNumberofVertices ()
 
void autocalculateNumberofVertices ()
 
- Public Member Functions inherited from openstudio::model::PlanarSurface
double azimuth () const
 Returns the surface's azimuth measured clockwise as angle between outward normal and local North (radians). More...
 
Point3d centroid () const
 Return the centroid of this planar surface's vertices. More...
 
bool equalVertices (const PlanarSurface &other) const
 Check if this planar surface's vertices are equal to the other's in the building coordinate system. More...
 
boost::optional< double > exteriorVisibleAbsorptance () const
 Returns exterior visible absorptance (unitless), if available. More...
 
std::vector
< GeneratorPhotovoltaic
generatorPhotovoltaics () const
 Returns any generator photovoltaics associated with this surface. More...
 
double grossArea () const
 Computes the surface's gross area (m^2). More...
 
boost::optional< double > heatCapacity () const
 
boost::optional< double > interiorVisibleAbsorptance () const
 
bool isAirWall () const
 Checks if this surface is an air wall, returns true if it's a ConstructionAirBoundary. More...
 
bool isConvex () const
 
double netArea () const
 Computes the surface's net area (m^2). More...
 
Vector3d outwardNormal () const
 Returns the outward normal vector in local coordinates. More...
 
Plane plane () const
 Get the plane, throws openstudio::Exception if cannot compute plane for this surface. More...
 
bool reverseEqualVertices (const PlanarSurface &other) const
 Check if this planar surface's vertices are reverse equal to the other's in the building coordinate system. More...
 
bool setThermalConductance (double value)
 
bool setUFactor (double value)
 Sets the u-factor of this surface in W/m^2*K, if possible. More...
 
std::vector< ModelObjectsolarCollectors () const
 Returns any solar hot water collectors associated with this surface. More...
 
bool subtractFromGrossArea () const
 Reports if user should subtract this surface's net area from parent's gross area to compute parent's net area (e.g. More...
 
std::vector
< SurfacePropertyConvectionCoefficients
surfacePropertyConvectionCoefficients () const
 Returns any SurfacePropertyConvectionCoefficients associated with this surface, does not return SurfacePropertyConvectionCoefficientsMultipleSurface. More...
 
boost::optional< double > thermalConductance () const
 
double tilt () const
 Returns the surface's tilt measured as angle between outward normal and local up (radians). More...
 
virtual std::vector
< std::vector< Point3d > > 
triangulation () const
 Get a triangulation of this surface, subsurfaces will be replaced by holes in the triangulation. More...
 
boost::optional< double > uFactor () const
 
boost::optional< double > visibleTransmittance () const
 Returns visible transmittance (unitless), if available. More...
 
boost::optional< ConstructionBaseconstruction () const
 Returns the construction object. More...
 
boost::optional< std::pair
< ConstructionBase, int > > 
constructionWithSearchDistance () const
 Returns the construction object and the search distance that was needed to find the construction. More...
 
bool isConstructionDefaulted () const
 Returns true if the construction is not directly referenced by this surface . More...
 
boost::optional
< PlanarSurfaceGroup
planarSurfaceGroup () const
 Returns the containing PlanarSurfaceGroup if available. More...
 
boost::optional< Spacespace () const
 Returns the containing Space if available. More...
 
std::vector< Point3dvertices () const
 Returns the vertices. More...
 
bool setVertices (const std::vector< Point3d > &vertices)
 Sets the vertices. More...
 
bool setConstruction (const ConstructionBase &construction)
 Sets the construction object. More...
 
void resetConstruction ()
 Resets the construction object. More...
 
virtual ~PlanarSurface ()=default
 
 PlanarSurface (const PlanarSurface &other)=default
 
 PlanarSurface (PlanarSurface &&other)=default
 
PlanarSurfaceoperator= (const PlanarSurface &)=default
 
PlanarSurfaceoperator= (PlanarSurface &&)=default
 
- Public Member Functions inherited from openstudio::model::ParentObject
std::vector< IddObjectType > allowableChildTypes () const
 Returns a vector of allowable children types. More...
 
std::vector< ModelObjectchildren () const
 Return direct child objects in the Model. More...
 
ParentObjectoperator= (const ParentObject &)=default
 
ParentObjectoperator= (ParentObject &&)=default
 
 ParentObject (const ParentObject &other)=default
 
 ParentObject (ParentObject &&other)=default
 
virtual ~ParentObject ()=default
 
- Public Member Functions inherited from openstudio::model::ModelObject
virtual ~ModelObject ()=default
 
 ModelObject (const ModelObject &other)=default
 
 ModelObject (ModelObject &&other)=default
 
ModelObjectoperator= (const ModelObject &)=default
 
ModelObjectoperator= (ModelObject &&)=default
 
ModelObject clone () const
 Creates a deep copy of this object, placing it in this object's model(). More...
 
ModelObject clone (Model model) const
 Creates a deep copy of this object, placing it in model. More...
 
Component createComponent () const
 Method for creating sharable Model snippets. More...
 
Model model () const
 Returns the Model that contains this object. More...
 
boost::optional< ParentObjectparent () const
 Return this object's parent in the hierarchy, if it has one. More...
 
std::vector< ResourceObjectresources () const
 Get the resources directly used by this ModelObject. More...
 
template<typename T >
std::vector< T > getModelObjectSources () const
 Get all objects of type T that point to this object. More...
 
template<typename T >
std::vector< T > getModelObjectSources (IddObjectType iddObjectType) const
 Get all objects of type T that point to this object. More...
 
template<typename T >
boost::optional< T > getModelObjectTarget (unsigned index) const
 Get the object of type T pointed to by this object from field index. More...
 
template<typename T >
std::vector< T > getModelObjectTargets () const
 Get all objects of type T to which this object points. More...
 
const std::vector< std::string > & outputVariableNames () const
 Get all output variables names that could be associated with this object. More...
 
std::vector< OutputVariableoutputVariables () const
 Get all output variables associated with this object, must run simulation to generate data. More...
 
boost::optional
< openstudio::TimeSeries
getData (const OutputVariable &variable, const std::string &envPeriod) const
 Get data associated with this output variable and this object. More...
 
std::vector< LifeCycleCostlifeCycleCosts () const
 Returns the list of all LifeCycleCosts that refer to this object. More...
 
std::vector< IdfObjectremoveLifeCycleCosts ()
 Removes all LifeCycleCosts that refer to this object. More...
 
IddObjectType iddObjectType () const
 This is a virtual function that will tell you the type of iddObject you are dealing with. More...
 
AdditionalProperties additionalProperties () const
 Returns this object's additional properties, constructing a new object if necessary. More...
 
bool hasAdditionalProperties () const
 Returns true if this object has additional properties. More...
 
std::vector< IdfObjectremoveAdditionalProperties ()
 Removes all additional properties that refer to this object. More...
 
boost::optional< std::string > cadObjectId () const
 
bool setCADObjectId (const std::string &cadObjectId)
 
boost::optional< std::string > gbXMLId () const
 
bool setGBXMLId (const std::string &gbXMLId)
 
boost::optional< std::string > displayName () const
 
bool setDisplayName (const std::string &displayName)
 
bool setParent (ParentObject &newParent)
 set the parent, child may have to call non-const methods on the parent More...
 
bool operator< (const ModelObject &right) const
 
bool operator== (const ModelObject &other) const
 equality test More...
 
bool operator!= (const ModelObject &other) const
 inequality test More...
 
std::vector< ScheduleTypeKeygetScheduleTypeKeys (const Schedule &schedule) const
 Return the ScheduleTypeKeys indicating how schedule is used in this object. More...
 
boost::optional< double > getAutosizedValue (const std::string &valueName, const std::string &units) const
 Gets the autosized component value from the sql file. More...
 
virtual std::vector
< EMSActuatorNames
emsActuatorNames () const
 Return the names of the available ems actuators. More...
 
virtual std::vector< std::string > emsInternalVariableNames () const
 Return the names of the available ems internal variables. More...
 
boost::optional< ModelObjectconnectedObject (unsigned port) const
 
boost::optional< unsigned > connectedObjectPort (unsigned port) const
 
- Public Member Functions inherited from openstudio::WorkspaceObject
bool canBeSource () const
 
bool canBeSource (unsigned index, const std::vector< std::string > &refLists=std::vector< std::string >()) const
 
std::vector< std::string > canBeTarget () const
 
std::vector< unsigned > getSourceIndices (const Handle &targetHandle) const
 
std::vector< WorkspaceObjectgetSources (IddObjectType type) const
 
boost::optional< WorkspaceObjectgetTarget (unsigned index) const
 
IdfObject idfObject ()
 
IdfObject idfObject () const
 
bool initialized () const
 
bool isSource () const
 
bool isTarget () const
 
unsigned numSources () const
 
bool objectListFieldsEqual (const WorkspaceObject &other) const
 
bool objectListFieldsNonConflicting (const WorkspaceObject &other) const
 
bool operator< (const WorkspaceObject &right) const
 
std::ostream & operator<< (std::ostream &os, const WorkspaceObject &workspaceObject)
 
WorkspaceObjectoperator= (WorkspaceObject &&)=default
 
WorkspaceObjectoperator= (const WorkspaceObject &)=default
 
std::vector
< openstudio::IdfObject
remove ()
 
bool setPointer (unsigned index, const Handle &targetHandle)
 
std::vector< WorkspaceObjectsources () const
 
std::vector< WorkspaceObjecttargets () const
 
Workspace workspace () const
 
 WorkspaceObject (const WorkspaceObject &other)=default
 
 WorkspaceObject (WorkspaceObject &&other)=default
 
virtual ~WorkspaceObject ()=default
 
- Public Member Functions inherited from openstudio::IdfObject
std::string briefDescription () const
 
cast () const
 
std::vector< T > castVector (const std::vector< U > &objects)
 
std::vector< std::vector
< std::string > > 
clearExtensibleGroups ()
 
IdfObject clone (bool keepHandle=false) const
 
std::string comment () const
 
boost::optional< std::string > createName (bool overwrite=true)
 
std::vector< unsigned > dataFields () const
 
bool dataFieldsEqual (const IdfObject &other) const
 
std::vector< std::string > eraseExtensibleGroup (unsigned groupIndex)
 
std::vector< IdfExtensibleGroupextensibleGroups () const
 
boost::optional< std::string > fieldComment (unsigned index, bool returnDefault=false) const
 
boost::optional< double > getDouble (unsigned index, bool returnDefault=false) const
 
IdfExtensibleGroup getExtensibleGroup (unsigned groupIndex) const
 
boost::optional< std::string > getField (unsigned index, bool returnDefault=false) const
 
std::vector< Handle > getHandles (const std::vector< T > &objects)
 
boost::optional< intgetInt (unsigned index, bool returnDefault=false) const
 
OSOptionalQuantity getQuantity (unsigned index, bool returnDefault=false, bool returnIP=false) const
 
boost::optional< std::string > getString (unsigned index, bool returnDefault=false, bool returnUninitializedEmpty=false) const
 
boost::optional< unsigned > getUnsigned (unsigned index, bool returnDefault=false) const
 
Handle handle () const
 
IddObject iddObject () const
 
 IdfObject (IddObjectType type, bool fastName=false)
 
 IdfObject (const IdfObject &other)
 
 IdfObject (const IddObject &, bool fastName=false)
 
 IdfObject (IdfObject &&other) noexcept
 
IdfExtensibleGroup insertExtensibleGroup (unsigned groupIndex)
 
IdfExtensibleGroup insertExtensibleGroup (unsigned groupIndex, const std::vector< std::string > &values)
 
bool isDataField (unsigned index) const
 
bool isEmpty (unsigned index) const
 
bool isObjectListField (unsigned index) const
 
bool isValid (StrictnessLevel level, bool checkNames=false) const
 
boost::optional< unsigned > maxExtensibleGroups () const
 
boost::optional< unsigned > maxFields () const
 
unsigned minExtensibleGroups () const
 
unsigned minFields () const
 
boost::optional< std::string > name (bool returnDefault=false) const
 
std::string nameString (bool returnDefault=false) const
 
unsigned numExtensibleGroups () const
 
unsigned numFields () const
 
unsigned numNonextensibleFields () const
 
std::vector< unsigned > objectListFields () const
 
bool objectListFieldsEqual (const IdfObject &other) const
 
bool objectListFieldsNonConflicting (const IdfObject &other) const
 
bool operator!= (const IdfObject &other) const
 
std::ostream & operator<< (std::ostream &os, const IdfObject &IdfObject)
 
IdfObjectoperator= (IdfObject &&other) noexcept
 
IdfObjectoperator= (const IdfObject &other)
 
bool operator== (const IdfObject &other) const
 
boost::optional< T > optionalCast () const
 
std::vector< std::string > popExtensibleGroup ()
 
std::ostream & print (std::ostream &os) const
 
std::ostream & printField (std::ostream &os, unsigned index, bool isLastField=false) const
 
std::ostream & printName (std::ostream &os, bool hasFields=true) const
 
IdfExtensibleGroup pushExtensibleGroup (const std::vector< std::string > &values)
 
IdfExtensibleGroup pushExtensibleGroup ()
 
std::vector< unsigned > requiredFields () const
 
void setComment (const std::string &msg)
 
bool setDouble (unsigned index, double value)
 
bool setFieldComment (unsigned index, const std::string &cmnt)
 
bool setInt (unsigned index, int value)
 
boost::optional< std::string > setName (const std::string &newName)
 
bool setQuantity (unsigned index, const Quantity &q)
 
bool setString (unsigned index, const std::string &value)
 
bool setUnsigned (unsigned index, unsigned value)
 
std::vector< T > subsetCastVector (const std::vector< U > &original)
 
ValidityReport validityReport (StrictnessLevel level, bool checkNames=false) const
 
virtual ~IdfObject ()=default
 

Static Public Member Functions

Static Methods
static IddObjectType iddObjectType ()
 
static std::vector< std::string > validSurfaceTypeValues ()
 
static std::vector< std::string > validOutsideBoundaryConditionValues ()
 
static std::vector< std::string > validSunExposureValues ()
 
static std::vector< std::string > validWindExposureValues ()
 
- Static Public Member Functions inherited from openstudio::model::PlanarSurface
static double filmResistance (const FilmResistanceType &type)
 Film resistances from ASHRAE Fundamentals, Chapter 25, Table 1 for non-reflective surfaces. More...
 
static std::vector< PlanarSurfacefindPlanarSurfaces (const std::vector< PlanarSurface > &planarSurfaces, boost::optional< double > minDegreesFromNorth, boost::optional< double > maxDegreesFromNorth, boost::optional< double > minDegreesTilt, boost::optional< double > maxDegreesTilt, double tol=1)
 Find PlanarSurfaces within angular range, specified in degrees in the site coordinate system, an unset optional means no limit. More...
 
static double stillAirFilmResistance (double tilt)
 Film resistance of still air on surface with tilt (rad). More...
 
- Static Public Member Functions inherited from openstudio::IdfObject
static boost::optional< IdfObjectload (const std::string &text)
 
static boost::optional< IdfObjectload (const std::string &text, const IddObject &iddObject)
 
static int printedFieldSpace ()
 

Related Functions

(Note that these are not member functions.)

using OptionalSurface = boost::optional< Surface >
 
using SurfaceVector = std::vector< Surface >
 

Additional Inherited Members

- Public Types inherited from openstudio::WorkspaceObject
typedef boost::optional
< WorkspaceObject
OptionalWorkspaceObject
 
typedef std::vector
< WorkspaceObject
WorkspaceObjectVector
 
- Public Types inherited from openstudio::IdfObject
typedef std::pair< IdfObject,
IdfObject
IdfObjectPair
 
typedef std::vector< IdfObjectIdfObjectVector
 
typedef boost::optional
< IdfObject
OptionalIdfObject
 
- Protected Types inherited from openstudio::model::ModelObject
using ImplType = detail::ModelObject_Impl
 
- Protected Types inherited from openstudio::WorkspaceObject
typedef
detail::WorkspaceObject_Impl 
ImplType
 
- Protected Types inherited from openstudio::IdfObject
typedef detail::IdfObject_Impl ImplType
 
- Protected Member Functions inherited from openstudio::model::PlanarSurface
 PlanarSurface (IddObjectType type, const std::vector< Point3d > &vertices, const Model &model)
 Constructs a new PlanarSurface object in the model. More...
 
- Protected Member Functions inherited from openstudio::model::ParentObject
 ParentObject (IddObjectType type, const Model &model)
 Constructs a new ParentObject object in the model. More...
 
- Protected Member Functions inherited from openstudio::model::ModelObject
 ModelObject (IddObjectType type, const Model &model, bool fastName=false)
 
 ModelObject (std::shared_ptr< detail::ModelObject_Impl > impl)
 
- Protected Member Functions inherited from openstudio::WorkspaceObject
 WorkspaceObject (std::shared_ptr< detail::WorkspaceObject_Impl > impl)
 
- Protected Member Functions inherited from openstudio::IdfObject
 IdfObject (std::shared_ptr< detail::IdfObject_Impl > impl)
 

Detailed Description

Surface is a PlanarSurface that wraps the OpenStudio IDD object 'OS_Surface'.

Constructor & Destructor Documentation

openstudio::model::Surface::Surface ( const std::vector< Point3d > &  vertices,
const Model model 
)
explicit
virtual openstudio::model::Surface::~Surface ( )
virtualdefault
openstudio::model::Surface::Surface ( const Surface other)
default
openstudio::model::Surface::Surface ( Surface &&  other)
default

Member Function Documentation

boost::optional<FoundationKiva> openstudio::model::Surface::adjacentFoundation ( ) const
boost::optional<Surface> openstudio::model::Surface::adjacentSurface ( ) const

Returns the adjacent Surface, if it exists.

boost::optional<AirflowNetworkSurface> openstudio::model::Surface::airflowNetworkSurface ( ) const
std::vector<SubSurface> openstudio::model::Surface::applyViewAndDaylightingGlassRatios ( double  viewGlassToWallRatio,
double  daylightingGlassToWallRatio,
double  desiredViewGlassSillHeight,
double  desiredDaylightingGlassHeaderHeight,
double  exteriorShadingProjectionFactor,
double  interiorShelfProjectionFactor,
const boost::optional< ConstructionBase > &  viewGlassConstruction,
const boost::optional< ConstructionBase > &  daylightingGlassConstruction 
)

Applies banded view and daylighting windows to the surface with optional exterior shading and interior light shelf.

Assumes that this surface spans the entire height of the space, this method should not be used if the wall is broken into multiple vertical pieces.

Returns false if the surface is not a wall, if the surface is not rectangular in face coordinates, if requested ratio is too large (window area ~= surface area), or if surface has any doors.

Otherwise, removes all existing windows and adds new windows to meet requested ratio.

viewGlassToWallRatio - the ratio of view glass to wall area, if 0 no view glass will be created daylightingGlassToWallRatio - the ratio of daylighting glass to wall area, if 0 no daylighting glass will be created desiredViewGlassSillHeight - the desired distance from the floor to the bottom of the view glass, this may be reduced if the requested window area is too high desiredDaylightingGlassHeaderHeight - the distance from the ceiling to the top of the daylighting glass, this may be reduced if the requested window area is too high exteriorShadingProjectionFactor - projection factor of exterior shading applied to the view window, if 0 no exterior shading will be created interiorShelfProjectionFactor - projection factor of interior light shelf applied to the daylighting window, if 0 no interior light shelf will be created viewGlassConstruction - optional construction to use for the view glass daylightingGlassConstruction - optional construction to use for the daylighting glass

If successful returns a vector of sub surfaces created, view window will be the first in the vector if viewGlassToWallRatio > 0

void openstudio::model::Surface::assignDefaultBoundaryCondition ( )

Assign default boundary condition.

void openstudio::model::Surface::assignDefaultSunExposure ( )

Assign default sun exposure.

void openstudio::model::Surface::assignDefaultSurfaceType ( )

Assign default surface type based on vertices.

void openstudio::model::Surface::assignDefaultWindExposure ( )

Assign default wind exposure.

void openstudio::model::Surface::autocalculateNumberofVertices ( )
void openstudio::model::Surface::autocalculateViewFactortoGround ( )
boost::optional<SurfaceIntersection> openstudio::model::Surface::computeIntersection ( Surface otherSurface)
boost::optional<Surface> openstudio::model::Surface::createAdjacentSurface ( const Space otherSpace)

Creates an adjacent Surface in another Space, also create adjacent SubSurface objects if needed.

Returns the new Surface if created.

std::vector<SubSurface> openstudio::model::Surface::createSubSurfaces ( const std::vector< std::vector< Point3d >> &  faces,
double  inset,
const boost::optional< ConstructionBase > &  construction 
)

Moves all of the surfaces vertices towards the centroid by inset then intersects each face with the inset polygon.

Faces are in space coordinates, it is expected that not all faces will intersect the surface. Returns all new sub surfaces created, sub surface types are defaulted. Optional construction is applied. Returns false is this surface has any current sub surfaces or if there is an adjacent surface.

boost::optional<SurfacePropertyExposedFoundationPerimeter> openstudio::model::Surface::createSurfacePropertyExposedFoundationPerimeter ( const std::string &  exposedPerimeterCalculationMethod,
double  exposedPerimeter 
)
double openstudio::model::Surface::exposedPerimeter ( const Polygon3d buildingPerimeter) const
double openstudio::model::Surface::filmResistance ( ) const

Returns the default film thermal resistance (m^2*K/W) for this surface.

Assumes still indoor air, and 15 mph wind outside. Does not consider any custom SurfacePropertyConvectionCoefficients.

AirflowNetworkSurface openstudio::model::Surface::getAirflowNetworkSurface ( const AirflowNetworkDetailedOpening surfaceAirflowLeakage)
AirflowNetworkSurface openstudio::model::Surface::getAirflowNetworkSurface ( const AirflowNetworkSimpleOpening surfaceAirflowLeakage)
AirflowNetworkSurface openstudio::model::Surface::getAirflowNetworkSurface ( const AirflowNetworkCrack surfaceAirflowLeakage)
AirflowNetworkSurface openstudio::model::Surface::getAirflowNetworkSurface ( const AirflowNetworkEffectiveLeakageArea surfaceAirflowLeakage)
AirflowNetworkSurface openstudio::model::Surface::getAirflowNetworkSurface ( const AirflowNetworkHorizontalOpening surfaceAirflowLeakage)
AirflowNetworkSurface openstudio::model::Surface::getAirflowNetworkSurface ( const AirflowNetworkSpecifiedFlowRate surfaceAirflowLeakage)
static IddObjectType openstudio::model::Surface::iddObjectType ( )
static
bool openstudio::model::Surface::intersect ( Surface otherSurface)

Intersect with other Surface in other Space.

Returns false if either surface has child windows. Returns false if either surface has an adjacent surface. Returns false if surfaces are not on the same plane with opposing outward normals. If the surfaces are the same, returns true but no new geometry is created. Returns true if an intersection occurred. Does not set surface adjacency.

bool openstudio::model::Surface::isGroundSurface ( ) const

Returns true if the surface has outsideBoundaryCondition of Ground, GroundFCfactorMethod GroundSlabPreprocessorAverage, GroundSlabPreprocessorCore, GroundSlabPreprocessorPerimeter, GroundBasementPreprocessorAverageWall, GroundBasementPreprocessorAverageFloor, GroundBasementPreprocessorUpperWall, GroundBasementPreprocessorLowerWall, or Foundation.

bool openstudio::model::Surface::isNumberofVerticesAutocalculated ( ) const
bool openstudio::model::Surface::isNumberofVerticesDefaulted ( ) const
bool openstudio::model::Surface::isPartOfEnvelope ( ) const

Returns true if the Surface is part of the building envelope.

bool openstudio::model::Surface::isSunExposureDefaulted ( ) const
bool openstudio::model::Surface::isViewFactortoGroundAutocalculated ( ) const
bool openstudio::model::Surface::isViewFactortoGroundDefaulted ( ) const
bool openstudio::model::Surface::isWindExposureDefaulted ( ) const
boost::optional<double> openstudio::model::Surface::numberofVertices ( ) const
Surface& openstudio::model::Surface::operator= ( const Surface )
default
Surface& openstudio::model::Surface::operator= ( Surface &&  )
default
std::string openstudio::model::Surface::outsideBoundaryCondition ( ) const
void openstudio::model::Surface::resetAdjacentFoundation ( )
void openstudio::model::Surface::resetAdjacentSurface ( )

Resets the adjacent Surface.

void openstudio::model::Surface::resetNumberofVertices ( )
void openstudio::model::Surface::resetSunExposure ( )
void openstudio::model::Surface::resetSurfacePropertyExposedFoundationPerimeter ( )
void openstudio::model::Surface::resetSurfacePropertyOtherSideCoefficients ( )
void openstudio::model::Surface::resetSurfacePropertyOtherSideConditionsModel ( )
void openstudio::model::Surface::resetViewFactortoGround ( )
void openstudio::model::Surface::resetWindExposure ( )
bool openstudio::model::Surface::setAdjacentFoundation ( const FoundationKiva kiva)
bool openstudio::model::Surface::setAdjacentSurface ( Surface surface)

Sets the adjacent Surface, will clear adjacent surface on other surface.

bool openstudio::model::Surface::setNumberofVertices ( boost::optional< double >  numberofVertices)
bool openstudio::model::Surface::setNumberofVertices ( double  numberofVertices)
bool openstudio::model::Surface::setOutsideBoundaryCondition ( const std::string &  outsideBoundaryCondition)
bool openstudio::model::Surface::setSpace ( const Space space)

Sets the parent Space.

bool openstudio::model::Surface::setSunExposure ( const std::string &  sunExposure)
bool openstudio::model::Surface::setSurfacePropertyOtherSideCoefficients ( const SurfacePropertyOtherSideCoefficients otherSideCoefficients)
bool openstudio::model::Surface::setSurfacePropertyOtherSideConditionsModel ( const SurfacePropertyOtherSideConditionsModel otherSideModel)
bool openstudio::model::Surface::setSurfaceType ( const std::string &  surfaceType)
bool openstudio::model::Surface::setViewFactortoGround ( boost::optional< double >  viewFactortoGround)
bool openstudio::model::Surface::setViewFactortoGround ( double  viewFactortoGround)
bool openstudio::model::Surface::setWindExposure ( const std::string &  windExposure)
boost::optional<SubSurface> openstudio::model::Surface::setWindowToWallRatio ( double  wwr)

Sets the window to wall ratio for this surface using a single banded window.

Uses applyViewAndDaylightingGlassRatios for implementation.

boost::optional<SubSurface> openstudio::model::Surface::setWindowToWallRatio ( double  wwr,
double  desiredHeightOffset,
bool  heightOffsetFromFloor 
)

Same as setWindowToWallRatio but with extra parameters desiredHeightOffset and heightOffsetFromFloor.

If heightOffsetFromFloor is true then desiredHeightOffset is the desired sill height, otherwise it is the offset from the ceiling. Uses applyViewAndDaylightingGlassRatios for implementation.

std::vector<ShadingSurfaceGroup> openstudio::model::Surface::shadingSurfaceGroups ( ) const

Returns any shading surface groups associated with this surface.

double openstudio::model::Surface::skylightToProjectedFloorRatio ( ) const

Get the skylight to projected floor ratio for this surface.

Calculated as sum(surface.skylights.netArea)/project(surface to z=0 plane).grossArea if this surface is a roof, returns 0 if this surface is not a roof.

double openstudio::model::Surface::skylightToRoofRatio ( ) const

Get the skylight to roof ratio for this surface.

Calculated as sum(surface.skylights.netArea)/surface.grossArea if this surface is a roof, returns 0 if this surface is not a roof.

std::vector<Surface> openstudio::model::Surface::splitSurfaceForSubSurfaces ( )

Splits this surface vertically surrounding any sub surfaces.

This surface must be a wall and must not have an adjacent surface. Returns any new surfaces created in this routine. Typically this is called on a surface that has doors but no windows before applying banded windows.

std::vector<SubSurface> openstudio::model::Surface::subSurfaces ( ) const

Returns all child SubSurfaces .

std::string openstudio::model::Surface::sunExposure ( ) const
boost::optional<SurfaceControlMovableInsulation> openstudio::model::Surface::surfaceControlMovableInsulation ( ) const

Returns the SurfaceControlMovableInsulation, if it exists.

boost::optional<SurfacePropertyConvectionCoefficients> openstudio::model::Surface::surfacePropertyConvectionCoefficients ( ) const

Returns the SurfacePropertyConvectionCoefficients, if it exists.

boost::optional<SurfacePropertyExposedFoundationPerimeter> openstudio::model::Surface::surfacePropertyExposedFoundationPerimeter ( ) const
boost::optional<SurfacePropertyLocalEnvironment> openstudio::model::Surface::surfacePropertyLocalEnvironment ( ) const

Returns the SurfacePropertyLocalEnvironment, if it exists.

boost::optional<SurfacePropertyOtherSideCoefficients> openstudio::model::Surface::surfacePropertyOtherSideCoefficients ( ) const

Returns the adjacent SurfaceSurfacePropertyOtherSideCoefficients, if it exists.

boost::optional<SurfacePropertyOtherSideConditionsModel> openstudio::model::Surface::surfacePropertyOtherSideConditionsModel ( ) const

Returns the adjacent SurfacePropertyOtherSideConditionsModel, if it exists.

std::string openstudio::model::Surface::surfaceType ( ) const
static std::vector<std::string> openstudio::model::Surface::validOutsideBoundaryConditionValues ( )
static
static std::vector<std::string> openstudio::model::Surface::validSunExposureValues ( )
static
static std::vector<std::string> openstudio::model::Surface::validSurfaceTypeValues ( )
static
static std::vector<std::string> openstudio::model::Surface::validWindExposureValues ( )
static
boost::optional<double> openstudio::model::Surface::viewFactortoGround ( ) const
std::string openstudio::model::Surface::windExposure ( ) const
double openstudio::model::Surface::windowToWallRatio ( ) const

Get the window to wall ratio for this surface.

Calculated as sum(surface.windows.netArea)/surface.grossArea if this surface is a wall, returns 0 if this surface is not a wall.

Friends And Related Function Documentation

using OptionalSurface = boost::optional<Surface>
related
using SurfaceVector = std::vector<Surface>
related