// Script to generate plot for documentation of
// function HeatTransfer.Channel.kc_evenGapOverall_KC
// of FluidDissipation Library
//
// Generated by Thorben Vahlenkamp
// 10-10-2008
// last change: 19-03-2009
// XRG Simulation GmbH

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

translateModel("ModelicaTest.Fluid.Dissipation.Verifications.HeatTransfer.Channel.kc_evenGapOverall_KC");

Advanced.StoreProtectedVariables:=true;

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

switchToSimulationMode();

removePlots();
createPlot(id = 1,
 position = {(-2), (-21), 708, 403},
 x = "input_Nu.y",
 y = {
    "Re_1[1]",
    "Re_1[2]",
    "Re_1[3]"},
 heading = "Even gap (Target= 1,inverted): Heat transfer for overall regime",
range = {1e1, 1e4, 1e6, 1e1},
 autoscale = false,
 autoerase = true,
 autoreplot = true,
 description = false,
 grid = true,
 color = true,
 online = false,
 filename = "kc_evenGapOverall_KC.mat",
 logX = true,
 logY = true,
 legends = {
	"Prandtl number= 0.72 (Air)",
	"Pr= 7 (Water)",
	"Pr= 1000 (Antifreeze)"},
 leftTitle = "Reynolds number [-]",
bottomTitle = "Nusselt number [-]");

createPlot(id = 2,
 position = {(-2), 400, 708, 403},
x = "input_Nu.y",
 y = {
    "Re_2[1]",
    "Re_2[2]",
    "Re_2[3]"},
 heading = "Even gap (Target= 2,inverted): Heat transfer for overall regime",
 range = {1e1, 1e4, 1e6, 1e1},
 autoscale = false,
 autoerase = true,
 autoreplot = true,
 description = false,
 grid = true,
 color = true,
 online = false,
 filename = "kc_evenGapOverall_KC.mat",
 logX = true,
 logY = true,
 legends = {
	"Prandtl number= 0.72 (Air)",
	"Pr= 7 (Water)",
	"Pr= 1000 (Antifreeze)"},
 leftTitle = "Reynolds number [-]",
bottomTitle = "Nusselt number [-]");

createPlot(id = 3,
 position = {708, (-21), 708, 403},
x = "input_Nu.y",
 y = {
    "Re_3[1]",
    "Re_3[2]",
    "Re_3[3]"},
 heading = "Even gap (Target= 3,inverted): Heat transfer for overall regime",
 range = {1e1, 1e4, 1e6, 1e1},
 autoscale = false,
 autoerase = true,
 autoreplot = true,
 description = false,
 grid = true,
 color = true,
 online = false,
 filename = "kc_evenGapOverall_KC.mat",
 logX = true,
 logY = true,
legends = {
	"Prandtl number= 0.72 (Air)",
	"Pr= 7 (Water)",
	"Pr= 1000 (Antifreeze)"},
 leftTitle = "Reynolds number [-]",
bottomTitle = "Nusselt number [-]");

 createPlot(id = 4,
 position = {708, 400, 708, 403},
 x = "input_Nu.y",
 y = {
    "Re_4[1]",
    "Re_4[2]",
    "Re_4[3]"},
 heading = "Even gap (Target= 4,inverted): Heat transfer for overall regime",
 range = {1e1, 1e4, 1e6, 1e1},
 autoscale = false,
 autoerase = true,
 autoreplot = true,
 description = false,
 grid = true,
 color = true,
 online = false,
 filename = "kc_evenGapOverall_KC.mat",
 logX = true,
 logY = true,
 legends = {
	"Prandtl number= 0.72 (Air)",
	"Pr= 7 (Water)",
	"Pr= 1000 (Antifreeze)"},
 leftTitle = "Reynolds number [-]",
bottomTitle = "Nusselt number [-]");

Modelica.Utilities.System.setWorkDirectory(currentDirectory);
