1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
#! /bin/sh
######################################
##### Model Transformation Tools #####
######################################
###############################################################
## Version control history
###############################################################
## $Id$
## $Log$
## Revision 1.65 2001/11/15 06:24:11 geraint
## Updated (-i dassl) residual function to use new DAEFunc (octave-2.1.35).
## YZ residual dependency on Ui still requires some work.
##
## Revision 1.64 2001/08/08 02:15:00 geraint
## Rationalisation of solver code, beginning with algebraic solvers.
##
|
>
>
>
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
#! /bin/sh
######################################
##### Model Transformation Tools #####
######################################
###############################################################
## Version control history
###############################################################
## $Id$
## $Log$
## Revision 1.66 2002/03/26 11:58:58 geraint
## Added cputime monitoring.
##
## Revision 1.65 2001/11/15 06:24:11 geraint
## Updated (-i dassl) residual function to use new DAEFunc (octave-2.1.35).
## YZ residual dependency on Ui still requires some work.
##
## Revision 1.64 2001/08/08 02:15:00 geraint
## Rationalisation of solver code, beginning with algebraic solvers.
##
|
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
|
data.elem (row, ++col) = y.elem (i);
data.elem (row, ++col) = t;
for (register int i = 0; i < nx; i++)
data.elem (row, ++col) = x.elem (i);
row++;
static std::fstream fcputime ("MTT.cputime", ios::out | ios::trunc | ios::app);
static clock_t cputime0 = clock();
static clock_t cputime1 = cputime0;
clock_t cputime = clock();
fcputime << t << '\t'
<< static_cast <double> (cputime - cputime0) / CLOCKS_PER_SEC << '\t'
<< static_cast <double> (cputime - cputime1) / CLOCKS_PER_SEC << std::endl;
cputime1 = cputime;
|
|
|
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
|
data.elem (row, ++col) = y.elem (i);
data.elem (row, ++col) = t;
for (register int i = 0; i < nx; i++)
data.elem (row, ++col) = x.elem (i);
row++;
static std::fstream fcputime ("MTT.cputime", std::ios::out | std::ios::trunc | std::ios::app);
static clock_t cputime0 = clock();
static clock_t cputime1 = cputime0;
clock_t cputime = clock();
fcputime << t << '\t'
<< static_cast <double> (cputime - cputime0) / CLOCKS_PER_SEC << '\t'
<< static_cast <double> (cputime - cputime1) / CLOCKS_PER_SEC << std::endl;
cputime1 = cputime;
|