Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
156 commits
Select commit Hold shift + click to select a range
6f22a9a
Add files via upload
ViswanathanGanesh01 Nov 9, 2024
6c51250
Add files via upload
ViswanathanGanesh01 Nov 9, 2024
a96394d
Create package.order
ViswanathanGanesh01 Nov 9, 2024
c24fb30
Add files via upload
ViswanathanGanesh01 Nov 9, 2024
81bf872
Create package.oder
ViswanathanGanesh01 Nov 9, 2024
cec0b17
Add files via upload
ViswanathanGanesh01 Nov 9, 2024
822b640
Delete Buildings/Electrical/AC/ThreePhasesBalanced/Loads/MotorDrive/T…
ViswanathanGanesh01 Nov 9, 2024
161fa25
Add files via upload
ViswanathanGanesh01 Nov 9, 2024
5131c80
Add files via upload
ViswanathanGanesh01 Nov 9, 2024
9767d2e
Add files via upload
ViswanathanGanesh01 Nov 12, 2024
0388b35
Delete Buildings/Resources/Scripts/Dymola/Electrical/AC/ThreePhasesBa…
ViswanathanGanesh01 Nov 12, 2024
0929c9d
Delete Buildings/Resources/Scripts/Dymola/Electrical/AC/ThreePhasesBa…
ViswanathanGanesh01 Nov 12, 2024
09e94d1
Add files via upload
ViswanathanGanesh01 Nov 12, 2024
0b0460c
Delete Buildings/Resources/Scripts/Dymola/Electrical/AC/ThreePhasesBa…
ViswanathanGanesh01 Nov 21, 2024
d5dee60
Add files via upload
ViswanathanGanesh01 Nov 21, 2024
1567f9c
Delete Buildings/Electrical/AC/ThreePhasesBalanced/Loads/MotorDrive d…
ViswanathanGanesh01 Nov 21, 2024
e8cdf81
Add files via upload
ViswanathanGanesh01 Nov 21, 2024
c136aa0
Add files via upload
ViswanathanGanesh01 Nov 21, 2024
8c8b757
Add files via upload
ViswanathanGanesh01 Dec 18, 2024
33a033c
Add files via upload
ViswanathanGanesh01 Dec 18, 2024
4babebf
Add files via upload
ViswanathanGanesh01 Dec 18, 2024
585220b
Add files via upload
ViswanathanGanesh01 Dec 19, 2024
24230bc
Add files via upload
ViswanathanGanesh01 Dec 19, 2024
c0a1639
Add files via upload
ViswanathanGanesh01 Dec 19, 2024
7e509eb
Add files via upload
ViswanathanGanesh01 Jan 2, 2025
3b7f25c
Add files via upload
ViswanathanGanesh01 Jan 2, 2025
6134869
Delete Buildings/Resources/Scripts/Dymola/Electrical/AC/ThreePhasesBa…
ViswanathanGanesh01 Jan 2, 2025
5e0b5d9
Add files via upload
ViswanathanGanesh01 Jan 2, 2025
3237f14
Add files via upload
ViswanathanGanesh01 Jan 2, 2025
287b98c
Add files via upload
ViswanathanGanesh01 Jan 2, 2025
daefb82
Add files via upload
ViswanathanGanesh01 Jan 2, 2025
cb07d6b
Add files via upload
ViswanathanGanesh01 Jan 2, 2025
966067e
Add files via upload
ViswanathanGanesh01 Jan 2, 2025
4336988
Add files via upload
ViswanathanGanesh01 Jan 3, 2025
257df4b
Add files via upload
ViswanathanGanesh01 Jan 3, 2025
59d6c93
Add files via upload
ViswanathanGanesh01 Jan 10, 2025
86b39ed
Add files via upload
ViswanathanGanesh01 Jan 10, 2025
0d6ed37
Add files via upload
ViswanathanGanesh01 Jan 10, 2025
cdf693f
Add files via upload
ViswanathanGanesh01 Jan 10, 2025
d924a27
Add files via upload
ViswanathanGanesh01 Jan 10, 2025
989a2aa
Add files via upload
ViswanathanGanesh01 Jan 24, 2025
8b68771
Delete Buildings/Electrical/AC/ThreePhasesBalanced/Loads/MotorDrive/I…
ViswanathanGanesh01 Jan 27, 2025
7b0657d
Update package.order
ViswanathanGanesh01 Jan 27, 2025
db57ead
Add files via upload
ViswanathanGanesh01 Jan 28, 2025
5e4ec5b
Add files via upload
ViswanathanGanesh01 Jan 28, 2025
8109e7f
Add files via upload
ViswanathanGanesh01 Jan 28, 2025
01a3828
Add files via upload
ViswanathanGanesh01 Jan 28, 2025
2b881dd
Add files via upload
ViswanathanGanesh01 Jan 28, 2025
86d242d
Add files via upload
ViswanathanGanesh01 Feb 3, 2025
71fcc56
Add files via upload
ViswanathanGanesh01 Feb 3, 2025
ec7982b
Delete Buildings/Electrical/AC/ThreePhasesBalanced/Loads/MotorDrive/I…
ViswanathanGanesh01 Feb 3, 2025
bb0c2b9
Merge branch 'lbl-srg:master' into issue2948-MotorDrive
ViswanathanGanesh01 Feb 3, 2025
5a9432d
Add files via upload
ViswanathanGanesh01 Feb 12, 2025
49be157
Delete Buildings/Electrical/AC/ThreePhasesBalanced/Loads/MotorDrive/T…
ViswanathanGanesh01 Feb 12, 2025
24e1f4f
Add files via upload
ViswanathanGanesh01 Feb 12, 2025
8ddf668
Add files via upload
ViswanathanGanesh01 Feb 12, 2025
836c661
Merge pull request #4103 from ViswanathanGanesh01/issue2948-MotorDrive
JayHuLBL Feb 18, 2025
dcdda45
added reference, openmoldeica
JayHuLBL Feb 19, 2025
649259c
removed BOM
JayHuLBL Feb 19, 2025
da1ecfc
corrected wrong using of scripts
JayHuLBL Feb 19, 2025
867e251
corrected package orders
JayHuLBL Feb 19, 2025
77f1c7f
Add files via upload
ViswanathanGanesh01 Mar 5, 2025
62a37c0
Add files via upload
ViswanathanGanesh01 Mar 5, 2025
d024b27
Merge branch 'issue2948_MotorDriver_update' into issue2948-MotorDrive
ViswanathanGanesh01 Jul 1, 2025
c8ec3a9
Merge pull request #4286 from ViswanathanGanesh01/issue2948-MotorDrive
JayHuLBL Jul 2, 2025
5428e86
updated reference results
JayHuLBL Jul 9, 2025
f09d24a
refactoring models
JayHuLBL Jul 9, 2025
8a16617
added show_t
JayHuLBL Jul 9, 2025
7f63c0b
Merge branch 'master' into issue2948_MotorDriver_update
JayHuLBL Jul 14, 2025
36f63ee
corrected expertimental setup
JayHuLBL Jul 14, 2025
4a1b1ac
improving graphics
JayHuLBL Jul 15, 2025
500f603
created based model for the motor induction models
JayHuLBL Jul 16, 2025
29b9ddd
refactoring the coupled models
JayHuLBL Jul 16, 2025
a3b2ab9
improving coupled models [ci skip]
JayHuLBL Jul 16, 2025
04c3933
Add files via upload
ViswanathanGanesh01 Jul 17, 2025
9afb450
Add files via upload
ViswanathanGanesh01 Jul 17, 2025
fdaf8ba
Merge branch 'issue2948_MotorDriver_update' into MBL---Electrical-Pac…
ViswanathanGanesh01 Jul 17, 2025
e5564c9
Add files via upload
ViswanathanGanesh01 Jul 18, 2025
01a5a2c
Merge pull request #4292 from ViswanathanGanesh01/MBL---Electrical-Pa…
JayHuLBL Jul 19, 2025
63bb26b
improved text format
JayHuLBL Jul 19, 2025
a0408b8
modified text
JayHuLBL Jul 21, 2025
6b8c157
added prefix r
JayHuLBL Aug 7, 2025
ee49408
upgraded node version
JayHuLBL Aug 8, 2025
792cd80
upgraded node version before installation
JayHuLBL Aug 8, 2025
1e20ba9
switch to the desired node version
JayHuLBL Aug 8, 2025
4b82c14
added sudo
JayHuLBL Aug 8, 2025
f0215c9
changed approach to upgrade node
JayHuLBL Aug 8, 2025
4a3a4d9
changed back node upgrade approach
JayHuLBL Aug 8, 2025
d5ce318
added sudo
JayHuLBL Aug 8, 2025
9bcd6a4
add npm installation
JayHuLBL Aug 8, 2025
04f6220
added rehash
JayHuLBL Aug 8, 2025
c6ffb69
added command end
JayHuLBL Aug 8, 2025
9c617b9
added apt update
JayHuLBL Aug 8, 2025
e41e6d6
moved the node version update to the test script
JayHuLBL Aug 8, 2025
b894897
added npm installation
JayHuLBL Aug 8, 2025
a807c30
updated node js version
JayHuLBL Aug 8, 2025
e722b46
changed yml file syntax error
JayHuLBL Aug 8, 2025
2de2099
corrected .yml error
JayHuLBL Aug 8, 2025
b810297
added specific node version
JayHuLBL Aug 8, 2025
6b06c4b
changed to the latest node version
JayHuLBL Aug 8, 2025
635463e
changed to the latest node version
JayHuLBL Aug 8, 2025
9ccbe50
Merge branch 'issue4306_addPrefixR' into issue2948_MotorDriver_update
JayHuLBL Aug 12, 2025
1dc0f47
Add files via upload
ViswanathanGanesh01 Sep 21, 2025
cd5afdc
Improved Documentation and Validation
ViswanathanGanesh01 Sep 21, 2025
1a2f4b9
Add files via upload
ViswanathanGanesh01 Sep 21, 2025
ef5f31e
Add files via upload
ViswanathanGanesh01 Sep 21, 2025
d944526
Added Validation Scripts
ViswanathanGanesh01 Sep 21, 2025
9581b2a
Merge branch 'issue2948_MotorDriver_update' into MBL---Electrical-Pac…
ViswanathanGanesh01 Sep 21, 2025
5f23d85
Removed Initial Dynamics Override
ViswanathanGanesh01 Sep 22, 2025
071aa8a
Added additional documentation
ViswanathanGanesh01 Sep 22, 2025
7428672
Added Data for Validations
ViswanathanGanesh01 Oct 1, 2025
0d2fca9
Updated Script for TableonFile
ViswanathanGanesh01 Oct 1, 2025
aa2c933
Delete Buildings/Resources/Scripts/Dymola/Electrical/AC/ThreePhasesBa…
ViswanathanGanesh01 Oct 1, 2025
bffdc46
Delete Buildings/Resources/Scripts/Dymola/Electrical/AC/ThreePhasesBa…
ViswanathanGanesh01 Oct 1, 2025
3e99304
Added Unit and quantity for parameters
ViswanathanGanesh01 Oct 1, 2025
8270920
Merge pull request #4358 from ViswanathanGanesh01/MBL---Electrical-Pa…
JayHuLBL Oct 1, 2025
46b1607
improving format [ci skip]
JayHuLBL Oct 1, 2025
c0e898f
merged master [ci skip]
JayHuLBL Oct 1, 2025
6930373
Model Clean Up
ViswanathanGanesh01 Oct 2, 2025
40d07a0
Merge branch 'issue2948_MotorDriver_update' into MBL---Electrical-Pac…
ViswanathanGanesh01 Oct 2, 2025
f079bc4
Merge pull request #4380 from ViswanathanGanesh01/MBL---Electrical-Pa…
JayHuLBL Oct 2, 2025
4f732f1
deleted not needed files, fixed html errors, fixed file check errors …
JayHuLBL Oct 2, 2025
3147153
removed BOM [ci shkip]
JayHuLBL Oct 2, 2025
674b17f
changed the stop time [ci skip]
JayHuLBL Oct 2, 2025
4c02b3c
clean up the InductionMotors package [ci skip]
JayHuLBL Oct 3, 2025
fa1c2d3
correcting formats [ci skip]
JayHuLBL Oct 3, 2025
2ba79db
Merge branch 'master' into issue2948_MotorDriver_update
JayHuLBL Oct 6, 2025
257dc79
corrected format to align wth MBL conventions [ci skip]
JayHuLBL Oct 7, 2025
e9b1177
improved documentation [ci skip]
JayHuLBL Oct 8, 2025
0c83d3c
changed controller type
JayHuLBL Oct 8, 2025
02f26c3
format documentation
ViswanathanGanesh01 Oct 8, 2025
39e5fee
Merge pull request #4392 from ViswanathanGanesh01/MBL---Electrical-Pa…
JayHuLBL Oct 8, 2025
dc7b07a
corrected typo
JayHuLBL Oct 8, 2025
8846d08
run unit test
JayHuLBL Oct 8, 2025
635be2a
deleted not used class
JayHuLBL Oct 13, 2025
7a3f457
deleted self-connections
JayHuLBL Oct 14, 2025
b27c741
propagating parameters [ci skip]
JayHuLBL Oct 15, 2025
c7c8fb2
propagated parameters
JayHuLBL Oct 15, 2025
84f0d24
proagated parameters
JayHuLBL Oct 16, 2025
c0bc20c
added default names
JayHuLBL Oct 16, 2025
5605aa8
updated controllers
JayHuLBL Oct 17, 2025
35bf629
Merge branch 'master' into issue2948_MotorDriver_update
JayHuLBL Nov 4, 2025
da5286f
added missing comment
JayHuLBL Nov 4, 2025
8992b16
Merge branch 'lbl-srg:master' into MBL---Electrical-Package-v2
ViswanathanGanesh01 Nov 7, 2025
879046c
Updated the Documentation for all examples
ViswanathanGanesh01 Nov 7, 2025
850502f
Updated Validation Data Files
ViswanathanGanesh01 Nov 7, 2025
3227bc8
Updated Scripts Files
ViswanathanGanesh01 Nov 7, 2025
9aacad7
Updated Reference Results
ViswanathanGanesh01 Nov 7, 2025
576d27b
Merge branch 'issue2948_MotorDriver_update' into MBL---Electrical-Pac…
ViswanathanGanesh01 Nov 7, 2025
d18c791
Merge branch 'master' into issue2948_MotorDriver_update
JayHuLBL Nov 11, 2025
df9d6ad
Merge pull request #4402 from ViswanathanGanesh01/MBL---Electrical-Pa…
JayHuLBL Nov 11, 2025
445ce5e
cleaned the docuementation
JayHuLBL Nov 11, 2025
e4883d7
Merge branch 'master' into issue2948_MotorDriver_update
JayHuLBL Feb 20, 2026
d88a96f
merged master
JayHuLBL Feb 20, 2026
6ebd0fc
corrected typos
JayHuLBL Feb 20, 2026
0051210
fixed broken links
JayHuLBL Feb 20, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,132 @@
within Buildings.Electrical.AC.ThreePhasesBalanced.Loads.MotorDrive.Coupled.Examples;
model Chiller "Example showing how to use the motor coupled chiller model"
extends Modelica.Icons.Example;
package MediumW = Buildings.Media.Water "Water medium";

parameter Modelica.Units.SI.Power P_nominal=2.5E3
"Nominal compressor power (at y=1)";
parameter Modelica.Units.SI.TemperatureDifference dTEva_nominal=-10
"Temperature difference evaporator outlet-inlet";
parameter Modelica.Units.SI.TemperatureDifference dTCon_nominal=10
"Temperature difference condenser outlet-inlet";
parameter Real COP_nominal=3 "Chiller COP";
parameter Modelica.Units.SI.MassFlowRate m2_flow_nominal=
-P_nominal*COP_nominal/dTEva_nominal/4200
"Nominal mass flow rate at chilled water side";
parameter Modelica.Units.SI.MassFlowRate m1_flow_nominal=
m2_flow_nominal*(COP_nominal+1)/COP_nominal
"Nominal mass flow rate at condenser water wide";

Buildings.Fluid.Sources.MassFlowSource_T sou1(
redeclare package Medium = Buildings.Media.Water,
use_T_in=true,
m_flow=m1_flow_nominal,
T=298.15,
nPorts=1) "Water source 1"
annotation (Placement(transformation(extent={{-60,20},{-40,40}})));
Buildings.Fluid.Sources.MassFlowSource_T sou2(
redeclare package Medium = Buildings.Media.Water,
use_T_in=true,
m_flow=m2_flow_nominal,
T=298.15,
nPorts=1) "Water source 2"
annotation (Placement(transformation(extent={{48,-40},{28,-20}})));
Buildings.Electrical.AC.ThreePhasesBalanced.Sources.Grid Sou(f=50, V=400)
"Voltage source"
annotation (Placement(transformation(extent={{-10,22},{10,42}})));
Buildings.Fluid.Sensors.TemperatureTwoPort senTem(
redeclare package Medium =Buildings.Media.Water,
m_flow_nominal=m2_flow_nominal,
T_start(displayUnit="K") = 280.15)
"Temperature sensor"
annotation (Placement(transformation(extent={{-20,-40},{-40,-20}})));
Modelica.Blocks.Sources.Step TSet(
height=-2,
offset=273.15 + 7,
startTime=300) "Evaporator side leaving water temperature set point"
annotation (Placement(transformation(extent={{-90,60},{-70,80}})));
Buildings.Fluid.Sources.Boundary_pT sin2(
redeclare package Medium = Buildings.Media.Water,
nPorts=1)
"Water sink 2"
annotation (Placement(transformation(extent={{-80,-40},{-60,-20}})));
Buildings.Fluid.Sources.Boundary_pT sin1(
redeclare package Medium = Buildings.Media.Water, nPorts=1)
"Water sink 1"
annotation (Placement(transformation(extent={{50,0},{30,20}})));

Buildings.Electrical.AC.ThreePhasesBalanced.Loads.MotorDrive.Coupled.Chiller chi(
redeclare package Medium1 = Buildings.Media.Water,
redeclare package Medium2 = Buildings.Media.Water,
P_nominal=P_nominal,
Nrpm_nominal=1500,
dp1_nominal=1000,
dp2_nominal=1000,
etaCarnot_nominal=0.5,
loaIne=1,
redeclare Buildings.Electrical.AC.ThreePhasesBalanced.Loads.MotorDrive.InductionMotors.Data.Generic per,
k=0.1,
Ti=5)
"Chiller with motor interface"
annotation (Placement(transformation(extent={{-10,-20},{10,0}})));
Modelica.Blocks.Sources.Ramp TCon_in(
height=10,
duration=60,
offset=273.15 + 20,
startTime=60)
"Condenser inlet temperature"
annotation (Placement(transformation(extent={{-90,24},{-70,44}})));
Modelica.Blocks.Sources.Ramp TEva_in(
height=10,
duration=60,
startTime=900,
offset=273.15 + 15)
"Evaporator inlet temperature"
annotation (Placement(transformation(extent={{80,-36},{60,-16}})));
equation
connect(Sou.terminal, chi.terminal)
annotation (Line(points={{0,22},{0,0}}, color={0,120,120}));
connect(TCon_in.y, sou1.T_in)
annotation (Line(points={{-69,34},{-62,34}}, color={0,0,127}));
connect(chi.port_a1, sou1.ports[1]) annotation (Line(points={{-10,-4},{-30,-4},
{-30,30},{-40,30}}, color={0,127,255}));
connect(senTem.port_a, chi.port_b2) annotation (Line(points={{-20,-30},{-14,
-30},{-14,-16},{-10,-16}}, color={0,127,255}));
connect(senTem.port_b, sin2.ports[1])
annotation (Line(points={{-40,-30},{-60,-30}}, color={0,127,255}));
connect(chi.port_a2, sou2.ports[1]) annotation (Line(points={{10,-16},{20,-16},
{20,-30},{28,-30}}, color={0,127,255}));
connect(chi.port_b1, sin1.ports[1]) annotation (Line(points={{10,-4},{20,-4},
{20,10},{30,10}}, color={0,127,255}));
connect(TEva_in.y, sou2.T_in)
annotation (Line(points={{59,-26},{50,-26}}, color={0,0,127}));
connect(TSet.y, chi.TSet) annotation (Line(points={{-69,70},{-20,70},{-20,-1},
{-12,-1}}, color={0,0,127}));
connect(senTem.T, chi.TMea)
annotation (Line(points={{-30,-19},{-30,-7},{-12,-7}}, color={0,0,127}));
annotation (experiment(Tolerance=1e-6,StartTime=0,StopTime=600),
__Dymola_Commands(file="modelica://Buildings/Resources/Scripts/Dymola/Electrical/AC/ThreePhasesBalanced/Loads/MotorDrive/Coupled/Examples/Chiller.mos"
"Simulate and plot"),
Documentation(info="<html>
<p>
This example sinmulates a motor coupled chiller.
</p>
<p>
To ensure that the chiller energy consumption is in accordance with the manufacture
records, we can compare <code>Sou.P.apparent</code> (energy consumption from
the grid) and <code>chi.P</code> (energy consumption according to
manufacture records).
</p>
</html>", revisions="<html>
<ul>
<li>
May 07, 2024, by Viswanathan Ganesh and Zhanwei He:<br/>
Debug and updated the model
</li>
<li>
October 15, 2021, by Mingzhe Liu:<br/>
First implementation.
</li>
</ul>
</html>"));
end Chiller;
Original file line number Diff line number Diff line change
@@ -0,0 +1,136 @@
within Buildings.Electrical.AC.ThreePhasesBalanced.Loads.MotorDrive.Coupled.Examples;
model HeatPump "Example showing how to use the motor coupled heat pump model"
extends Modelica.Icons.Example;
package MediumW = Buildings.Media.Water "Water medium";

parameter Modelica.Units.SI.Power P_nominal=2.5E3
"Nominal compressor power (at y=1)";
parameter Modelica.Units.SI.TemperatureDifference dTEva_nominal=-10
"Temperature difference evaporator outlet-inlet";
parameter Modelica.Units.SI.TemperatureDifference dTCon_nominal=10
"Temperature difference condenser outlet-inlet";
parameter Real COP_nominal=3 "Chiller COP";
parameter Modelica.Units.SI.MassFlowRate m2_flow_nominal=
-P_nominal*COP_nominal/dTEva_nominal/4200
"Nominal mass flow rate at chilled water side";
parameter Modelica.Units.SI.MassFlowRate m1_flow_nominal=
m2_flow_nominal*(COP_nominal+1)/COP_nominal
"Nominal mass flow rate at condenser water wide";

Buildings.Fluid.Sources.MassFlowSource_T sou1(
redeclare package Medium = MediumW,
use_T_in=true,
m_flow=m1_flow_nominal,
T=298.15,
nPorts=1) "Water source 1"
annotation (Placement(transformation(extent={{-60,20},{-40,40}})));
Buildings.Fluid.Sources.MassFlowSource_T sou2(
redeclare package Medium = MediumW,
use_T_in=true,
m_flow=m2_flow_nominal,
T=291.15,
nPorts=1) "Water source 2"
annotation (Placement(transformation(extent={{60,-30},{40,-10}})));
Buildings.Electrical.AC.ThreePhasesBalanced.Sources.Grid Sou(f=50, V=400)
"Voltage source"
annotation (Placement(transformation(extent={{-10,40},{10,60}})));
Buildings.Fluid.Sensors.TemperatureTwoPort senTem(
redeclare package Medium = MediumW,
m_flow_nominal=m2_flow_nominal,
T_start=303.15)
"Temperature sensor"
annotation (Placement(transformation(extent={{40,20},{60,40}})));
Modelica.Blocks.Sources.Step TSet(
height=10,
offset=273.15 + 30,
startTime=200)
"Condenser side leaving water temperature set point"
annotation (Placement(transformation(extent={{-60,60},{-40,80}})));
Buildings.Electrical.AC.ThreePhasesBalanced.Loads.MotorDrive.Coupled.HeatPump hea(
redeclare package Medium1 = MediumW,
redeclare package Medium2 = MediumW,
dTEva_nominal=dTEva_nominal,
dTCon_nominal=dTCon_nominal,
P_nominal=P_nominal,
Nrpm_nominal=1500,
etaCarnot_nominal=0.5,
dp1_nominal=1000,
dp2_nominal=1000,
redeclare Buildings.Electrical.AC.ThreePhasesBalanced.Loads.MotorDrive.InductionMotors.Data.Generic per,
loaIne=1,
k=0.1,
Ti=10) "Heat pump"
annotation (Placement(transformation(extent={{-10,-10},{10,10}})));
Buildings.Fluid.Sources.Boundary_pT sin2(
redeclare package Medium = MediumW,
nPorts=1)
"Water sink 2"
annotation (Placement(transformation(extent={{-60,-30},{-40,-10}})));
Buildings.Fluid.Sources.Boundary_pT sin1(
redeclare package Medium = MediumW,
nPorts=1)
"Water sink 1"
annotation (Placement(transformation(extent={{90,20},{70,40}})));

Modelica.Blocks.Sources.Ramp TCon_in(
height=10,
duration=60,
offset=273.15 + 20,
startTime=60)
"Condenser inlet temperature"
annotation (Placement(transformation(extent={{-94,24},{-74,44}})));
Modelica.Blocks.Sources.Ramp TEva_in(
height=10,
duration=60,
startTime=900,
offset=273.15 + 15)
"Evaporator inlet temperature"
annotation (Placement(transformation(extent={{94,-26},{74,-6}})));

equation
connect(hea.port_a2, sou2.ports[1]) annotation (Line(points={{10,-6},{10,-6},{
34,-6},{34,-20},{40,-20}}, color={0,127,255}));
connect(sou1.ports[1], hea.port_a1) annotation (Line(points={{-40,30},{-30,30},
{-30,6},{-10,6}}, color={0,127,255}));
connect(senTem.port_a, hea.port_b1) annotation (Line(points={{40,30},{20,30},{
20,6},{10,6}}, color={0,127,255}));
connect(Sou.terminal, hea.terminal) annotation (Line(points={{0,40},{0,10}},
color={0,120,120}));
connect(TSet.y, hea.TSet) annotation (Line(points={{-39,70},{-24,70},{-24,9},{
-12,9}}, color={0,0,127}));
connect(senTem.T, hea.TMea) annotation (Line(points={{50,41},{50,96},{-18,96},
{-18,3},{-12,3}}, color={0,0,127}));
connect(hea.port_b2, sin2.ports[1]) annotation (Line(points={{-10,-6},{-30,-6},
{-30,-20},{-40,-20}}, color={0,127,255}));
connect(senTem.port_b, sin1.ports[1]) annotation (Line(points={{60,30},{70,30}},
color={0,127,255}));
connect(TCon_in.y, sou1.T_in)
annotation (Line(points={{-73,34},{-62,34}}, color={0,0,127}));
connect(TEva_in.y, sou2.T_in)
annotation (Line(points={{73,-16},{62,-16}}, color={0,0,127}));

annotation (experiment(Tolerance=1e-6,StartTime=0,StopTime=350),
__Dymola_Commands(file="modelica://Buildings/Resources/Scripts/Dymola/Electrical/AC/ThreePhasesBalanced/Loads/MotorDrive/Coupled/Examples/HeatPump.mos"
"Simulate and plot"),
Documentation(info="<html>
<p>
This example sinmulates a motor coupled heat pump.
</p>
<p>
To ensure that the heat pump energy consumption is in accordance with the manufacture
records, we can compare <code>Sou.P.apparent</code> (energy consumption from the
grid) and <code>hea.P</code> (energy consumption according to manufacture records).
</p>
</html>", revisions="<html>
<ul>
<li>
May 07, 2024, by Viswanathan Ganesh and Zhanwei He:<br/>
Debug and updated the model
</li>
<li>
October 15, 2021, by Mingzhe Liu:<br/>
First implementation.
</li>
</ul>
</html>"));
end HeatPump;
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
within Buildings.Electrical.AC.ThreePhasesBalanced.Loads.MotorDrive.Coupled.Examples;
model Pump "Example showing how to use the motor coupled pump model"
extends Modelica.Icons.Example;
package MediumW = Buildings.Media.Water "Water medium";
parameter Modelica.Units.SI.MassFlowRate m_flow_nominal = 1
"Nominal mass flow rate";
parameter Modelica.Units.SI.Pressure dp_nominal=500
"nominal pressure drop";

Buildings.Fluid.Sources.Boundary_pT sou(
redeclare package Medium = MediumW,
nPorts=2)
"Boundary"
annotation (Placement(transformation(extent={{-10,-10},{10,10}}, rotation=0,
origin={-90,20})));
Buildings.Electrical.AC.ThreePhasesBalanced.Loads.MotorDrive.Coupled.Pump pum(
addPowerToMedium=true,
loaIne=1,
Nrpm_nominal=1500,
redeclare Buildings.Electrical.AC.ThreePhasesBalanced.Loads.MotorDrive.InductionMotors.Data.Generic motPer,
r=2,
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
redeclare package Medium = MediumW,
redeclare Buildings.Fluid.Movers.Data.Pumps.Wilo.VeroLine50slash150dash4slash2 per,
k=0.05,
Ti=5) "Pump"
annotation (Placement(transformation(extent={{0,10},{20,30}})));

Buildings.Electrical.AC.ThreePhasesBalanced.Sources.Grid gri(f=50, V=400)
"Voltage source"
annotation (Placement(transformation(extent={{0,60},{20,80}})));
Buildings.Fluid.Sensors.MassFlowRate senMasFlo(
redeclare package Medium = MediumW)
"Flow rate sensor"
annotation (Placement(transformation(extent={{0,-50},{-20,-30}})));
Buildings.Fluid.FixedResistances.PressureDrop dp1(
redeclare package Medium = MediumW,
m_flow_nominal=m_flow_nominal,
dp_nominal=1/2*dp_nominal) "Pressure loss"
annotation (Placement(transformation(extent={{-40,10},{-20,30}})));
Buildings.Fluid.FixedResistances.PressureDrop dp2(
redeclare package Medium = MediumW,
m_flow_nominal=m_flow_nominal,
dp_nominal=1/2*dp_nominal) "Pressure loss"
annotation (Placement(transformation(extent={{40,10},{60,30}})));
Modelica.Blocks.Sources.Step step(
height=10,
offset=0,
startTime=100)
"Flow rate set point"
annotation (Placement(transformation(extent={{-80,60},{-60,80}})));

equation
connect(gri.terminal, pum.terminal) annotation (Line(points={{10,60},{10,30}},
color={0,120,120}));
connect(step.y, pum.m_flow_set) annotation (Line(points={{-59,70},{-10,70},{
-10,28},{-2,28}}, color={0,0,127}));
connect(dp1.port_b, pum.port_a) annotation (Line(points={{-20,20},{0,20}},
color={0,127,255}));
connect(dp1.port_a, sou.ports[1])
annotation (Line(points={{-40,20},{-80,20},{-80,19}}, color={0,127,255}));
connect(pum.port_b, dp2.port_a) annotation (Line(points={{20,20},{40,20}},
color={0,127,255}));
connect(dp2.port_b, senMasFlo.port_a) annotation (Line(points={{60,20},{64,20},
{64,-40},{0,-40}}, color={0,127,255}));
connect(senMasFlo.port_b, sou.ports[2]) annotation (Line(points={{-20,-40},{
-50,-40},{-50,21},{-80,21}}, color={0,127,255}));
connect(senMasFlo.m_flow,pum.m_flow) annotation (Line(points={{-10,-29},{-10,
24},{-2,24}}, color={0,0,127}));

annotation (experiment(Tolerance=1e-6,StartTime=0,StopTime=200),
__Dymola_Commands(file="modelica://Buildings/Resources/Scripts/Dymola/Electrical/AC/ThreePhasesBalanced/Loads/MotorDrive/Coupled/Examples/Pump.mos"
"Simulate and plot"),
Documentation(info="<html>
<p>
This example simulates a motor coupled pump.
</p>
<ul>
<li>
The parameter <code>pum.riseTime</code> in the dynamics tab, helps to set the
response of the fluid by regulating the motor speed to meet the prescribed mass flow.
To get the desired equipment response along with riseTime the gains of the controller
also needs to be tuned.
</li>
<li>
To ensure that the pump energy consumption is in accordance with the manufacture
records, we can compare <code>gri.P.real</code> (energy consumption from the grid)
and <code>pum.P</code> (energy consumption according to manufacture records).
</li>
</ul>
</html>", revisions="<html>
<ul>
<li>
May 07, 2024, by Viswanathan Ganesh and Zhanwei He:<br/>
Debug and updated the model
</li>
<li>
October 15, 2021, by Mingzhe Liu:<br/>
First implementation.
</li>
</ul>
</html>"));
end Pump;
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
within Buildings.Electrical.AC.ThreePhasesBalanced.Loads.MotorDrive.Coupled;
package Examples "Collection of models that illustrate model use and test models"
extends Modelica.Icons.ExamplesPackage;

annotation (Documentation(info="<html>
<p>
This package contains examples for the use of models that can be found in
<a href=\"modelica://Buildings.Electrical.AC.ThreePhasesBalanced.Loads.MotorDrive.Coupled\">
Buildings.Electrical.AC.ThreePhasesBalanced.Loads.MotorDrive.Coupled</a>.
</p>
</html>"));
end Examples;
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Chiller
HeatPump
Pump
Loading