Buildings.Controls.OBC.CDL.Routing.Validation

Collection of models that validate the routing blocks of the CDL

Information

This package contains models that validate the blocks in Buildings.Controls.OBC.CDL.Routing.

The examples plot various outputs, which have been verified against analytical solutions. These model outputs are stored as reference data to allow continuous validation whenever models in the library change.

Package Content

Name Description
Buildings.Controls.OBC.CDL.Routing.Validation.BooleanReplicator BooleanReplicator Validation model for the BooleanReplicator block
Buildings.Controls.OBC.CDL.Routing.Validation.IntegerReplicator IntegerReplicator Validation model for the IntegerReplicator block
Buildings.Controls.OBC.CDL.Routing.Validation.RealExtractSignal RealExtractSignal Validation model for the extract signal block
Buildings.Controls.OBC.CDL.Routing.Validation.RealExtractor RealExtractor Validation model for the extractor block
Buildings.Controls.OBC.CDL.Routing.Validation.RealReplicator RealReplicator Validation model for the RealReplicator block

Buildings.Controls.OBC.CDL.Routing.Validation.BooleanReplicator Buildings.Controls.OBC.CDL.Routing.Validation.BooleanReplicator

Validation model for the BooleanReplicator block

Buildings.Controls.OBC.CDL.Routing.Validation.BooleanReplicator

Information

Validation test for the block Buildings.Controls.OBC.CDL.Routing.BooleanReplicator.

Modelica definition

model BooleanReplicator "Validation model for the BooleanReplicator block" Buildings.Controls.OBC.CDL.Routing.BooleanReplicator booRep( nout=3) "Block that outputs the array replicating input value"; Buildings.Controls.OBC.CDL.Logical.Sources.Pulse booPul( period=0.2) "Block that outputs boolean pulse"; equation connect(booPul.y, booRep.u); end BooleanReplicator;

Buildings.Controls.OBC.CDL.Routing.Validation.IntegerReplicator Buildings.Controls.OBC.CDL.Routing.Validation.IntegerReplicator

Validation model for the IntegerReplicator block

Buildings.Controls.OBC.CDL.Routing.Validation.IntegerReplicator

Information

Validation test for the block Buildings.Controls.OBC.CDL.Routing.IntegerReplicator.

Modelica definition

model IntegerReplicator "Validation model for the IntegerReplicator block" Buildings.Controls.OBC.CDL.Routing.IntegerReplicator intRep( nout=3) "Block that outputs the array replicating input value"; Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp ram( height=5, duration=1, offset=-2) "Block that outputs ramp signal"; Buildings.Controls.OBC.CDL.Conversions.RealToInteger reaToInt "Convert Real input to Integer output"; equation connect(ram.y, reaToInt.u); connect(reaToInt.y, intRep.u); end IntegerReplicator;

Buildings.Controls.OBC.CDL.Routing.Validation.RealExtractSignal Buildings.Controls.OBC.CDL.Routing.Validation.RealExtractSignal

Validation model for the extract signal block

Buildings.Controls.OBC.CDL.Routing.Validation.RealExtractSignal

Information

Validation test for the block Buildings.Controls.OBC.CDL.Routing.RealExtractSignal.

Modelica definition

model RealExtractSignal "Validation model for the extract signal block" Buildings.Controls.OBC.CDL.Routing.RealExtractSignal extSig( nin=5, nout=3, extract={1,2,5}) "Block that extracts signals from an input signal vector"; Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp ram( height=5, duration=1, offset=-2) "Block that outputs ramp signal"; Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp ram1( duration=1, height=4, offset=-1) "Block that outputs ramp signal"; Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp ram2( duration=1, height=3, offset=-2) "Block that outputs ramp signal"; Buildings.Controls.OBC.CDL.Continuous.Sources.Pulse pul( amplitude=0.5, period=0.2) "Generate pulse signal of type Real"; Buildings.Controls.OBC.CDL.Continuous.Sources.Pulse pul1( period=0.2, amplitude=1.5, offset=-0.2) "Generate pulse signal of type Real"; equation connect(ram.y, extSig.u[1]); connect(pul.y, extSig.u[2]); connect(pul1.y, extSig.u[3]); connect(ram1.y, extSig.u[4]); connect(ram2.y, extSig.u[5]); end RealExtractSignal;

Buildings.Controls.OBC.CDL.Routing.Validation.RealExtractor Buildings.Controls.OBC.CDL.Routing.Validation.RealExtractor

Validation model for the extractor block

Buildings.Controls.OBC.CDL.Routing.Validation.RealExtractor

Information

Validation test for the block Buildings.Controls.OBC.CDL.Routing.RealExtractor.

Modelica definition

model RealExtractor "Validation model for the extractor block" Buildings.Controls.OBC.CDL.Routing.RealExtractor extIndSig( nin=5) "Block that extracts signal from an input signal vector"; Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp ram( height=5, duration=1, offset=-2) "Block that outputs ramp signal"; Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp ram1( duration=1, height=4, offset=-1) "Block that outputs ramp signal"; Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp ram2( duration=1, height=3, offset=-2) "Block that outputs ramp signal"; Buildings.Controls.OBC.CDL.Continuous.Sources.Pulse pul( amplitude=0.5, period=0.2) "Generate pulse signal of type Real"; Buildings.Controls.OBC.CDL.Continuous.Sources.Pulse pul1( period=0.2, amplitude=1.5, offset=-0.2) "Generate pulse signal of type Real"; Buildings.Controls.OBC.CDL.Integers.Sources.Constant conInt(k=2) "Index to extract input signal"; Buildings.Controls.OBC.CDL.Routing.RealExtractor extIndSig1(nin=5) "Block that extracts signal from an input signal vector"; Buildings.Controls.OBC.CDL.Integers.Sources.Constant conInt1(k=6) "Index to extract input signal"; equation connect(ram.y, extIndSig.u[1]); connect(pul.y, extIndSig.u[2]); connect(pul1.y, extIndSig.u[3]); connect(ram1.y, extIndSig.u[4]); connect(ram2.y, extIndSig.u[5]); connect(conInt.y, extIndSig.index); connect(conInt1.y, extIndSig1.index); connect(ram.y, extIndSig1.u[1]); connect(pul.y, extIndSig1.u[2]); connect(pul1.y, extIndSig1.u[3]); connect(ram1.y, extIndSig1.u[4]); connect(ram2.y, extIndSig1.u[5]); end RealExtractor;

Buildings.Controls.OBC.CDL.Routing.Validation.RealReplicator Buildings.Controls.OBC.CDL.Routing.Validation.RealReplicator

Validation model for the RealReplicator block

Buildings.Controls.OBC.CDL.Routing.Validation.RealReplicator

Information

Validation test for the block Buildings.Controls.OBC.CDL.Routing.RealReplicator.

Modelica definition

model RealReplicator "Validation model for the RealReplicator block" Buildings.Controls.OBC.CDL.Routing.RealReplicator reaRep( nout=3) "Block that outputs the array replicating input value"; Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp ram( height=5, duration=1, offset=-2) "Block that outputs ramp signal"; equation connect(ram.y, reaRep.u); end RealReplicator;