<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="Generator" content="Microsoft Word 12 (filtered medium)">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]-->
<title>Problème initialisation variables Fortran</title>
<style>
<!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
p
{mso-style-priority:99;
mso-margin-top-alt:auto;
margin-right:0cm;
mso-margin-bottom-alt:auto;
margin-left:0cm;
font-size:12.0pt;
font-family:"Times New Roman","serif";}
span.EmailStyle18
{mso-style-type:personal-reply;
font-family:"Calibri","sans-serif";
color:#1F497D;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
{page:WordSection1;}
-->
</style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="FR" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D">Hi ,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D">This user has a problem using variable storage when creating a new type. She says that she initializes her variables in
<o:p></o:p></span></p>
<p><b><span lang="EN-US" style="font-size:10.0pt;font-family:"Courier New";
color:blue">If</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:
"Courier New"">(getIsFirstCallofSimulation())</span><span lang="EN-US"><o:p></o:p></span></p>
<p><b><span lang="EN-US" style="font-size:10.0pt;font-family:"Courier New";
color:blue">If</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:
"Courier New""> (getIsFirstTimestep())</span><span lang="EN-US"><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D">and uses the functions<o:p></o:p></span></p>
<p><b><span lang="EN-US" style="font-size:10.0pt;font-family:"Courier New";
color:blue">Call</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:
"Courier New""> SetStaticArrayValue(1,18.0)</span><span lang="EN-US"><o:p></o:p></span></p>
<p><b><span lang="EN-US" style="font-size:10.0pt;font-family:"Courier New";
color:blue">Call</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:
"Courier New""> SetOutputValue(1, 18.0)</span><span lang="EN-US">
<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D">To store and output values. But she has doubts about when to call these functions.
<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D">So have I; I think I understood it using the Ifs using the old INFO-array, but how does it work with the access functions?<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D">Is there something like getIsFirstItteration (INFO(7) = 0) ?<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Courier New"">getIsFirstTimestep
</span><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D">sounds more like “TIME = 1”.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D">Is there a storage-using example using the new access functions?<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D">Thanks,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D">Werner & the French users<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">De :</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> PERROTIN, Marian CAR [mailto:Marian.PERROTIN@carrier.utc.com]
<br>
<b>Envoyé :</b> mercredi 9 février 2011 16:44<br>
<b>À :</b> software réception<br>
<b>Objet :</b> Problème initialisation variables Fortran<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">Bonjour,</span><o:p></o:p></p>
<p><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">Je rencontre un problème en codant les fonctions FORTRAN de nouveaux composants dans Trnsys.</span>
<o:p></o:p></p>
<p><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">Je souhaiterais savoir comment</span>
<span style="font-size:10.0pt;font-family:
"Arial","sans-serif"">et surtout dans quelle fonction</span>
<span style="font-size:10.0pt;font-family:"Arial","sans-serif"">il faut initialiser les variables</span>
<span style="font-size:10.0pt;font-family:"Arial","sans-serif"">de stockage. </span>
<o:p></o:p></p>
<p><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">Sachant que je travaille avec la version 17, j’ai initialisé</span>
<span style="font-size:10.0pt;font-family:"Arial","sans-serif"">mes variables</span>
<span style="font-size:10.0pt;font-family:"Arial","sans-serif"">dans les fonctions suivantes :</span><o:p></o:p></p>
<p><b><span lang="EN-US" style="font-size:10.0pt;font-family:"Courier New";
color:blue">If</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:
"Courier New"">(getIsFirstCallofSimulation())</span><o:p></o:p></p>
<p><b><span lang="EN-US" style="font-size:10.0pt;font-family:"Courier New";
color:blue">If</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:
"Courier New""> (getIsFirstTimestep())</span><o:p></o:p></p>
<p><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial","sans-serif"">en utilisant les fonctions suivantes pour les variables de stockage et de sortie, respectivement:
</span><o:p></o:p></p>
<p><b><span lang="EN-US" style="font-size:10.0pt;font-family:"Courier New";
color:blue">Call</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:
"Courier New""> SetStaticArrayValue(1,18.0)</span><o:p></o:p></p>
<p><b><span lang="EN-US" style="font-size:10.0pt;font-family:"Courier New";
color:blue">Call</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:
"Courier New""> SetOutputValue(1, 18.0)</span><span lang="EN-US">
</span><o:p></o:p></p>
<p><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">J’obtiens</span>
<span style="font-size:10.0pt;font-family:"Arial","sans-serif"">toujours</span> <span style="font-size:10.0pt;font-family:"Arial","sans-serif"">
la valeur initiale (premier pas de temps)</span> <span style="font-size:10.0pt;
font-family:"Arial","sans-serif"">
2.06E+011 de toutes les variables, ce qui provoque une divergence</span> <span style="font-size:10.0pt;font-family:"Arial","sans-serif"">
au niveau des équations.</span><o:p></o:p></p>
<p><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">Merci d’avance</span><o:p></o:p></p>
<p><b><span lang="EN-US" style="font-family:"Calibri","sans-serif";color:#1F497D">Marian PERROTIN
</span></b><o:p></o:p></p>
<p><span lang="EN-US" style="font-family:"Calibri","sans-serif"">CARRIER-AdvanTE3C Solutions Center</span><o:p></o:p></p>
<p><i><span lang="EN-US" style="font-family:"Calibri","sans-serif"">Route de Thil 01122 Montluel Cedex-France</span></i><o:p></o:p></p>
<p><a href="mailto:marian.perrotin@carrier.utc.com"><i><span lang="EN-US" style="font-family:"Calibri","sans-serif"">marian.perrotin@carrier.utc.com</span></i></a><o:p></o:p></p>
<p><i><span lang="EN-US" style="font-family:"Calibri","sans-serif"">Tel: +33 (0) 4 72 25 22 23</span></i><o:p></o:p></p>
<p><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial","sans-serif";
color:black"><img border="0" id="_x0000_i1025" src="cid:image001.png@01CBC9ED.F61D0440" alt="ole0.bmp"></span><o:p></o:p></p>
</div>
</body>
</html>