Welcome to the TRNSYS Users Forum.

The forum is a place where people can interact and have discussions about different topics involving the use of the TRNSYS software package. Here you can post topics for discussion or questions on using TRNSYS and get advice from other users or TRNSYS experts. This forum is not intended for detailed technical support. Users should contact their distributor’s hotline for such assistance.

Some tips for success on using the forum:

  • Follow the Forum Rules posted in Forum Administration.
  • There are categories for different types of topics and questions. Post your topic or question into the proper category.
  • Before posting a topic or question search the existing topics  (and the TRNSYS Users listserv archive or Post archive) to see if a similar topic or question has already been answered.
  • Use a descriptive topic name. Don’t use attention getting subjects, they don’t get attention and only annoy people.
  • State the version of TRNSYS and which add-ons your are using.
  • Include enough specific details for your topic of question to be answered. Just posting “Why am I getting an error?” without describing the specific error and what you are trying to do when you get the error will not receive a response that fixes your issue.
  • Remember when people help you, they are doing you a favor. Be patient, help people out by posting good descriptions of what you need help with, and be polite even if a response does not solve your issue.
  • Moderators may edit your post for clarity or move your topic to a more appropriate category.

Notifications
Clear all

[Solved] How to submit seasonal/ annual domestic hot water profile to TRNSYS?

3 Posts
2 Users
0 Reactions
498 Views
0
Topic starter

Hello. I modeled a domestic hot water system in TRNSYS and I use Type 14 for a daily profile but it would be cumbersome to do an annual profile with it. Fortunately, I understand in the documentation that Type 41 may be used to take into account the seasonal variability of the DHW demand I have not been able to understand the use of Type 41 as described in the Mathematical Reference. I present here a simple case:

1/ I have 4 profiles during the year, one for each season: summer, winter, spring and fall. During each season, I have the same profile for the 5 working days and another one for the 2 weekend days. I don't care about special holidays. How do I proceed with Type 41?

2/ Alternatively, is it possible to provide a text file to TRNSYS, with a profile for the whole year (e.g. one column for the time, from 0 to 8760, and a value for the flow)?

3/ Alternatively, if I proceed with type 14 on a weekly basis, after a first week for instance, would I save the status of the system in order to launch the following weeks (with a new type 14 profile) and so on, for the 52 weeks? This actually means a new Type 14 for each season and the status of the system should be saved to start the following season.

Thank you.

1 Answer
0

Ken,

1) If you want to use Type 41 to do this, I would first build the eight daily profiles you want (weekday winter, weekend winter, weekday spring, weekend spring, etc.) as Type 14 forcing functions. Then I would write something like the following in an equation block:

IsWinter = LT(Time,2190)
IsSpring = GE(Time,2190)*LT(Time,4380)
IsSummer=GE(Time,4380)*LT(Time,6570)
IsFall=GE(Time,6570)

WeekdayDraw = IsWinter*WinterWeekday + IsSpring*SpringWeekday + IsSummer*SummerWeekday + IsFall*FallWeekday
WeekendDraw = IsWinter*WinterWeekend + IsSpring*SpringWeekend + IsSummer*SummerWeekend + IsFall*FallWeekend

'Time' is a variable TRNSYS already recognizes as the hour of the year, you don't have to connect it or do anything else to define it. Connect 'WinterWeekday', 'WinterWeekend', etc. from the outputs of their respective forcing functions, and connect 'WeekdayDraw' and 'WeekendDraw' to their corresponding inputs in Type 41. You probably want to tweak those start and stop hours for each season, and I should note that this won't repeat annually if you want to run a simulation longer than 8760 hours ... still, it should give you a good starting point for what you're trying to accomplish. 

(LT = "less than", GE = "greater than or equal to" - these and other logic functions are explained in the TRNEdit documentation, under "Available mathematical functions". You can also reference this post I wrote on the forum about using equation blocks to write IF statements).

2) Yes, you can provide a text file to TRNSYS with the profile for the whole year. Use the Type 9 data reader (also in the Utilities library) to do that. That may actually be easier than building eight forcing function profiles and wiring them up through the equation block and through Type 41 to get exactly the profile you want. 

 

Ken Topic starter 08/06/2023 11:07 am

@a_weiss
Dear a_weiss , thank you very much for your detailed suggestions. I have just implemented the second solution (use of Type 9) and it works perfectly. So, my issue is solved.
I however wonder what could be the interest of the solution with Type 41 since it is very easy to generate a file to be read by Type 9. Thanks.

A_Weiss A_Weiss 08/06/2023 1:54 pm

@ken Depends on the situation. If you had a profile that you only wanted to run on weekdays, and be 0 on weekends and/or holidays, it would be very easy to connect that profile to the 'weekday' input of Type 41 and leave the weekend/holiday input unconnected at 0. That may be easier than manually copy/pasting the profile in a spreadsheet program and keeping track of weekday/weekend/holiday days while doing so. But there's no right or wrong way to do it, as long as the solution works for your situation. Flexibility is one of the major selling points of TRNSYS!

Share: