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

[TRNSYS-users] Problems with dynamic arrays definition in new types



Dear Trnsys users,
 
I have a question concerning to the use of Dynamic arrays in new Trnsys types. I'm programming a new Type with fortran 90 and I'm using the instruction ALLOCATABLE to define the dimension of some arrays. This dimension is depending on an input defined in the proforma.
 
The issue is that I don't exactly know at which step iteration should I define the array dimension so that this dimenson keeps saved in each iteration. In other words, if I define the array dimension just bellow the variables definition, each time the trnsys call my type, the matrix appear as "Undefined pointer/array" until trnsys finds the ALLOCATE instruction. This happens even if I've already defined the dimension in previous iteration callings. This fact affects all the calculations because one of the arrays is the STORED array, which I use to update the temporary terms of my ecuations.  
 
Does anybody know who to solve this problem?
 
Many thanks,
 
Jordi Cipriano
BEE-Group
CIMNE-Terrassa
CIMNE. Spain
BEGIN:VCARD
VERSION:2.1
N:Líndez;Jordi Cipriano
FN:Jordi Cipriano Líndez
ORG:CIMNE-Bee Group
TEL;WORK;VOICE:+34 937899169; +34 973003581
TEL;WORK;FAX:+34937883110
ADR;WORK:;;Dr. Ullés nº 2. 3º;Terrassa;Spain;08224
LABEL;WORK;ENCODING=QUOTED-PRINTABLE:Dr. Ull=E9s n=BA 2. 3=BA=0D=0ATerrassa, Spain 08224
URL;WORK:http://www.cimne.com/beegroup
EMAIL;PREF;INTERNET:cipriano@cimne.upc.edu
REV:20070524T160314Z
END:VCARD