Aller au contenu

Mathc gnuplot/002r

Un livre de Wikilivres.


Sommaire


Installer et compiler ce fichier dans votre répertoire de travail.

c00d.c
/* --------------------------------- */
/* save as  c00d.c                   */
/* --------------------------------- */
#include "x_hfile.h"
#include      "fd.h"
/* --------------------------------- */
int main(void)
{
CTRL_G w;
CTRL_H h;

  w.xmin = -2.; w.xmax =  10.;
  w.ymin = -1.; w.ymax = 100.;
           	
  h.tmin = -2.; h.tmax =  10.; h.step = 0.001;
 
 clrscrn();
 printf(" H : if(t>0) 1 else 0 \n\n"
        " Y : t-> %s       \n\n\n\n",Yeq);

     G_H(w,h,Y);

 printf(" To see the graph"
        " ... load \"a_main.plt\" ... with gnuplot.\n\n\n");
 stop();

 return 0;
}
/* --------------------------------- */
/* --------------------------------- */


Exemple de sortie écran :
 H : if(t>0) 1 else 0 

 Y : t-> Sum(t**2 * (-1)^n*H(t-.25*n),n=0..10)       



 To see the graph ... load "a_main.plt" ... with gnuplot.


 Press return to continue.