<html 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=utf-8"><meta name=Generator content="Microsoft Word 15 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:Helvetica;
panose-1:2 11 6 4 2 2 2 2 2 4;}
@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:Verdana;
panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
{font-family:Consolas;
panose-1:2 11 6 9 2 2 4 3 2 4;}
@font-face
{font-family:"Book Antiqua";
panose-1:2 4 6 2 5 3 5 3 3 4;}
@font-face
{font-family:"PrimaSans BT\,Verdana\,sans-serif";}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
pre
{mso-style-priority:99;
mso-style-link:"HTML Preformatted Char";
margin:0cm;
font-size:10.0pt;
font-family:"Courier New";}
span.HTMLPreformattedChar
{mso-style-name:"HTML Preformatted Char";
mso-style-priority:99;
mso-style-link:"HTML Preformatted";
font-family:Consolas;}
span.EmailStyle25
{mso-style-type:personal-compose;
font-family:"Calibri",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:72.0pt 90.0pt 72.0pt 90.0pt;}
div.WordSection1
{page:WordSection1;}
--></style></head><body lang=EN-GB link=blue vlink=purple style='word-wrap:break-word'><div class=WordSection1><p class=MsoNormal><span style='mso-fareast-language:EN-US'>Dear Clement,<o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'>Setting the right PID parameters can be tricky if you do it by hand and trial and error runs.<o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'>On the other hand it is a very straight forward optimization problem. I would suggest that you couple TRNSYS with GenOPT and use Particle Swarm Optimization.<o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'>If you have license for TRNOPT then this is pretty easy to setup just follow TRNOPT manual, if not you will have to follow the following guide:<o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><a href="https://sel.me.wisc.edu/trnsys/demos/genopt-type56.pdf">https://sel.me.wisc.edu/trnsys/demos/genopt-type56.pdf</a><o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'>This guide was prepared since you cannot optimize type56 variables through TRNOPT, but it can be used as a base to understand how to couple TRNSYS and GenOPT if TRNOPT is not available.<o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'>As far as PSO parameters are concerned you can use the ones from the publication below – they work really well with engineering problems. You can also get insights on how to formulate cost functions for the optimization process which include technical constraints. For your problem you just need an equation for the outlet air temperature oscillation which you will try to minimize.<o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><a href="https://www.sciencedirect.com/science/article/abs/pii/S0196890415005610">https://www.sciencedirect.com/science/article/abs/pii/S0196890415005610</a><o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'>Since you have gone down the TRNSYS route, I would strongly advise you to learn how to do optimizations with heuristics. Even though your current problem is an easy one, optimization through PSO which can handle up to 100 variables both discrete and continuous is an invaluable tool in anything that you might want to do in the future.<o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'>Best regards,<br><br>George</span><o:p></o:p></p><p class=MsoNormal><span lang=EN-US style='font-size:10.0pt;font-family:"PrimaSans BT\,Verdana\,sans-serif";color:black;background:white;mso-fareast-language:EL'>--<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:9.0pt;font-family:"Book Antiqua",serif;color:black;background:white;mso-fareast-language:EL'>Dr. George Kyriakarakos, Agricultural Engineer</span><span lang=EN-US style='font-size:9.0pt;font-family:"Book Antiqua",serif;color:black;mso-fareast-language:EL'><br><span style='background:white'>PhD, MSc Energy Systems & Renewable Energy Sources</span><br><span style='background:white'>Agricultural University of Athens,</span><br><span style='background:white'>Dept. of Natural Resources and Agricultural Engineering</span><br><span style='background:white'>Iera odos street, 75, Athens 11855, Greece</span><br><span style='background:white'>Tel. +30.210.5294046 (direct), Fax:+30.210.5294023</span><br><span style='background:white'>Mobile +30.6942.046895</span><br><span style='background:white'>e-mail: <a href="mailto:gk@aua.gr"><span style='color:#0563C1'>gk@aua.gr</span></a><o:p></o:p></span></span></p><p class=MsoNormal><span lang=EN-US style='font-size:9.0pt;font-family:"Book Antiqua",serif;color:black;background:white;mso-fareast-language:EL'>Skype: georgekyriak<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:9.0pt;font-family:"Book Antiqua",serif;color:black;background:white;mso-fareast-language:EL'>Linkedin:</span><span lang=EN-US style='font-size:9.0pt;font-family:"Book Antiqua",serif'> </span><span style='font-size:9.0pt;font-family:"Book Antiqua",serif'>http://www.linkedin.com/in/georgekyr</span><span lang=EN-US style='font-size:9.0pt;font-family:"Book Antiqua",serif;color:black;mso-fareast-language:EL'><o:p></o:p></span></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><o:p> </o:p></span></p><div><div style='border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=MsoNormal><b><span lang=EN-US>From:</span></b><span lang=EN-US> TRNSYS-users <trnsys-users-bounces@lists.onebuilding.org> <b>On Behalf Of </b>Clement Nevers via TRNSYS-users<br><b>Sent:</b> Tuesday, March 29, 2022 4:20 PM<br><b>To:</b> trnsys-users@lists.onebuilding.org<br><b>Cc:</b> Clement Nevers <nevers@insa-toulouse.fr><br><b>Subject:</b> [TRNSYS-users] PID controller parameters setting - Cooling coils Type508<o:p></o:p></span></p></div></div><p class=MsoNormal><o:p> </o:p></p><pre><span style='font-family:"Arial",sans-serif'>Hi everyone,<br><br><o:p></o:p></span></pre><pre><span style='font-family:"Arial",sans-serif'>I have encountered some problems when the PID controller(type23) was used for controling the outlet air temperature of cooling coil (type508).<o:p></o:p></span></pre><pre><span style='font-family:"Arial",sans-serif'><o:p> </o:p></span></pre><pre><span style='font-family:"Arial",sans-serif'>The fluid flow rate of cooling coil is conected with a outlet of flow diverter (type11). Thus, the fluid flow rate of cooling coil is determined by the control signal of the flow diverter. I build this mechanism in order to model a cooling cooling with a bypass in fluid side (3-ways valve flow controlling).<o:p></o:p></span></pre><pre><span style='font-family:"Arial",sans-serif'><o:p> </o:p></span></pre><pre><span style='font-family:"Arial",sans-serif'>Then, the PID controller is used for keeping the outlet air temperature (Controlled variable) of cooling coil at a setpoint, the control signal is basically the fluid proportion of the flow diverter. <o:p></o:p></span></pre><pre><span style='font-family:"Arial",sans-serif'><o:p> </o:p></span></pre><pre><span style='font-family:"Arial",sans-serif'>But no matter how to adjust the parameters of PID, the outlet air temperature oscillation cannot be eliminated.<o:p></o:p></span></pre><pre><span style='font-family:"Arial",sans-serif'><o:p> </o:p></span></pre><pre><span style='font-family:"Arial",sans-serif'>So, I have the following questions :<o:p></o:p></span></pre><pre><span style='font-family:"Arial",sans-serif'><o:p> </o:p></span></pre><pre><span style='font-family:"Arial",sans-serif'>How to determine the parameters of PID controller, such as Gain constant, Integral time and Derivative time, to avoid Controlled variable oscillation ? <o:p></o:p></span></pre><pre><span style='font-family:"Arial",sans-serif'><br>Is there a better way to accurately model this system? <br><br>Thanks in advance,</span><o:p></o:p></pre><p>Regards<o:p></o:p></p><div><div><p class=MsoNormal><strong><span style='font-family:"Verdana",sans-serif;color:#666666'>NEVERS Clément</span></strong><span style='font-family:"Verdana",sans-serif;color:#666666'><o:p></o:p></span></p></div><div><p class=MsoNormal><em><span style='font-size:7.5pt;font-family:"Verdana",sans-serif;color:#666666'>Research Assistant - LMDC, Toulouse</span></em><span style='font-family:"Verdana",sans-serif;color:#666666'><o:p></o:p></span></p></div><div><p class=MsoNormal><em><span style='font-family:"Verdana",sans-serif;color:#666666'> </span></em><span style='font-family:"Verdana",sans-serif;color:#666666'><o:p></o:p></span></p></div><div><p class=MsoNormal><em><span style='font-family:"Verdana",sans-serif;color:#666666'>mail </span></em><span style='font-family:"Verdana",sans-serif;color:#666666'>: <a href="mailto:nevers@etud.insa-toulouse.fr">nevers@insa-toulouse.fr</a><o:p></o:p></span></p></div><div><div><p class=MsoNormal style='margin-bottom:12.0pt'><span style='font-size:9.0pt;font-family:"Helvetica",sans-serif;color:#666666'><o:p> </o:p></span></p></div><div><p class=MsoNormal><strong><span style='font-size:9.0pt;font-family:"Verdana",sans-serif;color:#666666'>Département du Génie Civil</span></strong><span style='font-size:9.0pt;font-family:"Verdana",sans-serif;color:#666666'><o:p></o:p></span></p></div><div><p class=MsoNormal><strong><span style='font-size:9.0pt;font-family:"Verdana",sans-serif;color:#990000'>INSA</span></strong><strong><span style='font-size:9.0pt;font-family:"Verdana",sans-serif;color:#666666'> Toulouse</span></strong><span style='font-size:9.0pt;font-family:"Verdana",sans-serif;color:#666666'><o:p></o:p></span></p></div><div><p class=MsoNormal><span style='font-size:9.0pt;font-family:"Verdana",sans-serif;color:#666666'>135 avenue de Rangueil<o:p></o:p></span></p></div><div><p class=MsoNormal><span style='font-size:9.0pt;font-family:"Verdana",sans-serif;color:#666666'>31077 Toulouse Cedex 4<o:p></o:p></span></p></div><div><p class=MsoNormal><span style='font-size:7.5pt;font-family:"Verdana",sans-serif;color:#666666'>tel : +33 (0)5 61 55 95 13</span><span style='font-family:"Verdana",sans-serif;color:#666666'><o:p></o:p></span></p></div><div><p class=MsoNormal><span style='font-size:7.5pt;font-family:"Verdana",sans-serif;color:#666666'>web : <a href="http://www.insa-toulouse.fr/" target="_blank">www.insa-toulouse.fr</a></span><span style='font-family:"Verdana",sans-serif;color:#666666'><o:p></o:p></span></p></div></div></div></div></body></html>