Skip to content

[RFC]: Add C implementations to base special math functions (tracking issue) #649

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
kgryte opened this issue Dec 2, 2022 · 29 comments · Fixed by #3058, #3061, #3072 or #3076 · May be fixed by #3377
Open

[RFC]: Add C implementations to base special math functions (tracking issue) #649

kgryte opened this issue Dec 2, 2022 · 29 comments · Fixed by #3058, #3061, #3072 or #3076 · May be fixed by #3377
Labels
Accepted RFC feature request which has been accepted. difficulty: 3 Likely to be challenging but manageable. Enhancement Issue or pull request for enhancing existing functionality. Math Issue or pull request specific to math functionality. Native Addons Issue involves or relates to Node.js native add-ons. priority: High High priority concern or feature request. RFC Request for comments. Feature requests and proposed changes. Tracking Issue Tracking issue.

Comments

@kgryte
Copy link
Member

kgryte commented Dec 2, 2022

Description

This RFC proposes adding C implementations to all base special math functions. The purpose of this issue is to serve as a tracking issue for adding C implementations.

Packages

  • abs
  • abs2
  • abs2f
  • absf
  • acos
  • acosf
  • acosd
  • acosdf
  • acosh
  • acoshf
  • acot
  • acotf
  • acotd
  • acotdf
  • acoth
  • acothf
  • acovercos
  • acovercosf
  • acoversin
  • acoversinf
  • acsc
  • acscf
  • acscd
  • acscdf
  • acsch
  • acschf
  • ahavercos
  • ahavercosf
  • ahaversin
  • ahaversinf
  • asec
  • asecf
  • asecd
  • asecdf
  • asech
  • asechf
  • asin
  • asinf
  • asind
  • asindf
  • asinf
  • asinh
  • asinhf
  • atan
  • atanf
  • atan2
  • atan2f
  • atand
  • atandf
  • atanh
  • atanhf
  • avercos
  • avercosf
  • aversin
  • aversinf
  • bernoulli
  • bernoullif
  • besselj0
  • besselj0f
  • besselj1
  • besselj1f
  • bessely0
  • bessely0f
  • bessely1
  • bessely1f
  • beta
  • betaf
  • betainc
  • betaincf
  • betaincinv
  • betaincinvf
  • betaln
  • betalnf
  • binet
  • binetf
  • binomcoef
  • binomcoeff
  • binomcoefln
  • binomcoeflnf
  • boxcox
  • boxcoxf
  • boxcox1p
  • boxcox1pf
  • boxcox1pinv
  • boxcox1pinvf
  • boxcoxinv
  • boxcoxinvf
  • cabs
  • cabs2
  • cabs2f
  • cabsf
  • cbrt
  • cbrtf
  • cceil
  • cceilf
  • cceiln
  • cceilnf
  • ccis
  • ccisf
  • ceil
  • ceil10
  • ceil10f
  • ceil2
  • ceil2f
  • ceilb
  • ceilbf
  • ceilf
  • ceiln
  • ceilnf
  • ceilsd
  • ceilsdf
  • cexp
  • cexpf
  • cflipsign
  • cflipsignf
  • cfloor
  • cfloorf
  • cfloorn
  • cfloornf
  • cidentity
  • cidentityf
  • cinv
  • cinvf
  • clamp
  • clampf
  • copysign
  • copysignf
  • cos
  • cosf
  • cosd
  • cosdf
  • cosh
  • coshf
  • cosm1
  • cosm1f
  • cospi
  • cospif
  • cot
  • cotf
  • cotd
  • cotdf
  • coth
  • cothf
  • covercos
  • covercosf
  • coversin
  • coversinf
  • cphase
  • cphasef
  • cpolar
  • cpolarf
  • cround
  • croundf
  • croundn
  • croundnf
  • csc
  • cscf
  • cscd
  • cscdf
  • csch
  • cschf
  • csignum
  • csignumf
  • deg2rad
  • deg2radf
  • digamma
  • digammaf
  • dirac-delta
  • dirac-deltaf
  • dirichlet-eta
  • dirichlet-etaf
  • ellipe
  • ellipef
  • ellipj
  • ellipjf
  • ellipk
  • ellipkf
  • erf
  • erff
  • erfc
  • erfcf
  • erfcinv
  • erfcinvf
  • erfcx
  • erfcxf
  • erfinv
  • erfinvf
  • exp
  • expf
  • exp10
  • exp10f
  • exp2
  • exp2f
  • expit
  • expitf
  • expm1
  • expm1f
  • expm1rel
  • expm1relf
  • factorial
  • factorialf
  • factorial2
  • factorial2f
  • factorialln
  • factoriallnf
  • falling-factorial
  • falling-factorialf
  • fast/*
  • fibonacci
  • fibonaccif
  • fibonacci-index
  • fibonacci-indexf
  • flipsign
  • flipsignf
  • floor
  • floor10
  • floor10f
  • floor2
  • floor2f
  • floorb
  • floorbf
  • floorf
  • floorn
  • floornf
  • floorsd
  • floorsdf
  • fmod
  • fmodf
  • fresnel
  • fresnelf
  • fresnelc
  • fresnelcf
  • fresnels
  • fresnelsf
  • frexp
  • frexpf
  • gamma
  • gammaf
  • gamma-delta-ratio
  • gamma-delta-ratiof
  • gamma-lanczos-sum
  • gamma-lanczos-sumf
  • gamma-lanczos-sum-expg-scaled
  • gamma-lanczos-sum-expg-scaledf
  • gamma1pm1
  • gamma1pm1f
  • gammainc
  • gammaincf
  • gammaincinv
  • gammaincinvf
  • gammaln
  • gammalnf
  • gammasgn
  • gammasgnf
  • gcd
  • gcdf
  • hacovercos
  • hacovercosf
  • hacoversin
  • hacoversinf
  • havercos
  • havercosf
  • haversin
  • haversinf
  • heaviside
  • heavisidef
  • hypot
  • hypotf
  • identity
  • identityf
  • inv
  • invf
  • kernel-betainc
  • kernel-betaincf
  • kernel-betaincinv
  • kernel-betaincinvf
  • kernel-cos
  • kernel-cosf
  • kernel-sin
  • kernel-sinf
  • kernel-tan
  • kernel-tanf
  • kronecker-delta
  • kronecker-deltaf
  • labs
  • lcm
  • lcmf
  • ldexp
  • ldexpf
  • ln
  • lnf
  • log
  • logf
  • log10
  • log10f
  • log1mexp
  • log1mexpf
  • log1p
  • log1pf
  • log1pexp
  • log1pexpf
  • log1pmx
  • log1pmxf
  • log2
  • log2f
  • logaddexp
  • logaddexpf
  • logit
  • logitf
  • lucas
  • lucasf
  • max
  • maxf
  • maxabs
  • maxabsf
  • maxabsn
  • maxn
  • min
  • minf
  • minabs
  • minabsf
  • minabsn
  • minmax
  • minmaxf
  • minmaxabs
  • minmaxabsf
  • minmaxabsn
  • minmaxn
  • minn
  • modf
  • modff
  • nanmax
  • nanmaxf
  • nanmin
  • nanminf
  • negafibonacci
  • negafibonaccif
  • negalucas
  • negalucasf
  • nonfibonacci
  • nonfibonaccif
  • pdiff
  • pdifff
  • polygamma
  • polygammaf
  • pow
  • powf
  • powm1
  • powm1f
  • rad2deg
  • rad2degf
  • ramp
  • rampf
  • rcbrt
  • rcbrtf
  • rempio2
  • rempio2f
  • riemann-zeta
  • riemann-zetaf
  • rising-factorial
  • rising-factorialf
  • round
  • roundf
  • round10
  • round10f
  • round2
  • round2f
  • roundb
  • roundbf
  • roundn
  • roundnf
  • roundsd
  • roundsdf
  • rsqrt
  • rsqrtf
  • sec
  • secd
  • secdf
  • secf
  • sici
  • sicif
  • signum
  • signumf
  • sin
  • sinf
  • sinc
  • sincf
  • sincos
  • sincosd
  • sincosdf
  • sincosf
  • sincospi
  • sincospif
  • sinh
  • sinhf
  • sinpi
  • sinpif
  • spence
  • spencef
  • sqrt
  • sqrt1pm1
  • sqrt1pm1f
  • sqrtf
  • sqrtpi
  • sqrtpif
  • tan
  • tanf
  • tand
  • tandf
  • tanh
  • tanhf
  • tribonacci
  • tribonaccif
  • trigamma
  • trigammaf
  • trunc
  • trunc10
  • trunc10f
  • trunc2
  • trunc2f
  • truncb
  • truncbf
  • truncf
  • truncn
  • truncnf
  • truncsd
  • truncsdf
  • vercos
  • vercosf
  • versin
  • versinf
  • wrap
  • wrapf
  • xlog1py
  • xlog1pyf
  • xlogy
  • xlogyf

Related Issues

None.

Questions

No.

Other

No.

Checklist

  • I have read and understood the Code of Conduct.
  • Searched for existing issues and pull requests.
  • The issue name begins with RFC:.
@kgryte kgryte added RFC Request for comments. Feature requests and proposed changes. Feature Issue or pull request for adding a new feature. Math Issue or pull request specific to math functionality. Native Addons Issue involves or relates to Node.js native add-ons. Enhancement Issue or pull request for enhancing existing functionality. and removed Feature Issue or pull request for adding a new feature. labels Dec 2, 2022
@kgryte kgryte added difficulty: 3 Likely to be challenging but manageable. Accepted RFC feature request which has been accepted. priority: High High priority concern or feature request. labels Feb 25, 2024
@Pratik772846
Copy link
Contributor

@kgryte I would like to work on this.

@kgryte
Copy link
Member Author

kgryte commented Mar 6, 2024

@Pratik772846 I suggest picking one of the associated RFCs for updating a single package. This is a tracking issue.

@kgryte
Copy link
Member Author

kgryte commented Mar 6, 2024

@Pranavchiku As you've been managing a number of the RFCs and PRs, would you mind updating the OP to match the current state of implementations?

Planeshifter pushed a commit that referenced this issue May 18, 2025

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
PR-URL: #7000
Ref: #649

Co-authored-by: stdlib-bot <82920195+stdlib-bot@users.noreply.github.com>
Reviewed-by: Gunj Joshi <gunjjoshi8372@gmail.com>
Reviewed-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Philipp Burckhardt <pburckhardt@outlook.com>
Planeshifter pushed a commit that referenced this issue May 18, 2025
PR-URL: #7022
Ref: #649

Co-authored-by: stdlib-bot <82920195+stdlib-bot@users.noreply.github.com>
Reviewed-by: Philipp Burckhardt <pburckhardt@outlook.com>
Planeshifter pushed a commit that referenced this issue May 18, 2025
PR-URL: #4939
Ref: #649

Signed-off-by: Gururaj Gurram <143020143+gururaj1512@users.noreply.github.com>
Co-authored-by: stdlib-bot <82920195+stdlib-bot@users.noreply.github.com>
Co-authored-by: Karan Anand <anandkarancompsci@gmail.com>
Reviewed-by: Shabareesh Shetty <139731143+ShabiShett07@users.noreply.github.com>
Reviewed-by: Karan Anand <119553199+anandkaranubc@users.noreply.github.com>
Planeshifter pushed a commit that referenced this issue May 19, 2025
PR-URL: #6296
Closes: #2106
Ref: #649

Co-authored-by: Karan Anand <anandkarancompsci@gmail.com>
Reviewed-by: Karan Anand <anandkarancompsci@gmail.com>
Reviewed-by: Philipp Burckhardt <pburckhardt@outlook.com>
Reviewed-by: Gunj Joshi <gunjjoshi8372@gmail.com>
Signed-off-by: Karan Anand <119553199+anandkaranubc@users.noreply.github.com>
kgryte pushed a commit that referenced this issue Jun 1, 2025
PR-URL: #4396
Ref: #649
Reviewed-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Karan Anand <anandkarancompsci@gmail.com>
Reviewed-by: Gunj Joshi <gunjjoshi8372@gmail.com>
Co-authored-by: stdlib-bot <noreply@stdlib.io>
Co-authored-by: Gunj Joshi <gunjjoshi8372@gmail.com>
Co-authored-by: Karan Anand <anandkarancompsci@gmail.com>
kgryte added a commit that referenced this issue Jun 1, 2025
PR-URL: #6736
Ref: #649
Co-authored-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Philipp Burckhardt <pburckhardt@outlook.com>
Planeshifter pushed a commit that referenced this issue Jun 1, 2025
PR-URL: #7081
Ref: #649

Co-authored-by: stdlib-bot <noreply@stdlib.io>
Reviewed-by: Philipp Burckhardt <pburckhardt@outlook.com>
kgryte added a commit that referenced this issue Jun 2, 2025
PR-URL: #3055
Ref: #649
Co-authored-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Athan Reines <kgryte@gmail.com> 
Reviewed-by: Karan Anand <anandkarancompsci@gmail.com>
Reviewed-by: Gunj Joshi <gunjjoshi8372@gmail.com>
Co-authored-by: stdlib-bot <noreply@stdlib.io>
Co-authored-by: Karan Anand <anandkarancompsci@gmail.com>
anandkaranubc added a commit to anandkaranubc/stdlib that referenced this issue Jun 3, 2025
PR-URL: stdlib-js#3055
Ref: stdlib-js#649
Co-authored-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Athan Reines <kgryte@gmail.com> 
Reviewed-by: Karan Anand <anandkarancompsci@gmail.com>
Reviewed-by: Gunj Joshi <gunjjoshi8372@gmail.com>
Co-authored-by: stdlib-bot <noreply@stdlib.io>
Co-authored-by: Karan Anand <anandkarancompsci@gmail.com>
Planeshifter pushed a commit that referenced this issue Jun 3, 2025
PR-URL: #6142
Ref: #649

Co-authored-by: stdlib-bot <noreply@stdlib.io>
Reviewed-by: Philipp Burckhardt <pburckhardt@outlook.com>
Reviewed-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Dhruvil Mehta <68022411+dhruvilmehta@users.noreply.github.com>
Planeshifter pushed a commit that referenced this issue Jun 4, 2025
PR-URL: #6191
Ref: #649

Co-authored-by: Karan Anand <anandkarancompsci@gmail.com>
Co-authored-by: stdlib-bot <noreply@stdlib.io>
Reviewed-by:  Karan Anand <anandkarancompsci@gmail.com>
Reviewed-by: Philipp Burckhardt <pburckhardt@outlook.com>
Signed-off-by: Karan Anand <119553199+anandkaranubc@users.noreply.github.com>
Planeshifter pushed a commit that referenced this issue Jun 4, 2025
PR-URL: #7201
Ref: #649

Reviewed-by: Philipp Burckhardt <pburckhardt@outlook.com>
Signed-off-by: Karan Anand <119553199+anandkaranubc@users.noreply.github.com>
kgryte added a commit that referenced this issue Jun 5, 2025
PR-URL: #6066
Ref: #649
Co-authored-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Athan Reines <kgryte@gmail.com> 
Co-authored-by: stdlib-bot <noreply@stdlib.io>
Co-authored-by: Karan Anand <anandkarancompsci@gmail.com>
Reviewed-by: Gunj Joshi <gunjjoshi8372@gmail.com>
Reviewed-by: Karan Anand <anandkarancompsci@gmail.com>
kgryte added a commit that referenced this issue Jun 6, 2025
PR-URL: #7007
Ref: #649
Co-authored-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Athan Reines <kgryte@gmail.com> 
Co-authored-by: stdlib-bot <noreply@stdlib.io>
kgryte added a commit that referenced this issue Jun 7, 2025
PR-URL: #7048
Ref: #649
Co-authored-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Athan Reines <kgryte@gmail.com> 
Reviewed-by: Philipp Burckhardt <pburckhardt@outlook.com>
Co-authored-by: stdlib-bot <noreply@stdlib.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Accepted RFC feature request which has been accepted. difficulty: 3 Likely to be challenging but manageable. Enhancement Issue or pull request for enhancing existing functionality. Math Issue or pull request specific to math functionality. Native Addons Issue involves or relates to Node.js native add-ons. priority: High High priority concern or feature request. RFC Request for comments. Feature requests and proposed changes. Tracking Issue Tracking issue.
Projects
None yet
9 participants