version 1.1, 2003/05/18 09:57:33 |
version 1.5, 2004/12/18 01:56:03 |
|
|
/* $OpenXM$ */ |
/* $OpenXM: OpenXM/src/asir-contrib/packages/doc/gnuplot.oxweave,v 1.4 2004/03/05 15:56:40 ohara Exp $ */ |
|
|
|
|
/*&C-texi |
/*&C |
@c DO NOT EDIT THIS FILE oxgnuplot.texi |
@c DO NOT EDIT THIS FILE oxgnuplot.texi |
*/ |
*/ |
/*&jp-texi |
/*&ja |
@node GNUPLOT $BH!?t(B,,, Top |
@node GNUPLOT Functions,,, Top |
@chapter GNUPLOT $BH!?t(B |
@chapter GNUPLOT $BH!?t(B |
|
|
$B$3$N@a$G$O(B GNUPLOT $B$N(B ox $B%5!<%P(B @code{ox_sm1_gnuplot} |
$B$3$N@a$G$O(B GNUPLOT $B$N(B ox $B%5!<%P(B @code{ox_sm1_gnuplot} |
|
|
@code{gnuplot} $B$O(B |
@code{gnuplot} $B$O(B |
@file{$(OpenXM_HOME)/lib/asir-contrib/} $B$K$"$k(B. |
@file{$(OpenXM_HOME)/lib/asir-contrib/} $B$K$"$k(B. |
*/ |
*/ |
/*&eg-texi |
/*&en |
@node GNUPLOT Functions,,, Top |
@node GNUPLOT Functions,,, Top |
@chapter GNUPLOT Functions |
@chapter GNUPLOT Functions |
|
|
Line 24 These interface functions are defined in the file @cod |
|
Line 24 These interface functions are defined in the file @cod |
|
The file @file{gnuplot} is at @* |
The file @file{gnuplot} is at @* |
@file{$(OpenXM_HOME)/lib/asir-contrib}. |
@file{$(OpenXM_HOME)/lib/asir-contrib}. |
*/ |
*/ |
/*&C-texi |
/*&C |
|
|
|
@menu |
|
* gnuplot.start:: |
|
* gnuplot:: |
|
* gnuplot.plot_dots:: |
|
* gnuplot.heat:: |
|
* gnuplot.plot_function:: |
|
* gnuplot.output:: |
|
* gnuplot.setenv:: |
|
* gnuplot.stop:: |
|
@end menu |
|
|
|
*/ |
|
/*&C |
@example |
@example |
@include opening.texi |
@include opening.texi |
[255] gnuplot.start(); |
[255] gnuplot.start(); |
Line 33 The file @file{gnuplot} is at @* |
|
Line 47 The file @file{gnuplot} is at @* |
|
0 |
0 |
@end example |
@end example |
*/ |
*/ |
/*&eg-texi |
/*&en |
The function |
The function |
@code{gnuplot.heat}(@var{dt},@var{step}) demonstrates our gnuplot interface. |
@code{gnuplot.heat}(@var{dt},@var{step}) demonstrates our gnuplot interface. |
It numerically solves the heat equation |
It numerically solves the heat equation |
Line 59 One can observe the instability by changing CFL number |
|
Line 73 One can observe the instability by changing CFL number |
|
gnuplot.heat_set_N(20); gnuplot.heat(0.003,30); (CFL > 0.5 unstable) |
gnuplot.heat_set_N(20); gnuplot.heat(0.003,30); (CFL > 0.5 unstable) |
@end example |
@end example |
*/ |
*/ |
/*&jp-texi |
/*&ja |
$B4X?t(B |
$B4X?t(B |
@code{gnuplot.heat}(@var{dt},@var{step}) $B$O$o$l$o$l$N(B GNUPLOT $B%$%s%?%U%'!<%94X?t$N%G%b(B |
@code{gnuplot.heat}(@var{dt},@var{step}) $B$O$o$l$o$l$N(B GNUPLOT $B%$%s%?%U%'!<%94X?t$N%G%b(B |
$B$G$"$k(B. |
$B$G$"$k(B. |
Line 87 CFL $B$rJQ$($k$3$H$K$h$j(B, $BIT0BDj@-$,@8$8$k$N$r4 |
|
Line 101 CFL $B$rJQ$($k$3$H$K$h$j(B, $BIT0BDj@-$,@8$8$k$N$r4 |
|
gnuplot.set_heat_N(20); gnuplot.heat(0.003,30); (CFL > 0.5 unstable) |
gnuplot.set_heat_N(20); gnuplot.heat(0.003,30); (CFL > 0.5 unstable) |
@end example |
@end example |
*/ |
*/ |
/*&C-texi |
/*&C |
Author of @code{GNUPLOT}: Thomas Williams, Colin Kelley |
Author of @code{GNUPLOT}: Thomas Williams, Colin Kelley |
*/ |
*/ |
|
|
/*&jp-texi |
/*&ja |
@section $BH!?t0lMw(B |
@section $BH!?t0lMw(B |
*/ |
*/ |
/*&eg-texi |
/*&en |
@section Functions |
@section Functions |
*/ |
*/ |
/*&jp-texi |
/*&ja |
@menu |
@node gnuplot.start,,, GNUPLOT Functions |
* gnuplot.start:: |
|
@end menu |
|
@node gnuplot.start,,, GNUPLOT $BH!?t(B |
|
@subsection @code{gnuplot.start} |
@subsection @code{gnuplot.start} |
@findex gnuplot.start |
@findex gnuplot.start |
@table @t |
@table @t |
Line 121 Author of @code{GNUPLOT}: Thomas Williams, Colin Kelle |
|
Line 132 Author of @code{GNUPLOT}: Thomas Williams, Colin Kelle |
|
@item $B<1JLHV9f$O(B, @code{Gnuplot_proc} $B$K3JG<$5$l$k(B. |
@item $B<1JLHV9f$O(B, @code{Gnuplot_proc} $B$K3JG<$5$l$k(B. |
@end itemize |
@end itemize |
*/ |
*/ |
/*&eg-texi |
/*&en |
@menu |
|
* gnuplot.start:: |
|
@end menu |
|
@node gnuplot.start,,, GNUPLOT Functions |
@node gnuplot.start,,, GNUPLOT Functions |
@subsection @code{gnuplot.start} |
@subsection @code{gnuplot.start} |
@findex gnuplot.start |
@findex gnuplot.start |
|
|
@item The descriptor is stored in @code{Gnuplot_proc}. |
@item The descriptor is stored in @code{Gnuplot_proc}. |
@end itemize |
@end itemize |
*/ |
*/ |
/*&C-texi |
/*&C |
@example |
@example |
P = gnuplot.start(); |
P = gnuplot.start(); |
@end example |
@end example |
*/ |
*/ |
/*&jp-texi |
/*&ja |
@table @t |
@table @t |
@item $B;2>H(B |
@item $B;2>H(B |
@code{ox_launch}, @code{gnuplot} |
@code{ox_launch}, @code{gnuplot} |
@end table |
@end table |
*/ |
*/ |
/*&eg-texi |
/*&en |
@table @t |
@table @t |
@item Reference |
@item Reference |
@code{ox_launch}, @code{gnuplot} |
@code{ox_launch}, @code{gnuplot} |
Line 164 P = gnuplot.start(); |
|
Line 172 P = gnuplot.start(); |
|
*/ |
*/ |
|
|
|
|
/*&eg-texi |
/*&en |
@menu |
|
* gnuplot:: |
|
@end menu |
|
@node gnuplot,,, GNUPLOT Functions |
@node gnuplot,,, GNUPLOT Functions |
@subsection @code{gnuplot} |
@subsection @code{gnuplot} |
@findex gnuplot |
@findex gnuplot |
|
|
gnuplot does not accept @code{^}. Use @code{**} instead. |
gnuplot does not accept @code{^}. Use @code{**} instead. |
@end itemize |
@end itemize |
*/ |
*/ |
/*&jp-texi |
/*&ja |
@menu |
@node gnuplot,,, GNUPLOT Functions |
* gnuplot:: |
|
@end menu |
|
@node gnuplot,,, GNUPLOT $BH!?t(B |
|
@subsection @code{gnuplot} |
@subsection @code{gnuplot} |
@findex gnuplot |
@findex gnuplot |
@table @t |
@table @t |
|
|
GNUPLOT $B$O(B @code{^} $B$r$&$1$D$1$J$$(B. $B$+$o$j$K(B, @code{**} $B$r;H$&(B. |
GNUPLOT $B$O(B @code{^} $B$r$&$1$D$1$J$$(B. $B$+$o$j$K(B, @code{**} $B$r;H$&(B. |
@end itemize |
@end itemize |
*/ |
*/ |
/*&C-texi |
/*&C |
@example |
@example |
[232] P = gnuplot.start(); |
[232] P = gnuplot.start(); |
0 |
0 |
|
|
|
|
@end example |
@end example |
*/ |
*/ |
/*&eg-texi |
/*&en |
@table @t |
@table @t |
@item Reference |
@item Reference |
@code{ox_launch}, @code{gnuplot.start}, @code{rtostr}, |
@code{ox_launch}, @code{gnuplot.start}, @code{rtostr}, |
|
|
in Japansese, ISBN4-924998-11-7 |
in Japansese, ISBN4-924998-11-7 |
@end table |
@end table |
*/ |
*/ |
/*&jp-texi |
/*&ja |
@table @t |
@table @t |
@item $B;2>H(B |
@item $B;2>H(B |
@code{ox_launch}, @code{gnuplot.start}, @code{rtostr}, |
@code{ox_launch}, @code{gnuplot.start}, @code{rtostr}, |
|
|
|
|
|
|
|
|
/*&eg-texi |
/*&en |
@menu |
|
* gnuplot.plot_dots:: |
|
@end menu |
|
@node gnuplot.plot_dots,,, GNUPLOT Functions |
@node gnuplot.plot_dots,,, GNUPLOT Functions |
@subsection @code{gnuplot.plot_dots} |
@subsection @code{gnuplot.plot_dots} |
@findex gnuplot.plot_dots |
@findex gnuplot.plot_dots |
|
|
When @var{d} == @code{[ ]}, the screen will be cleared. |
When @var{d} == @code{[ ]}, the screen will be cleared. |
@end itemize |
@end itemize |
*/ |
*/ |
/*&jp-texi |
/*&ja |
@menu |
@node gnuplot.plot_dots,,, GNUPLOT Functions |
* gnuplot.plot_dots:: |
|
@end menu |
|
@node gnuplot.plot_dots,,, GNUPLOT $BH!?t(B |
|
@subsection @code{gnuplot.plot_dots} |
@subsection @code{gnuplot.plot_dots} |
@findex gnuplot.plot_dots |
@findex gnuplot.plot_dots |
@table @t |
@table @t |
|
|
@var{d} == @code{[ ]} $B$N$H$-$O%9%/%j!<%s$,$^$:>C5n$5$l$k(B. |
@var{d} == @code{[ ]} $B$N$H$-$O%9%/%j!<%s$,$^$:>C5n$5$l$k(B. |
@end itemize |
@end itemize |
*/ |
*/ |
/*&C-texi |
/*&C |
@example |
@example |
[239] P = gnuplot.start(); |
[239] P = gnuplot.start(); |
0 |
0 |
|
|
0 |
0 |
@end example |
@end example |
*/ |
*/ |
/*&jp-texi |
/*&ja |
@table @t |
@table @t |
@item $B;2>H(B |
@item $B;2>H(B |
@code{gnuplot.start}, @code{plot "fileName" with options}(GNUPLOT command), |
@code{gnuplot.start}, @code{plot "fileName" with options}(GNUPLOT command), |
@code{gnuplot.clean}, @code{gnuplot} |
@code{gnuplot.clean}, @code{gnuplot} |
@end table |
@end table |
*/ |
*/ |
/*&eg-texi |
/*&en |
@table @t |
@table @t |
@item Reference |
@item Reference |
@code{gnuplot.start}, @code{plot "fileName" with options}(GNUPLOT command), |
@code{gnuplot.start}, @code{plot "fileName" with options}(GNUPLOT command), |
|
|
|
|
/** heat equation **/ |
/** heat equation **/ |
|
|
/*&eg-texi |
/*&en |
@menu |
|
* gnuplot.heat:: |
|
@end menu |
|
@node gnuplot.heat,,, GNUPLOT Functions |
@node gnuplot.heat,,, GNUPLOT Functions |
@subsection @code{gnuplot.heat} |
@subsection @code{gnuplot.heat} |
@findex gnuplot.heat |
@findex gnuplot.heat |
Line 427 with the initial condition |
|
Line 420 with the initial condition |
|
@noindent |
@noindent |
Algorithm: NOT Written. (Difference scheme. Courant-Levi-Friedrichs conditions.) |
Algorithm: NOT Written. (Difference scheme. Courant-Levi-Friedrichs conditions.) |
*/ |
*/ |
/*&jp-texi |
/*&ja |
@menu |
@node gnuplot.heat,,, GNUPLOT Functions |
* gnuplot.heat:: |
|
@end menu |
|
@node gnuplot.heat,,, GNUPLOT $BH!?t(B |
|
@subsection @code{gnuplot.heat} |
@subsection @code{gnuplot.heat} |
@findex gnuplot.heat |
@findex gnuplot.heat |
@table @t |
@table @t |
Line 458 Algorithm: NOT Written. (Difference scheme. Courant-Le |
|
Line 448 Algorithm: NOT Written. (Difference scheme. Courant-Le |
|
@item $B$3$N4X?t$O>-Mh(B @code{pde_heat_demo} $B$H8F$P$l$kM=Dj(B. |
@item $B$3$N4X?t$O>-Mh(B @code{pde_heat_demo} $B$H8F$P$l$kM=Dj(B. |
@end itemize |
@end itemize |
*/ |
*/ |
/*&C-texi |
/*&C |
@example |
@example |
[232] Heat_N = 20$ |
[232] Heat_N = 20$ |
[233] gnuplot.heat(0.001,30)$ |
[233] gnuplot.heat(0.001,30)$ |
Line 468 Algorithm: NOT Written. (Difference scheme. Courant-Le |
|
Line 458 Algorithm: NOT Written. (Difference scheme. Courant-Le |
|
|
|
|
|
|
|
/*&eg-texi |
/*&en |
@menu |
|
* gnuplot.output:: |
|
@end menu |
|
@node gnuplot.output,,, GNUPLOT Functions |
@node gnuplot.output,,, GNUPLOT Functions |
@subsection @code{gnuplot.output} |
@subsection @code{gnuplot.output} |
@findex gnuplot.output |
@findex gnuplot.output |
|
|
the output will be written to X11 display. |
the output will be written to X11 display. |
@end itemize |
@end itemize |
*/ |
*/ |
/*&jp-texi |
/*&ja |
@menu |
@node gnuplot.output,,, GNUPLOT Functions |
* gnuplot.output:: |
|
@end menu |
|
@node gnuplot.output,,, GNUPLOT $B4X?t(B |
|
@subsection @code{gnuplot.output} |
@subsection @code{gnuplot.output} |
@findex gnuplot.output |
@findex gnuplot.output |
@table @t |
@table @t |
|
|
@end itemize |
@end itemize |
*/ |
*/ |
|
|
/*&C-texi |
/*&C |
@example |
@example |
[273] gnuplot.output(|file="hoge.eps"); |
[273] gnuplot.output(|file="hoge.eps"); |
Graphic output of GNUPLOT will be written to hoge.eps as a Poscript file. |
Graphic output of GNUPLOT will be written to hoge.eps as a Poscript file. |
Line 533 Output device is set to X11 |
|
Line 517 Output device is set to X11 |
|
@end example |
@end example |
*/ |
*/ |
|
|
/*&eg-texi |
/*&en |
@table @t |
@table @t |
@item Reference |
@item Reference |
@code{gnuplot} |
@code{gnuplot} |
@end table |
@end table |
*/ |
*/ |
/*&jp-texi |
/*&ja |
@table @t |
@table @t |
@item $B;2>H(B |
@item $B;2>H(B |
@code{gnuplot} |
@code{gnuplot} |
Line 547 Output device is set to X11 |
|
Line 531 Output device is set to X11 |
|
*/ |
*/ |
|
|
|
|
/*&eg-texi |
/*&en |
@menu |
|
* gnuplot:: |
|
@end menu |
|
@node gnuplot.plot_function,,, GNUPLOT Functions |
@node gnuplot.plot_function,,, GNUPLOT Functions |
@subsection @code{gnuplot.plot_function} |
@subsection @code{gnuplot.plot_function} |
@findex gnuplot.plot_function |
@findex gnuplot.plot_function |
Line 573 Polynomial or a list of polynomials |
|
Line 554 Polynomial or a list of polynomials |
|
@end itemize |
@end itemize |
*/ |
*/ |
|
|
/*&jp-texi |
/*&ja |
@menu |
@node gnuplot.plot_function,,, GNUPLOT Functions |
* gnuplot:: |
|
@end menu |
|
@node gnuplot.plot_function,,, GNUPLOT $BH!?t(B |
|
@subsection @code{gnuplot.plot_function} |
@subsection @code{gnuplot.plot_function} |
@findex gnuplot.plot_function |
@findex gnuplot.plot_function |
@table @t |
@table @t |
@item gnuplot.gnuplot(@var{f}|proc=@var{p}) |
@item gnuplot.plot_function(@var{f}|proc=@var{p}) |
:: @code{gnuplot} $B%5!<%P$K(B @var{f} $B$N%0%i%U$r=q$/$h$&$KMj$`(B. |
:: @code{gnuplot} $B%5!<%P$K(B @var{f} $B$N%0%i%U$r=q$/$h$&$KMj$`(B. |
@end table |
@end table |
|
|
Line 598 Polynomial or a list of polynomials |
|
Line 576 Polynomial or a list of polynomials |
|
@item @code{gnuplot} $B%5!<%P$K(B @var{f} $B$N%0%i%U$r=q$/$h$&$KMj$`(B. |
@item @code{gnuplot} $B%5!<%P$K(B @var{f} $B$N%0%i%U$r=q$/$h$&$KMj$`(B. |
@end itemize |
@end itemize |
*/ |
*/ |
/*&C-texi |
/*&C |
|
|
@example |
@example |
[290] gnuplot.plot_function((x+sin(x))^2); |
[290] gnuplot.plot_function((x+sin(x))^2); |
Line 609 Polynomial or a list of polynomials |
|
Line 587 Polynomial or a list of polynomials |
|
|
|
*/ |
*/ |
|
|
/*&eg-texi |
/*&en |
@table @t |
@table @t |
@item Reference |
@item Reference |
@code{gnuplot.to_gnuplot_format} |
@code{gnuplot.to_gnuplot_format} |
@end table |
@end table |
*/ |
*/ |
/*&jp-texi |
/*&ja |
@table @t |
@table @t |
@item $B;2>H(B |
@item $B;2>H(B |
@code{gnuplot.to_gnuplot_format} |
@code{gnuplot.to_gnuplot_format} |
@end table |
@end table |
*/ |
*/ |
|
|
|
/*&en |
|
|
|
@node gnuplot.stop,,, GNUPLOT Functions |
|
@subsection @code{gnuplot.stop} |
|
@findex gnuplot.stop |
|
@table @t |
|
@item gnuplot.stop() |
|
:: Stop the gnuplot and remove the temporary fifo file. |
|
@end table |
|
|
|
@table @var |
|
@item return |
|
Void |
|
@item s |
|
String |
|
@end table |
|
|
|
@itemize @bullet |
|
@item Stop the @code{GNUPLOT} and remove the temporary fifo file generated |
|
by the mkfifo system call under the temporary directory. |
|
@end itemize |
|
*/ |
|
/*&ja |
|
|
|
@node gnuplot.stop,,, GNUPLOT Functions |
|
@subsection @code{gnuplot.stop} |
|
@findex gnuplot.stop |
|
@table @t |
|
@item gnuplot.stop() |
|
:: @code{GNUPLOT} $B$rDd;_$7(B, $BDL?.MQ$N(B fifo $B%U%!%$%k$r>C$9(B. |
|
@end table |
|
|
|
@table @var |
|
@item return |
|
Void |
|
@item s |
|
String |
|
@end table |
|
|
|
@itemize @bullet |
|
@item @code{GNUPLOT} $B$rDd;_$7(B, $B0l;~%G%#%l%/%H%j$N2<$K:n@.$5$l$?DL?.MQ$N(B fifo $B%U%!%$%k$r>C$9(B. |
|
@item $BDL?.MQ$N(B fifo $B%U%!%$%kL>$O(B gnuplot $B$G;O$^$k(B. |
|
@end itemize |
|
*/ |
|
|
|
/*&C |
|
@example |
|
[273] gnuplot.stop() |
|
@end example |
|
*/ |
|
|
|
/*&en |
|
@table @t |
|
@item Reference |
|
@code{gnuplot.start} |
|
@end table |
|
*/ |
|
/*&ja |
|
@table @t |
|
@item $B;2>H(B |
|
@code{gnuplot.start} |
|
@end table |
|
*/ |
|
|
|
/*&en |
|
@node gnuplot.setenv,,, GNUPLOT Functions |
|
@subsection @code{gnuplot.setenv} |
|
@findex gnuplot.setenv |
|
@table @t |
|
@item gnuplot.setenv(@var{key},@var{value}) |
|
:: |
|
@end table |
|
|
|
@table @var |
|
@item return |
|
Void |
|
@item key |
|
String |
|
@item value |
|
Object |
|
@end table |
|
|
|
@itemize @bullet |
|
@item The @var{key} takes the value either in |
|
"gnuplot.callingMethod" or "plot.gnuplotexec". |
|
@end itemize |
|
*/ |
|
/*&ja |
|
@node gnuplot.setenv,,, GNUPLOT Functions |
|
@subsection @code{gnuplot.setenv} |
|
@findex gnuplot.setenv |
|
@table @t |
|
@item gnuplot.setenv(@var{key},@var{value}) |
|
:: |
|
@end table |
|
|
|
@table @var |
|
@item return |
|
Void |
|
@item key |
|
String |
|
@item value |
|
Object |
|
@end table |
|
|
|
@itemize @bullet |
|
@item @code{key} $B$O(B "gnuplot.callingMethod" $B$^$?$O(B "plot.gnuplotexec". |
|
@end itemize |
|
*/ |
|
|
|
/*&C |
|
@example |
|
Use the old method to communicate with gnuplot (version 3). |
|
This method does not use mkfifo, but we need a patched version of gnuplot. |
|
[273] gnuplot.setenv("gnuplot.callingMethod",0); |
|
[274] gnuplot.setenv("plot.gnuplotexec",getenv("OpenXM_HOME")+"/bin/gnuplot4ox"); |
|
|
|
Calling your own gnuplot binary. |
|
[274] gnuplot.setenv("plot.gnuplotexec","/cygdrive/c/program files/gnuplot/pgnuplot.exe"); |
|
@end example |
|
*/ |
|
|
|
/*&en |
|
@table @t |
|
@item Reference |
|
@code{gnuplot.start} |
|
@end table |
|
*/ |
|
/*&ja |
|
@table @t |
|
@item $B;2>H(B |
|
@code{gnuplot.start} |
|
@end table |
|
*/ |
|
|
end$ |
end$ |
|
|