NAME

PDL::Math - extended mathematical operations for PDL


SYNOPSIS

 use PDL::Math;

 use PDL::Graphics::TriD;
 imag3d [SURF2D,bessj0(rvals(zeroes(50,50))/2)];


DESCRIPTION

This module extends PDL with more advanced mathematical functions than provided and standard Perl.

Note all the functions have one input pdl, and one output, unless otherwise stated.

The functions are usually available from the system maths library, however if they are not (determined when PDL is compiled) a version from the Cephes math library is used.


FUNCTIONS


acos

  Signature: (a(); [o]b())

Complete the standard trigonometric functions.


asin

  Signature: (a(); [o]b())

Complete the standard trigonometric functions.


atan

  Signature: (a(); [o]b())

Complete the standard trigonometric functions.


cosh

  Signature: (a(); [o]b())

The standard hyperbolic functions.


sinh

  Signature: (a(); [o]b())

The standard hyperbolic functions.


tan

  Signature: (a(); [o]b())

Complete the standard trigonometric functions.


tanh

  Signature: (a(); [o]b())

The standard hyperbolic functions.


ceil

  Signature: (a(); [o]b())

Round to integral values in floating-point format


floor

  Signature: (a(); [o]b())

Round to integral values in floating-point format


rint

  Signature: (a(); [o]b())

Round to integral values in floating-point format


pow

  Signature: (a(); b(); [o]c())

Synonym for `**'


acosh

  Signature: (a(); [o]b())

The standard hyperbolic functions.


asinh

  Signature: (a(); [o]b())

The standard hyperbolic functions.


atanh

  Signature: (a(); [o]b())

The standard hyperbolic functions.


erf

  Signature: (a(); [o]b())

The error function


erfc

  Signature: (a(); [o]b())

The complement of the error function


bessj0

  Signature: (a(); [o]b())

Standard Bessel Functions


bessj1

  Signature: (a(); [o]b())

Standard Bessel Functions


bessy0

  Signature: (a(); [o]b())

Standard Bessel Functions


bessy1

  Signature: (a(); [o]b())

Standard Bessel Functions


bessjn

  Signature: (a(); int n(); [o]b())

Standard Bessel Functions


bessyn

  Signature: (a(); int n(); [o]b())

Standard Bessel Functions


lgamma

  Signature: (a(); [o]b(); int[o]s())

log gamma function

This returns 2 piddles -- the first set gives the log(gamma) values, while the second set, of integer values, gives the sign of the gamma function. This is useful for determining factorials, amongst other things.


badmask

  Signature: (a(); b(); [o]c())

Clears all infs and nans in a to the corresponding value in b


erfi

  Signature: (a(); [o]b())

The inverse of the error function


eigens

  Signature: ([phys]a(m); [o,phys]ev(n,n); [o,phys]e(n))

Eigenvalues and -vectors of a matrix in lower triangular form

XXX Hard interface


simq

  Signature: ([phys]a(n,n); [phys]b(n); [o,phys]x(n); int [o,phys]ips(n); int flag)

Solution of simultaneous linear equations.

(XXX hard interface)


squaretotri

  Signature: (a(n,n); b(m))

Convert a symmetric square matrix to triangular vector storage


BUGS

Hasn't been tested on all platforms to ensure Cephes versions are picked up automatically and used correctly.


AUTHOR

Copyright (C) R.J.R. Williams 1997 (rjrw@ast.leeds.ac.uk), Karl Glazebrook (kgb@aaoepp.aao.gov.au) and Tuomas J. Lukka (Tuomas.Lukka@helsinki.fi).

All rights reserved. There is no warranty. You are allowed to redistribute this software / documentation under certain conditions. For details, see the file COPYING in the PDL distribution. If this file is separated from the PDL distribution, the copyright notice should be included in the file.