---------- Forwarded message ----------
From: Ayoze Amaro García <[EMAIL PROTECTED]>
Date: 2008/5/22
Subject: how GSL works?
To: [email protected]


  Good day,

  A few days ago I discovered the gsl, wich was aperfecto option for my
classes, but I trying to doy a very simple program with complex numbers:
creating, add, sub, and so on, but I can not neither compile nor execute
because it seems that I am not linking well or something like that. I send
my example code reduced tu just make rect numbers and add them after, to
print  the result on screen at the end.

  Thanks in advance.


Ayoze Amaro García
#include <stdio.h> 
#include </usr/include/gsl/gsl_complex.h>
#include </usr/include/gsl/gsl_complex_math.h>

main()
{
gsl_complex z,r, sum;
double x,y;
x= 3;
y= 4;
z = gsl_complex_rect (x,y);
r = gsl_complex_rect (y,x);
sum = gsl_complex_add (z,r);
printf ("The sum is: %f\n", sum);
}
_______________________________________________
Help-gsl mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-gsl

Reply via email to