<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
<title></title>
</head>
<body text="#000000" bgcolor="#ffffff">
David and Werner<br>
That is an interesting suggestion. If you have two equations with
the same name in your input file, TRNSYS should catch that and give
you an error saying so when you run the simulation. Its not always
easy to find where the duplicate equations are; I typically open the
*.dck itself from the Studio and then search for the name of the
offending equation, then note the name of the equation block that it
was found in.<br>
<br>
One other thing to note though: while equation names cannot be
duplicated, a variable can be used in more than one equation block.
For example, the following is perfectly okay (note that the second
equation block uses the results of the first equation block. as a
side note, NO link needs to be drawn between the two equation blocks
in the Studio!):<br>
<br>
<br>
<font face="Courier">* EQUATIONS "equation block 1"<br>
* <br>
EQUATIONS 2<br>
myEqn1 = 0.0<br>
myEqn2 = myEqn1+4<br>
*$UNIT_NAME equation block 1<br>
*$LAYER Main<br>
*$POSITION 565 779<br>
<br>
* EQUATIONS "equation block 2"<br>
* <br>
EQUATIONS 1<br>
myEqn3 = myEqn1+myEqn2<br>
*$UNIT_NAME equation block 2<br>
*$LAYER Main<br>
*$POSITION 500 700</font><br>
<br>
<br>
On 7/20/2011 10:53, keilholz, werner wrote:
<blockquote
cite="mid:1FF6CC8FFEAB7C4BBFAB3EF8AF80A879020AF050@Maude2010.cstb.local"
type="cite">
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<meta name="Generator" content="Microsoft Word 12 (filtered
medium)">
<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:11.0pt;
font-family:"Calibri","sans-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;}
span.EmailStyle17
{mso-style-type:personal;
font-family:"Calibri","sans-serif";
color:windowtext;}
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]-->
<div class="WordSection1">
<p class="MsoNormal"><span style="color: rgb(31, 73, 125);"
lang="EN-US">Thanks David for this suggestion.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color: rgb(31, 73, 125);"
lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color: rgb(31, 73, 125);"
lang="EN-US">In the meantime, you can now also use the edit
button in the equation editor and use the replace function
of the text editor.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color: rgb(31, 73, 125);"
lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color: rgb(31, 73, 125);"
lang="EN-US">Werner<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color: rgb(31, 73, 125);"
lang="EN-US"><o:p> </o:p></span></p>
<div>
<div style="border-right: medium none; border-width: 1pt
medium medium; border-style: solid none none; border-color:
rgb(181, 196, 223) -moz-use-text-color -moz-use-text-color;
padding: 3pt 0cm 0cm;">
<p class="MsoNormal"><b><span style="font-size: 10pt;
font-family:
"Tahoma","sans-serif";">De :</span></b><span
style="font-size: 10pt; font-family:
"Tahoma","sans-serif";">
<a class="moz-txt-link-abbreviated" href="mailto:trnsys-users-bounces@cae.wisc.edu">trnsys-users-bounces@cae.wisc.edu</a>
[<a class="moz-txt-link-freetext" href="mailto:trnsys-users-bounces@cae.wisc.edu">mailto:trnsys-users-bounces@cae.wisc.edu</a>]
<b>De la part de</b> CHEZE David 227480<br>
<b>Envoyé :</b> mercredi 20 juillet 2011 11:01<br>
<b>À :</b> <a class="moz-txt-link-abbreviated" href="mailto:trnsys-users@engr.wisc.edu">trnsys-users@engr.wisc.edu</a><br>
<b>Objet :</b> [TRNSYS-users] duplicate equation block
component<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><span lang="EN-US">Hi,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">I wrote an Equation
block (in TRNSYS 17.0.019) which stands for a very simple
fluid heater and I aim to duplicate this block (just
Copy/paste in the Studio) in order to have a new instance of
this object in the same project but connected to another
hydraulic loop with different behavior : when I just
copy/past in the studio, another block is nicely copied, all
equations are written in the deck files but with the same
variable’s names what can not be used as I guessed. In an
object oriented use of this “Equation block”, it would be
nice to have a feature in the studio which ensures an
automatic renaming of the declared variables. Another way is
obviously user component’s writing but not so quick and more
general while the problem was local.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">Thanks for your advice,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size: 10pt; font-family:
"Arial","sans-serif";" lang="EN-US">David
</span><span lang="EN-US"><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
</div>
<pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
TRNSYS-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:TRNSYS-users@cae.wisc.edu">TRNSYS-users@cae.wisc.edu</a>
<a class="moz-txt-link-freetext" href="https://mailman.cae.wisc.edu/listinfo/trnsys-users">https://mailman.cae.wisc.edu/listinfo/trnsys-users</a>
</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
***************************
David BRADLEY
Principal
Thermal Energy Systems Specialists, LLC
22 North Carroll Street - suite 370
Madison, WI 53703 USA
P:+1.608.274.2577
F:+1.608.278.1475
<a class="moz-txt-link-abbreviated" href="mailto:d.bradley@tess-inc.com">d.bradley@tess-inc.com</a>
<a class="moz-txt-link-freetext" href="http://www.tess-inc.com">http://www.tess-inc.com</a>
<a class="moz-txt-link-freetext" href="http://www.trnsys.com">http://www.trnsys.com</a></pre>
</body>
</html>