I am developing a model for Heat Exchangers. I wrote the energy balance equation. When I check the model, I am getting the error shown in the figure. I am not able to figure it out the remaining three equations
model HX1
replaceable package Medium1 = Modelica.Media.Air.DryAirNasa annotation (
choicesAllMatching=true);
replaceable package Medium2 =
Modelica.Media.Water.ConstantPropertyLiquidWater annotation (
choicesAllMatching=true);
Modelica.Fluid.Interfaces.FluidPort_a AirInlet
annotation (Placement(transformation(extent={{-110,48},{-90,68}})));
Modelica.Fluid.Interfaces.FluidPort_a WaterOutlet
annotation (Placement(transformation(extent={{90,-48},{110,-28}})));
Modelica.Fluid.Interfaces.FluidPort_b AirOutlet
annotation (Placement(transformation(extent={{88,50},{108,70}})));
Modelica.Fluid.Interfaces.FluidPort_b WaterInlet
annotation (Placement(transformation(extent={{-110,-56},{-90,-36}})));
equation
WaterInlet.m_flow * (WaterOutlet.h_outflow - WaterInlet.h_outflow)
= AirInlet.m_flow * ( AirInlet.h_outflow - AirOutlet.h_outflow);
WaterInlet.m_flow = - WaterOutlet.m_flow;
AirInlet.m_flow = -AirOutlet.m_flow;
AirInlet.p = AirOutlet.p;
WaterInlet.p = WaterOutlet.p;
annotation (Icon(coordinateSystem(preserveAspectRatio=false)), Diagram(
coordinateSystem(preserveAspectRatio=false)));
end HX1;
Can anyone help me with this? Are there any heat exchangers available for free?