Blame doc/examples/specfun.c

Packit 67cb25
#include <stdio.h>
Packit 67cb25
#include <gsl/gsl_sf_bessel.h>
Packit 67cb25
Packit 67cb25
int
Packit 67cb25
main (void)
Packit 67cb25
{
Packit 67cb25
  double x = 5.0;
Packit 67cb25
  double expected = -0.17759677131433830434739701;
Packit 67cb25
  
Packit 67cb25
  double y = gsl_sf_bessel_J0 (x);
Packit 67cb25
Packit 67cb25
  printf ("J0(5.0) = %.18f\n", y);
Packit 67cb25
  printf ("exact   = %.18f\n", expected);
Packit 67cb25
  return 0;
Packit 67cb25
}