This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Offer to help with TR1 Math


Curt Brune wrote:
On Tue, Nov 21, 2006 at 10:57:20PM -0500, Ed Smith-Rowland wrote:
A fellow physicist! I'm a nuke myself. I would say the basics of what I said in that email are still true.
The biggest holes are still the Bessel and Neumann functions of arbitrary real order. There is a scheme used by the GSL project and described in the second edition of Numerical Recipes that I think we'll adopt.

I have that book and can look in to it.


I used Arfken for the orthogonal polynomials (Legendre, Laguerre, Hermite).

I used Abramowitz and Stegun for just about everything.

The whole thing needs to be worked over for sanity and naming and commentary.

Plus putting these functions through real use would really help.

Anyhoo, help would be most welcome! This material is, as one of my professors said, is "cut but not dried". I guess that goes some way towards explaining why the C++ committee decided not to move these functions into the main C++ draft.

*sniff*

Anyway, maybe with another implementation the balance of power will shift . . .

I am looking at http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2005/n1836.pdf

Is that what you use as the current draft?  I see Bessel and Neumann
functions, just not of "arbitrary real order" -- is that your point?
I'm just trying to get up to speed on the project status.

The Bessel functions I was thinking of are in 5.2.1.8 through 5.2.1.11:

// [5.2.1.8] regular modified cylindrical Bessel functions:

double cyl_bessel_i(double nu, double x);

float cyl_bessel_if(float nu, float x);

long double cyl_bessel_il(long double nu, long double x);

// [5.2.1.9] cylindrical Bessel functions (of the first kind):

double cyl_bessel_j(double nu, double x);

float cyl_bessel_jf(float nu, float x);

long double cyl_bessel_jl(long double nu, long double x);

// [5.2.1.10] irregular modified cylindrical Bessel functions:

double cyl_bessel_k(double nu, double x);

float cyl_bessel_kf(float nu, float x);

long double cyl_bessel_kl(long double nu, long double x);

// [5.2.1.11] cylindrical Neumann functions;

// cylindrical Bessel functions (of the second kind):

double cyl_neumann(double nu, double x);

float cyl_neumannf(float nu, float x);

long double cyl_neumannl(long double nu, long double x);

This is a complication but OTOH, it makes the spherical Bessel functions trivial
because they are cylindrical bessel functions with nu = 1/2 times some crud.

Also, I was thinking that as a gnu extension we could provide
Airy functions which are linear combinations of Bessel functions of order 1/3.


I'll send what I have tomorrow after I make sure it doesn't crash.


OK. Great.




Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]