File: sin3.jgr

package info (click to toggle)
jgraph 83-20
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 628 kB
  • ctags: 445
  • sloc: ansic: 4,728; makefile: 186; sh: 106; awk: 104
file content (25 lines) | stat: -rw-r--r-- 630 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
(* This is the same as sin.jgr only a different include file of points is
used:  This one orders the points by ascending y value instead of ascending
x value.  The graph looks quite different *)

newgraph 

yaxis min -1 max 1 label : sin(i)
xaxis min -10 max 10 label : i

(* Plot the sin curve *)
curve 1 
  marktype none
  linetype solid
  pts include sin3.pts
   (* sin.pts was created by the following c program:

     #include <math.h>
     main();
     {
       double x;
       for (x = -10.0; x < 10.0; x += .03)
         printf("%f %f\n", x, sin(x));
     }
     
   * and then the output was piped through sort -n +1 *)