/[ascend]/trunk/models/johnpye/datareader/testtmy.a4c
ViewVC logotype

Annotation of /trunk/models/johnpye/datareader/testtmy.a4c

Parent Directory Parent Directory | Revision Log Revision Log


Revision 812 - (hide annotations) (download) (as text)
Fri Aug 11 04:22:18 2006 UTC (14 years, 2 months ago) by johnpye
File MIME type: text/x-ascend
File size: 680 byte(s)
First apparently working version of data reader. This version just done linear interpolation.
1 johnpye 811 IMPORT "johnpye/datareader/datareader";
2     REQUIRE "atoms.a4l";
3    
4 johnpye 812 MODEL drconf;
5     filename IS_A symbol_constant;
6     format IS_A symbol_constant;
7     format :== 'TMY2';
8     END drconf;
9    
10 johnpye 811 MODEL testtmy;
11     t IS_A time;
12 johnpye 812 G IS_A solver_var;
13     Gbn IS_A solver_var;
14     G2 IS_A solver_var;
15 johnpye 811
16 johnpye 812 tmydata IS_A drconf;
17     tmydata.filename :== '/home/john/src/ascend/models/johnpye/datareader/23161.tm2';
18 johnpye 811
19     filereader:datareader(
20     t : INPUT;
21     G, Gbn : OUTPUT;
22 johnpye 812 tmydata : DATA
23 johnpye 811 );
24    
25 johnpye 812 G2 = G + Gbn;
26 johnpye 811
27 johnpye 812 METHODS
28    
29     METHOD default_self;
30     END default_self;
31    
32     METHOD on_load;
33     RUN default_self; RUN specify; RUN values;
34     END on_load;
35    
36     METHOD specify;
37     FIX t;
38     END specify;
39    
40     METHOD values;
41     t := 0 {s};
42     END values;
43    
44 johnpye 811 END testtmy;

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22