JuliaMath / JuliaMath/FixedPointNumbers.jl

Supplemental support for numerical and mathematical functions

Open
#185 1 comment 1 reaction 0 assignees View on GitHub
enhancement
Dominant language
Julia
Stars
95
Forks
38
Avg merge
13m
Merged PRs (30d)
2

Description

In response to #179, I checked the support status and performance of some other functions. The (incomplete) list is shown below.

## To be supported
- [ ] `^(::FixedPoint, ::Integer)` for more accuracy
- e.g. `N0f8(0.8)^3 != N0f8(64/125)`
- [x] `bitstring` (PR #195)
- [x] `big` (Issue #184, PR #186)
- [x] `clamp` (Issue #179, PR #194)
- [x] `copysign(x::Fixed, y)` and `flipsign(x::Fixed, y)` for speed performance (PR #187)
- [ ] `fma` and `muladd`
- [x] `rationalize` (Issue #184, PR #186)
- [x] 3-arg `rem` and `div` (`cld`) (PR #226, PR #230)
- [ ] `rem2pi` and `mod2pi`
- [x] `signbit` for speed performance (for `Normed`) (PR #187)

## To be dropped
- [x] `abs(::Normed)` specialization is not helpful. (PR #187)
- The fallback implementation works fine.
- [x] `copysign(x::Normed, y)` and `flipsign(x::Normed, y)` should be throw error. (PR #187)

## TBD
- `maxintfloat` (`maxintfixed` and `minintfixed`?)
- `parse` and `tryparse` for fixed point numbers with suffix
- bit shift operators (Issue #250)
- I think they are usuful but somewhat dangerous.
- `numerator` and `denominator`

- `widemul`

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.