[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [TRNSYS-users] Python



Dear Tim

 

The connection with python works now, thanks!

But another question came up:

 

I am testing an algorithm which takes the weather forecast of the following 48 hours in to account. What do you think is the best way to give the controller the required forecast?

 

I thought of a time delay using type 150 to shift the whole simulation 48h backwards and then the undelayed weather output of type 15 would represent the forecast.

 

But type 150 allows only a shift of 25 time steps and maybe there is a more elegant solution than adding type 150 in series or to change the default range of the type’s time steps (which I am not familiar with).

 

Thanks for your help.

 

Best regards,

 

Frederick




2017-10-26 21:13 GMT+02:00 mcdowell--- via TRNSYS-users <trnsys-users@lists.onebuilding.org>:

Frederick Gonon -

The two calling Python types are fundamentally different as Type163 reads and writes files between TRNSYS and Python and Type169 communicates directly between the programs.  There are example scripts included in the MathematicalReference volume of the TRNSYS 18 documentation set.

The connection is written using Python3.

Regards,

Tim

 

---
Timothy P. McDowell Executive Vice President Thermal Energy System Specialists, LLC 22 N Carroll St, Suite 370 Madison, WI 53703 office: 608-274-2577 cell: 608-225-5250

On 2017-10-26 09:03, Gonon Frederick via TRNSYS-users wrote:

Dear all,
 
Does anybody know how to connect Trnsys with Python? There are two types (169 and 163) to realise this connection but it doesn't work yet with my simulation.
 
Anything important to take care of or maybe an example would be helpful.
 
Thank's for your help!!
 
Best regards,
 
Frederick Gonon

_______________________________________________
TRNSYS-users mailing list
TRNSYS-users@lists.onebuilding.org
http://lists.onebuilding.org/listinfo.cgi/trnsys-users-onebuilding.org

_______________________________________________
TRNSYS-users mailing list
TRNSYS-users@lists.onebuilding.org
http://lists.onebuilding.org/listinfo.cgi/trnsys-users-onebuilding.org