ReactOS 0.4.16-dev-2104-gb84fa49
jn_yn.c File Reference
#include <math.h>
#include <float.h>
#include "ieee754/ieee754.h"
Include dependency graph for jn_yn.c:

Go to the source code of this file.

Typedefs

typedef int fpclass_t
 

Functions

fpclass_t _fpclass (double __d)
 
int_errno (void)
 
double _jn (int n, double num)
 
double _yn (int order, double num)
 

Typedef Documentation

◆ fpclass_t

typedef int fpclass_t

Definition at line 5 of file jn_yn.c.

Function Documentation

◆ _errno()

int * _errno ( void  )

Definition at line 215 of file errno.c.

216{
217 return &msvcrt_get_thread_data()->thread_errno;
218}
thread_data_t *CDECL msvcrt_get_thread_data(void)
Definition: thread.c:45

Referenced by __wcserror_s(), _access_s(), _aligned_offset_malloc(), _aligned_offset_realloc(), _atoi_l(), _atol_l(), _beginthread(), _chdrive(), _chsize_s(), _close(), _cwait(), _dup2(), _fcvt_s(), _findnext(), _findnexti64(), _flsbuf(), _fsopen(), _ftime_s(), _fullpath(), _gcvt(), _gcvt_s(), _get_errno(), _get_osfhandle(), _get_osplatform(), _get_pgmptr(), _get_tzname(), _get_wpgmptr(), _getcwd(), _getdcwd(), _gmtime64_s(), _heapadd(), _i64toa_s(), _i64tow_s(), _localtime32_s(), _localtime64_s(), _locking(), _lseeki64(), _ltoa_s(), _ltow_s(), _makepath_s(), _mbccpy_s_l(), _mbsnbcat_s_l(), _mbstowcs_l(), _mbstrlen_l(), _mktemp_s(), _pclose(), _pipe(), _putenv_s(), _read(), _searchenv_s(), _set_errno(), _setmbcp(), _setmbcp_l(), _setmode(), _sopen_dispatch(), _splitpath_s(), _strdate_s(), _Strftime(), _strlwr_s_l(), _strnset_s(), _strtime_s(), _strtoi64_l(), _strtol_l(), _strtoui64_l(), _strtoul_l(), _strupr_s_l(), _strxfrm_l(), _tolower_l(), _toupper_l(), _tsearchenv_s(), _tstat64(), _ui64toa_s(), _ui64tow_s(), _ultoa_s(), _ultow_s(), _vscprintf_p_l(), _waccess_s(), _wasctime(), _wcslwr_s(), _wcslwr_s_l(), _wcsnset_s(), _wcsset_s(), _wcstod_l(), _wcstoi64_l(), _wcstol_l(), _wcstoui64_l(), _wcstoul_l(), _wcsupr_s_l(), _wcsxfrm_l(), _wctomb_s_l(), _wfindnext(), _wfindnext32(), _wfindnext64(), _wfindnext64i32(), _wfindnexti64(), _wfopen_s(), _wfreopen_s(), _wfullpath(), _wgetcwd(), _wgetdcwd(), _wmakepath_s(), _wmktemp_s(), _wputenv_s(), _write(), _wsearchenv_s(), _wsopen_dispatch(), _wsopen_s(), _wsplitpath_s(), _wstat64(), _wstrdate_s(), _wstrtime_s(), _wsystem(), _wtoi_l(), _wtol_l(), _yn(), alloc_pioinfo_block(), asctime(), asctime_buf(), calloc(), fopen_s(), freopen_s(), get_ioinfo_alloc(), heap_alloc_dbg(), heap_alloc_dbg_internal(), malloc(), math_error(), mbsrtowcs_s(), mktime_helper(), msvcrt_get_file(), msvcrt_init_fp(), msvcrt_set_errno(), msvcrt_spawn(), perror(), pf_printf(), rand_s(), read_i(), read_utf8(), run_open_osfhandle(), START_TEST(), strerror_s(), strftime_date(), strftime_helper(), strftime_impl(), strftime_int(), strftime_nstr(), strftime_str(), strftime_time(), strtod_helper(), Test_popen(), tmpnam_helper(), vfprintf_helper(), vfwprintf_helper(), vsprintf_p_l_opt(), vswprintf_p_l_opt(), wcsrtombs_l(), wcsrtombs_s_l(), wctomb(), win_iconv_open(), and wtmpnam_helper().

◆ _fpclass()

fpclass_t _fpclass ( double  __d)

Definition at line 595 of file math.c.

596{
597 union { double f; UINT64 i; } u = { num };
598 int e = u.i >> 52 & 0x7ff;
599 int s = u.i >> 63;
600
601 switch (e)
602 {
603 case 0:
604 if (u.i << 1) return s ? _FPCLASS_ND : _FPCLASS_PD;
605 return s ? _FPCLASS_NZ : _FPCLASS_PZ;
606 case 0x7ff:
607 if (u.i << 12) return ((u.i >> 51) & 1) ? _FPCLASS_QNAN : _FPCLASS_SNAN;
608 return s ? _FPCLASS_NINF : _FPCLASS_PINF;
609 default:
610 return s ? _FPCLASS_NN : _FPCLASS_PN;
611 }
612}
unsigned long long UINT64
#define _FPCLASS_PZ
Definition: float.h:113
#define _FPCLASS_PD
Definition: float.h:114
#define _FPCLASS_PN
Definition: float.h:115
#define _FPCLASS_ND
Definition: float.h:111
#define _FPCLASS_QNAN
Definition: float.h:108
#define _FPCLASS_NINF
Definition: float.h:109
#define _FPCLASS_NN
Definition: float.h:110
#define _FPCLASS_SNAN
Definition: float.h:107
#define _FPCLASS_NZ
Definition: float.h:112
#define _FPCLASS_PINF
Definition: float.h:116
GLdouble s
Definition: gl.h:2039
GLuint GLuint num
Definition: glext.h:9618
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble * u
Definition: glfuncs.h:240
#define e
Definition: ke_i.h:82
#define f
Definition: ke_i.h:83

Referenced by _yn().

◆ _jn()

double _jn ( int  n,
double  num 
)

Definition at line 12 of file jn_yn.c.

13{
14 /* FIXME: errno handling */
15 return __ieee754_jn(n, num);
16}
GLdouble n
Definition: glext.h:7729
double __ieee754_jn(int, double)
Definition: jn_yn.c:64

Referenced by jn().

◆ _yn()

double _yn ( int  order,
double  num 
)

Definition at line 21 of file jn_yn.c.

22{
23 double retval;
24 if (!_finite(num)) *_errno() = EDOM;
27 {
28 *_errno() = EDOM;
29 retval = sqrt(-1);
30 }
31 return retval;
32}
#define EDOM
Definition: errno.h:54
_ACRTIMP int __cdecl _finite(double)
Definition: math.c:1582
_ACRTIMP double __cdecl sqrt(double)
Definition: sqrt.c:5
GLuint GLdouble GLdouble GLint GLint order
Definition: glext.h:11194
double __ieee754_yn(int, double)
Definition: jn_yn.c:227
fpclass_t _fpclass(double __d)
Definition: math.c:595
int * _errno(void)
Definition: errno.c:215
int retval
Definition: wcstombs.cpp:91

Referenced by yn().