Question-and-Answer Resource for the Building Energy Modeling Community
Get started with the Help page
Ask Your Question

Revision history [back]

Let me try to answer with an example in Ruby. I'm pretty sure you can convert to Python syntax.

air_loop = OpenStudio::Model::addSystemType7(m).to_AirLoopHVAC.get heating_coil = air_loop.supplyComponents(OpenStudio::Model::CoilHeatingWater::iddObjectType).first.to_CoilHeatingWater.get hot_water_plant = heating_coil.plantLoop.get boiler = hot_water_plant.supplyComponents(OpenStudio::Model::BoilerHotWater::iddObjectType).first.to_BoilerHotWater.get puts boiler.name

Every HVACComponent in OpenStudio, including water coils have the methods plantLoop and airLoopHVAC that return the specified system.

Let me try to answer with an example in Ruby. I'm pretty sure you can convert to Python syntax.

air_loop = OpenStudio::Model::addSystemType7(m).to_AirLoopHVAC.get heating_coil = air_loop.supplyComponents(OpenStudio::Model::CoilHeatingWater::iddObjectType).first.to_CoilHeatingWater.get hot_water_plant = heating_coil.plantLoop.get boiler = hot_water_plant.supplyComponents(OpenStudio::Model::BoilerHotWater::iddObjectType).first.to_BoilerHotWater.get puts boiler.name

Every HVACComponent in OpenStudio, including water coils have the methods plantLoop and airLoopHVAC that return the specified system.

Let me try to answer with an example in Ruby. I'm pretty sure you can convert to Python syntax.

   air_loop = OpenStudio::Model::addSystemType7(m).to_AirLoopHVAC.get
  heating_coil = air_loop.supplyComponents(OpenStudio::Model::CoilHeatingWater::iddObjectType).first.to_CoilHeatingWater.get
  hot_water_plant = heating_coil.plantLoop.get
  boiler = hot_water_plant.supplyComponents(OpenStudio::Model::BoilerHotWater::iddObjectType).first.to_BoilerHotWater.get
  puts boiler.name

Every HVACComponent in OpenStudio, including water coils have the methods plantLoop and airLoopHVAC that return the specified system.