Overview
Comment:Remove a du state ment causaing touble
- but needs more work.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | origin/master | trunk
Files: files | file ages | folders
SHA3-256: fc06d98918d9e75698ff0c3fe7af5e46018e797b78edaf13744efb8a9fbbf407
User & Date: gawthrop@users.sourceforge.net on 1996-08-25 10:07:05
Other Links: branch diff | manifest | tags
Context
1996-08-25
10:13:37
Initial revision check-in: 459e1a3aa3 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
10:07:05
Remove a du state ment causaing touble
- but needs more work.
check-in: fc06d98918 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
09:53:35
Error handling added. check-in: 8d9b71b3b1 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
Changes

Modified mttroot/mtt/bin/trans/ode2obs_r from [084cef41d4] to [e4a7eab05c].

11
12
13
14
15
16
17



18
19
20
21
22
23
24
# Copyright (c) P.J.Gawthrop 1991, 1992, 1994, 1995, 1996.

###############################################################
## Version control history
###############################################################
## $Id$
## $Log$



## Revision 1.1  1996/08/25 08:37:44  peter
## Initial revision
##
###############################################################

#Inform user
echo Creating $1_obs.r







>
>
>







11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# Copyright (c) P.J.Gawthrop 1991, 1992, 1994, 1995, 1996.

###############################################################
## Version control history
###############################################################
## $Id$
## $Log$
## Revision 1.2  1996/08/25 08:38:14  peter
## Error handling added.
##
## Revision 1.1  1996/08/25 08:37:44  peter
## Initial revision
##
###############################################################

#Inform user
echo Creating $1_obs.r
51
52
53
54
55
56
57

58
59

60
61
62
63
64
65
66
67
68
69
70
Matrix MTTUU(MTTNuu,1);

FOR i := 1:MTTNu DO
  MTTUU(i,1) := MTTU(i,1);
END;

IF MTTGPCNu>0 THEN

FOR i := 1:MTTNu DO
  MTTUU(i+MTTNu,1) := MTTdU(i,1);

END;

MTTU := MTTU;
MTTdU := MTTdU;
MTTUU := MTTUU;

%Create the Y vector of output derivatives.
MTTNyy := (MTTGPCNy+1)*MTTNy;
Matrix MTTYY(MTTNyy,1);

FOR i := 1:MTTNy DO







>
|
|
>



|







54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
Matrix MTTUU(MTTNuu,1);

FOR i := 1:MTTNu DO
  MTTUU(i,1) := MTTU(i,1);
END;

IF MTTGPCNu>0 THEN
BEGIN
  FOR i := 1:MTTNu DO
    MTTUU(i+MTTNu,1) := MTTdU(i,1);
  END;
END;

MTTU := MTTU;
%  MTTdU := MTTdU; ---- removed temporarily, needs def file change? 
MTTUU := MTTUU;

%Create the Y vector of output derivatives.
MTTNyy := (MTTGPCNy+1)*MTTNy;
Matrix MTTYY(MTTNyy,1);

FOR i := 1:MTTNy DO
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
write ";END;";

SHUT "$1_obs.r";
quit;

EOF


#Reduce writes errors to std output with ***** in front.
grep '\*\*\*\*\*' ode2obs_r.log >mtt_error
# Test for errors and print if any
err_length=$(wc -c <mtt_error)
if [ $err_length != "0" ]
then
  echo MTT has failed with the following errors '...'
  cat mtt_error
  exit 1
else
  exit 0
fi













|
<
<
<
<
<
<
<
|
<
<
<
<

<
<
<
<
<
166
167
168
169
170
171
172
173







174




175





write ";END;";

SHUT "$1_obs.r";
quit;

EOF

# Now invoke the standard error handling.







mtt_error_r ode2obs_r.log











MTT: Model Transformation Tools
GitHub | SourceHut | Sourceforge | Fossil RSS ]