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

RE: Problems with second TYPE 45



Juan, 

TRNSYS Types check the number of inputs/parameters/derivatives with a call
to Typeck. During that call, Typeck compares the right numbers (often called
NI, NP, ND in the code) with the actual numbers in the deck file (which
TRNSYS stores in the INFO array).

When Type45 calls Type38, the INFO array is "the INFO array for Type45", not
the one for Type38 (since Type38 doesn't even appear in the deck file). So
Type38 just skips the call to Typeck if it was called from within Type45.
This is what the following line in the code is doing:
IF(INFO(2).EQ.45) GO TO 5

Now, I assume you renamed Type45 to Type145 and Type38 to Type138 and also
renamed all subroutines. Your Type138 also has to skip the call to Typeck
when it is called from within Type145, which you can do by changing the line
to:
IF(INFO(2).EQ.145) GO TO 5

You have also to keep in mind that all errors occuring in Type138 will
appear to happen in Type145 since the INFO array is the one from Type145.

I hope the fog is clearing a little bit! Please let us know if it works.

Michaël

_________________________________________________________

Michaël Kummert

Solar Energy Laboratory - University of Wisconsin-Madison
1303 Engr Res Bldg, 1500 Engineering Drive
Madison, WI 53706

Tel: +1 (608) 263-1589
Fax: +1 (608) 262-8464
E-mail: kummert@engr.wisc.edu

SEL Web Site: http://sel.me.wisc.edu 
TRNSYS Web Site: http://sel.me.wisc.edu/trnsys



-----Original Message-----
From: owner-trnsys@relay.doit.wisc.edu
[mailto:owner-trnsys@relay.doit.wisc.edu] On Behalf Of Juan Pablo Salazar
Sent: Thursday, April 03, 2003 13:22
To: trnsys@relay.doit.wisc.edu
Subject: Problems with second TYPE 45


Dear TRNSYS Users,
 
I am still getting the following error with my second TYPE 45 (now TYPE 145)
component.
 
 
***** ERROR *****        TRNSYS ERROR # 103
 UNIT  23 TYPE 145
  10 INPUTS WERE SPECIFIED,  5 ARE REQUIRED
 CHECK COMPONENT CONFIGURATION
 
 
 ***** ERROR *****        TRNSYS ERROR # 103
 UNIT  23 TYPE 145
  39 PARAMETERS WERE SPECIFIED, 11 ARE REQUIRED
 CHECK COMPONENT CONFIGURATION
 
 
 ***** ERROR *****        TRNSYS ERROR # 103
 UNIT  23 TYPE 145
  10 INPUTS WERE SPECIFIED,  5 ARE REQUIRED
 CHECK COMPONENT CONFIGURATION
 
 
 ***** ERROR *****        TRNSYS ERROR # 103
 UNIT  23 TYPE 145
  39 PARAMETERS WERE SPECIFIED, 11 ARE REQUIRED
 CHECK COMPONENT CONFIGURATION
 
As specified in the “Red Book”, not to be mistaken with another “Red Book”,
namely that of Bilbo Baggins, the INFO array values from position 1 thru 5
are read from the DECK file. This is obviously working because I’m getting
the error message with the right number of inputs and parameters that are
required by TYPE 45. So where does this information of 5 inputs and 11
parameters come from? 
 
I also have the non-standard TYPE144 (Swimming Pool) and it assigns the NI,
NP and ND values within it’s source code, overwriting values that may have
been read from the DECK file. May this be the solution?
 
Please tell me if what I wrote is just a bunch of nonsense!
 
Best regards,
Juan Pablo de L. C. Salazar