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

Re: [TRNSYS-users] Setting storageSize



Tom,

 I think the problem may be in how you declared the SPEICHER() array at the top of your code. Can you send an excerpt of the code used to declare SPEICHER()?

kind regards,

 David



On 03/02/2018 14:28, s0537085 via TRNSYS-users wrote:

Hello,

 

I try to set my storage size properly. So far I receive the massage: The shapes of the array expressions do not conform.

 

My idea is to user-specific number of nodes in my modell, which is PAR(1). Each node has 5 variables.

To set the storage size I write: size=PAR(1)*5.

At initial timestep I want to set the 5 variables to their initial values, using a loop.

                       

                     SIZE=PAR(1)*5

          CALL setStorageSize(SIZE,INFO)

       AN=JFIX(PAR(1)+0.1)

          ILAMDAA=0

          IXA=AN                       

          ITETAA=AN*2                    

          IAA=AN*3                       

   IBB=AN*4

          DO I=1,AN            

              ILAMDAA=ILAMDAA+1

              IXA=IXA+1                       

              ITETAA=ITETAA+1                    

              IAA=IAA+1                       

              IBB=IBB+1

              SPEICHER(ILAMDAA)=LAMDAA

              SPEICHER(IXA)=XA

              SPEICHER(ITETAA)=TETAA

              SPEICHER(IAA)=AA

              SPEICHER(IBB)=BB

          END DO

          CALL setStorageVars(SPEICHER,SIZE,INFO)

          RETURN 1

 

I already tried to get inspiration from Type4, but didn´t work.

 

Can someone help, please.

 

Kind regards

Tom

 



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

-- 
***************************
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
d.bradley@tess-inc.com

http://www.tess-inc.com
http://www.trnsys.com