Overview
Comment:No longer uses save_ascii_data_for_plotting function to write data
- eliminates dependence on liboctinterp (and libncurses) for .cc.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | origin/master | trunk
Files: files | file ages | folders
SHA3-256: e34b83bfe1212c32b46c8017ab76c9f673044365509842afbd248fab6d33371e
User & Date: geraint@users.sourceforge.net on 2002-05-01 12:21:29
Other Links: branch diff | manifest | tags
Context
2002-05-01
12:24:41
Removed unnecessary inclusion of load-save.h. check-in: 2cbc22ff2d user: geraint@users.sourceforge.net tags: origin/master, trunk
12:21:29
No longer uses save_ascii_data_for_plotting function to write data
- eliminates dependence on liboctinterp (and libncurses) for .cc.
check-in: e34b83bfe1 user: geraint@users.sourceforge.net tags: origin/master, trunk
2002-04-30
23:27:00
Replaced octave_map with columnvector in simpar.cc. Not quite as descriptive but
standardises the interfaces somewhat and reduces the dependency on liboctinterp
(and thus libreadline, libkpathsea, libncurses, etc).
check-in: 8641b82344 user: geraint@users.sourceforge.net tags: origin/master, trunk
Changes

Modified mttroot/mtt/bin/mttrc from [e928afb320] to [b1c9b36ff2].

11
12
13
14
15
16
17




18
19
20
21
22
23
24
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28







+
+
+
+









###############################################################
## Version control history
###############################################################
## $Id$
## $Log$
## Revision 1.27  2002/04/28 18:41:26  geraint
## Fixed [ 549658 ] awk should be gawk.
## Replaced calls to awk with call to gawk.
##
## Revision 1.26  2002/04/26 16:16:33  geraint
## Removed unnecessary variables PLAT and GCCVERS.
##
## Revision 1.25  2002/04/02 09:16:39  geraint
## Tidied up library search paths, now assumes that system libraries are set up correctly.
## For Debian, this means installing the following: blas-dev, fftw-dev, lapack-dev, libncurses5-dev, libkpathsea-dev, libreadline-dev
## It may also be necessary to run /sbin/ldconfig on the relevant directories (especially Octave's).
193
194
195
196
197
198
199
200
201


202
203
204
205
206
207
208
197
198
199
200
201
202
203


204
205
206
207
208
209
210
211
212







-
-
+
+







    # include paths

    IOCTAVE="-I${PREFIX}/include/octave/ -I${PREFIX}/include/octave/octave"

    # library paths

    OCTAVEVERS=`octave --version | gawk '{ print $4 }'`
    LOCTAVE="-L${PREFIX}/lib/octave-${OCTAVEVERS} -loctave -lcruft -loctinterp"
    LSYSTEM="-ldl -lm -lncurses -lkpathsea -lreadline -lblas -llapack -lfftw -lg2c"
    LOCTAVE="-L${PREFIX}/lib/octave-${OCTAVEVERS} -loctave -lcruft"
    LSYSTEM="-ldl -lm -lkpathsea -lreadline -lblas -llapack -lfftw -lg2c"

    # compiler options

    DEBUG="-g"
    OPTIM="-O3"
    FLAGS="-fno-rtti -fno-exceptions -fno-implicit-templates"

Modified mttroot/mtt/bin/trans/make_ode2odes from [0dc2f50e29] to [7870987d9c].

1
2
3
4
5
6
7
8
9
10
11





12
13
14
15
16
17
18
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23











+
+
+
+
+







#! /bin/sh

     ###################################### 
     ##### Model Transformation Tools #####
    ######################################

###############################################################
## Version control history
###############################################################
## $Id$
## $Log$
## Revision 1.71  2002/04/30 23:27:00  geraint
## Replaced octave_map with columnvector in simpar.cc. Not quite as descriptive but
## standardises the interfaces somewhat and reduces the dependency on liboctinterp
## (and thus libreadline, libkpathsea, libncurses, etc).
##
## Revision 1.70  2002/04/28 18:41:27  geraint
## Fixed [ 549658 ] awk should be gawk.
## Replaced calls to awk with call to gawk.
##
## Revision 1.69  2002/04/17 13:46:58  geraint
## #include <fstream> for -oct as well as -cc.
##
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
407
408
409
410
411
412
413

414
415
416
417

418
419
420
421

422
423
424
425
426
427
428







-




-




-







make_cc() 
{
# get octave version
case `$MATRIX --version | gawk -F\. '{print $2}'` in
    0) # stable
	vector_value=vector_value
	feval_header=toplev.h
	save_ascii_data_function=save_ascii_data
	;;
    1) # development
	vector_value=column_vector_value
	feval_header=parse.h
	save_ascii_data_function=save_ascii_data_for_plotting
	;;
    *)
	vector_value=column_vector_value
	feval_header=parse.h
	save_ascii_data_function=save_ascii_data_for_plotting
	;;
esac

cat <<EOF  > $filename
#include <octave/oct.h>
#include <octave/load-save.h>
#include <octave/lo-mappers.h>
917
918
919
920
921
922
923




924


925
926
927
928
929
930
931
919
920
921
922
923
924
925
926
927
928
929

930
931
932
933
934
935
936
937
938







+
+
+
+
-
+
+







  static int row;

  if (dump_data)
    {
       if (row > 0)
         {
           Matrix written_data = data.extract (0, 0, row-1, data.cols ()-1);
	   file << "# name: mtt_dump" << std::endl
		<< "# type: matrix" << std::endl
		<< "# rows: " << written_data.rows () << std::endl
		<< "# columns: " << written_data.columns () << std::endl
           $save_ascii_data_function (file, written_data, "mtt_data");
		<< written_data;
	   file.flush ();
	 }
       return;
    }

  const int nx = x.length (), ny = y.length ();
  register int col = 0;

949
950
951
952
953
954
955
956
957






958
959
960
961
962
963
964
956
957
958
959
960
961
962


963
964
965
966
967
968
969
970
971
972
973
974
975







-
-
+
+
+
+
+
+







	   << static_cast <double> (cputime - cputime0) / CLOCKS_PER_SEC << '\t'
	   << static_cast <double> (cputime - cputime1) / CLOCKS_PER_SEC << std::endl;
  cputime1 = cputime;

  if (nrows == row)
    {
#ifdef STANDALONE
      $save_ascii_data_function (file, data, "mtt_data");
//    std::cout << data << std::endl;
      file << "# name: mtt_dump" << std::endl
	   << "# type: matrix" << std::endl
	   << "# rows: " << data.rows () << std::endl
	   << "# columns: " << data.columns () << std::endl
	   << data;
      file.flush ();
#else // ! STANDALONE
  set_global_value ("MTT_data", data);
#endif
    row = 0;
    fcputime.close();
    }
}

Modified mttroot/mtt/debian/control from [9e6dc56b5b] to [c16da457b0].

1
2
3
4
5
6
7
8
9
10
11

12
13
14
15
16
17
18
1
2
3
4
5
6
7
8
9
10

11
12
13
14
15
16
17
18










-
+







Source: mtt
Section: math
Priority: optional
Maintainer: Geraint <geraint@users.sf.net>
Build-Depends: debhelper (>> 3.0.0)
Standards-Version: 3.5.2

Package: mtt
Architecture: all
Depends: gawk, octave, xfig
Recommends: blas-dev, fftw-dev, c-compiler, g++, gnuplot, info-browser, lapack-dev, latex2html, libkpathsea-dev, libncurses5-dev, libreadline4-dev, pdf-viewer, postscript-viewer, octave-headers, octave-info, octave-sp, p2c, transfig, xterm, www-browser, wish
Recommends: blas-dev, fftw-dev, c-compiler, g++, gnuplot, info-browser, lapack-dev, latex2html, libkpathsea-dev, libreadline4-dev, pdf-viewer, postscript-viewer, octave-headers, octave-info, p2c, transfig, xterm, www-browser, wish
Suggests: scigraphica
Description: Model Transformation Tools.
 A set of tools for modelling dynamic physical systems using the bond-graph
 methodology and transforming these models into representations suitable for
 analysis, control and simulation. These tools use, and generate m files for,
 GNU Octave.
 .


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