Closed
Description
Description
This RFC proposes adding native C implementation for @stdlib/math/base/special/fibonacci-index
.
double stdlib_base_fibonacci_index( const double F );
Related Issues
Tracked in issue #649.
Questions
I am not sure about the method's signature. In the original JavaScript code, both the return type and the parameter are {NonNegativeInteger}. However, in some tests they take on the value NaN, which as far as I know does not exist for integer types in C. For this reason, I decided on using double, but please tell me if there is a more suitable solution.
Other
The implementation depends on the round
function, which is addressed in #735. I can use the round method from C until the method is implemented in stdlib, and I can also contribute to implementing round
.
Checklist
- I have read and understood the Code of Conduct.
- Searched for existing issues and pull requests.
- The issue name begins with
RFC:
.
Metadata
Metadata
Assignees
Labels
RFC feature request which has been accepted.Issue involves or relates to C.Issue or pull request for adding a new feature.A good first issue for new contributors!Issue or pull request specific to math functionality.Request for comments. Feature requests and proposed changes.May require some initial design or R&D, but should be straightforward to resolve and/or implement.Normal priority concern or feature request.