]> git.ipfire.org Git - thirdparty/man-pages.git/blob - man3/j0.3
accept.2, execve.2, futimesat.2, getresuid.2, getrlimit.2, madvise.2, mq_getsetattr...
[thirdparty/man-pages.git] / man3 / j0.3
1 .\" Copyright 1993 David Metcalfe (david@prism.demon.co.uk)
2 .\" and Copyright 2008, Linux Foundation, written by Michael Kerrisk
3 .\" <mtk.manpages@gmail.com>
4 .\"
5 .\" Permission is granted to make and distribute verbatim copies of this
6 .\" manual provided the copyright notice and this permission notice are
7 .\" preserved on all copies.
8 .\"
9 .\" Permission is granted to copy and distribute modified versions of this
10 .\" manual under the conditions for verbatim copying, provided that the
11 .\" entire resulting derived work is distributed under the terms of a
12 .\" permission notice identical to this one.
13 .\"
14 .\" Since the Linux kernel and libraries are constantly changing, this
15 .\" manual page may be incorrect or out-of-date. The author(s) assume no
16 .\" responsibility for errors or omissions, or for damages resulting from
17 .\" the use of the information contained herein. The author(s) may not
18 .\" have taken the same level of care in the production of this manual,
19 .\" which is licensed free of charge, as they might when working
20 .\" professionally.
21 .\"
22 .\" Formatted or processed versions of this manual, if unaccompanied by
23 .\" the source, must acknowledge the copyright and authors of this work.
24 .\"
25 .\" References consulted:
26 .\" Linux libc source code
27 .\" Lewine's _POSIX Programmer's Guide_ (O'Reilly & Associates, 1991)
28 .\" 386BSD man pages
29 .\" Modified Sat Jul 24 19:08:17 1993 by Rik Faith (faith@cs.unc.edu)
30 .\" Modified 2002-08-25, aeb
31 .\" Modified 2004-11-12 as per suggestion by Fabian Kreutz/AEB
32 .\" 2008-07-24, mtk, moved yxx() material into separate y0.3 page
33 .\"
34 .TH J0 3 2008-08-05 "" "Linux Programmer's Manual"
35 .SH NAME
36 j0, j0f, j0l, j1, j1f, j1l, jn, jnf, jnl \-
37 Bessel functions of the first kind
38 .SH SYNOPSIS
39 .nf
40 .B #include <math.h>
41 .sp
42 .fi
43 .BI "double j0(double " x );
44 .br
45 .BI "double j1(double " x );
46 .br
47 .BI "double jn(int " n ", double " x );
48 .sp
49 .BI "float j0f(float " x );
50 .br
51 .BI "float j1f(float " x );
52 .br
53 .BI "float jnf(int " n ", float " x );
54 .sp
55 .BI "long double j0l(long double " x );
56 .br
57 .BI "long double j1l(long double " x );
58 .br
59 .BI "long double jnl(int " n ", long double " x );
60 .sp
61 Link with \fI\-lm\fP.
62 .sp
63 .in -4n
64 Feature Test Macro Requirements for glibc (see
65 .BR feature_test_macros (7)):
66 .in
67 .sp
68 .ad l
69 .BR j0 (),
70 .BR j1 (),
71 .BR jn ():
72 _SVID_SOURCE || _BSD_SOURCE || _XOPEN_SOURCE
73 .br
74 .BR j0f (),
75 .BR j0l (),
76 .BR j1f (),
77 .BR j1l (),
78 .BR jnf (),
79 .BR jnl ():
80 _SVID_SOURCE || _BSD_SOURCE || _XOPEN_SOURCE\ >=\ 600
81 .\" Also seems to work: -std=c99 -D_XOPEN_SOURCE
82 .ad b
83 .SH DESCRIPTION
84 The
85 .BR j0 ()
86 and
87 .BR j1 ()
88 functions return Bessel functions of \fIx\fP
89 of the first kind of orders 0 and 1, respectively.
90 The
91 .BR jn ()
92 function
93 returns the Bessel function of \fIx\fP of the first kind of order \fIn\fP.
94 .PP
95 The
96 .BR j0f ()
97 etc. and
98 .BR j0l ()
99 etc. functions are versions that take and return
100 .I float
101 and
102 .I "long double"
103 values, respectively.
104 .SH RETURN VALUE
105 On success, these functions return the appropriate
106 Bessel value of the first kind for
107 .IR x .
108
109 If
110 .I x
111 is a NaN, a NaN is returned.
112
113 If
114 .I x
115 is too large in magnitude,
116 or the result underflows,
117 a range error occurs,
118 and the return value is 0.
119 .SH ERRORS
120 See
121 .BR math_error (7)
122 for information on how to determine whether an error has occurred
123 when calling these functions.
124 .PP
125 The following errors can occur:
126 .TP
127 Range error: result underflow, or \fIx\fP is too large in magnitude
128 .I errno
129 is set to
130 .BR ERANGE .
131 .\" An underflow floating-point exception
132 .\" .RB ( FE_UNDERFLOW )
133 .\" is raised.
134 .PP
135 These functions do not raise exceptions for
136 .BR fetestexcept (3).
137 .\" FIXME . Is it intentional that these functions do not raise exceptions?
138 .\" e.g., j0(1.5e16)
139 .\" Bug raised: http://sources.redhat.com/bugzilla/show_bug.cgi?id=6805
140 .SH "CONFORMING TO"
141 The functions returning
142 .I double
143 conform to SVr4, 4.3BSD,
144 POSIX.1-2001.
145 The others are nonstandard functions that also exist on the BSDs.
146 .SH BUGS
147 There are errors of up to 2e\-16 in the values returned by
148 .BR j0 (),
149 .BR j1 ()
150 and
151 .BR jn ()
152 for values of \fIx\fP between \-8 and 8.
153 .SH SEE ALSO
154 .BR y0 (3)