Overview
| Comment: | Fixed bug mtt_error --> mtt_error.txt Replaced lsode by Euler integration. |
|---|---|
| Downloads: | Tarball | ZIP archive |
| Timelines: | family | ancestors | descendants | both | origin/master | trunk |
| Files: | files | file ages | folders |
| SHA3-256: |
54877be992776749c0b1d238cab10104 |
| User & Date: | gawthrop@users.sourceforge.net on 1997-01-06 21:36:44.000 |
| Other Links: | branch diff | manifest | tags |
Context
|
1997-01-07
| ||
| 09:16:03 |
Added step_factor parameter - gives that number of integration steps per sample. check-in: 9fd21e4896 user: gawthrop@users.sourceforge.net tags: origin/master, trunk | |
|
1997-01-06
| ||
| 21:36:44 |
Fixed bug mtt_error --> mtt_error.txt Replaced lsode by Euler integration. check-in: 54877be992 user: gawthrop@users.sourceforge.net tags: origin/master, trunk | |
|
1997-01-05
| ||
| 19:34:35 | Don't write globals which are already assigned to a number. check-in: 16bd2610f6 user: gawthrop@users.sourceforge.net tags: origin/master, trunk | |
Changes
Modified mttroot/mtt/bin/trans/ode2odes_m
from [216203f9c6]
to [9640440e1a].
| ︙ | ︙ | |||
11 12 13 14 15 16 17 18 19 20 21 22 23 24 | # Copyright (c) P.J.Gawthrop, 1996. ############################################################### ## Version control history ############################################################### ## $Id$ ## $Log$ ## Revision 1.7 1996/09/12 18:41:48 peter ## Standard error handling added. ## ## Revision 1.6 1996/08/24 14:11:04 peter ## Global parameter passing. ## ## Revision 1.5 1996/08/18 12:01:26 peter | > > > | 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 | # Copyright (c) P.J.Gawthrop, 1996. ############################################################### ## Version control history ############################################################### ## $Id$ ## $Log$ ## Revision 1.8 1996/09/13 17:54:08 peter ## Now writes default $PARAMS to $1_args.m - $1_ode may use it. ## ## Revision 1.7 1996/09/12 18:41:48 peter ## Standard error handling added. ## ## Revision 1.6 1996/08/24 14:11:04 peter ## Global parameter passing. ## ## Revision 1.5 1996/08/18 12:01:26 peter |
| ︙ | ︙ | |||
49 50 51 52 53 54 55 | else PARAMS=$2; fi PARAMS="$PARAMS ;" | | | 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 | else PARAMS=$2; fi PARAMS="$PARAMS ;" $MATRIX << EOF > ode2odes_m.log 2>mtt_error.txt %Read in parameters $1_numpar; [nx,ny,nu,nz,nyz] = $1_def; t=0; %Just in case it appears in the parameter list. |
| ︙ | ︙ | |||
74 75 76 77 78 79 80 |
[n,m]=size(T);
if m>n
T=T';
end;
if nx>0
| | > > > > > > > > > > | | | | 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 |
[n,m]=size(T);
if m>n
T=T';
end;
if nx>0
% x = lsode('$1_ode', x0, T);
%Euler integration
x = x0;
X=[];
dt = T(2)-T(1);
for t=T'
X = [X x];
dx = $1_ode(x,t);
x = x + dx*dt;
end;
X = X';
write_matrix([T,X], '$1_odes');
else
X = zeros(size(T));
end;
if ny>0
i=0;
for tt=T'
i=i+1;
y(i,:) = $1_odeo(X(i,:),tt)';
end;
write_matrix([T,y], '$1_odeso');
end;
EOF
# Now invoke the standard error handling.
|
| ︙ | ︙ |