// Script to generate plot for documentation of
// function HeatTransfer.HeatExchanger.kc_flatTube
// of FluidDissipation Library
//
// Generated by Sven Rutkowski
// 05-01-2010
// last change: 06-01-2010
// XRG Simulation GmbH

currentDirectory = Modelica.Utilities.System.getWorkDirectory();
cd(Modelica.Utilities.System.getEnvironmentVariable("temp"));

translateModel("ModelicaTest.Fluid.Dissipation.Verifications.HeatTransfer.HeatExchanger.kc_flatTube");

Advanced.StoreProtectedVariables:=true;

simulateModel("ModelicaTest.Fluid.Dissipation.Verifications.HeatTransfer.HeatExchanger.kc_flatTube",startTime=0, stopTime=1, numberOfIntervals=50000, method="dassl", tolerance=1e-005, resultFile="kc_flatTube");

switchToSimulationMode();

removePlots();
createPlot(id = 1,
  position = {(-2), (-21), 708, 403},
 x = "Re",
 y = {
	"Nu[1]"
},
 heading = "Flat tube and louver fin: Heat transfer",
 range = {1e2, 1e4, 1e2, 1e0},
 autoscale = false,
 autoerase = true,
 autoreplot = true,
 description = false,
 grid = true,
 color = true,
 online = false,
 logX = true,
 logY = true,
 filename = "kc_flatTube.mat",
 legends = {
	"Pr= 0.72 (Air)"
},
 leftTitle = "Nusselt number [-]",
 bottomTitle = "Reynolds number [-]");

createPlot(id = 2,
  position = {711, (-21), 708, 403},
 x = "Re",
 y = {
	"Nu[2]"
},
 heading = "Flat tube and rectangular offset strip fin: Heat transfer",
 range = {1e2, 1e4, 1e2, 1e0},
 autoscale = false,
 autoerase = true,
 autoreplot = true,
 description = false,
 grid = true,
 color = true,
 online = false,
 logX = true,
 logY = true,
 filename = "kc_flatTube.mat",
 legends = {
	"Pr= 0.72 (Air)"
},
 leftTitle = "Nusselt number [-]",
 bottomTitle = "Reynolds number [-]");


createPlot(id = 3,
  position = {353, 190, 708, 403},
  x = "Re",
 y = {
	"Nu[1]",
	"Nu[2]"
},
 heading = "Flat Tube Heat Exchanger: Heat transfer (Air)",
range = {1e2, 1e4, 1e2, 1e0},
 autoscale = false,
 autoerase = true,
 autoreplot = true,
 description = false,
 grid = true,
 color = true,
 online = false,
 logX = true,
 logY = true,
 filename = "kc_flatTube.mat",
 legends = {
	"Louver fin",
	"Rectangular offset strip fin"
},
 leftTitle = "Nusselt number [-]",
 bottomTitle = "Reynolds number [-]");

Modelica.Utilities.System.setWorkDirectory(currentDirectory);
