Numerical Methods or Calculus: integration, differentation, interpolation, etc #2676
Replies: 12 comments 14 replies
-
@spencerstith Euler method, Second-order Runge-Kutta methods |
Beta Was this translation helpful? Give feedback.
-
Hey Spencer, By interpolation I assume you mean something like I can imagine that ODE iterators like Euler and Runge-Kutta, which Madan mentions, would also be useful in math.js. But maybe after we have a solver for algebraic equations, so that we can make a consistent API? 🤔 Not sure about this, I'd love to hear your thoughts! Anyway, starting a new issue about a specific feature would be a great start. Then you (or anyone else) can propose an API and later follow up with a PR :) |
Beta Was this translation helpful? Give feedback.
-
@josdejong Any thoughts about this, Jos? |
Beta Was this translation helpful? Give feedback.
-
Yes, I would love to have numerical implementations to do integration, differentiation, etc 👍 . Thanks for bringing this up. Related: #227 |
Beta Was this translation helpful? Give feedback.
-
Could I take this issue? I can help to implement a Runge-Kutta or maybe some integration algorithms. |
Beta Was this translation helpful? Give feedback.
-
Sounds good, thanks for your offer @jjram20 👍 . Before you work out new functions in detail, please keep us up to date on what exactly you plan to implement and how, so we can discuss where needed. |
Beta Was this translation helpful? Give feedback.
-
I could start creating a new folder for numerical methods for calculus inside of /src/functions including a function for numerical integration using the trapezoidal rule, the function would include as parameters the functions that will be integrated as a string and it will be evaluated using the method evaluate of this library, the other parameters will be the limits of integration and the size of increments. The idea is to evaluate using for cycles. If I am not considering anything, am not being clear, or anything else please let me know. |
Beta Was this translation helpful? Give feedback.
-
Yes it makes sense to introduce a new category, "numerical" or "calculus" (what would be the best name?), and create a folder in |
Beta Was this translation helpful? Give feedback.
-
For now I would like to start including numerical differentiation (using the definition (f(x+h)-f(x))/h) and numerical integration using trapezoidal rule, and later the next step could be to add other algorithms as Runge-Kutta, but step by step, what do you think about it? |
Beta Was this translation helpful? Give feedback.
-
That sounds like a good and realistic plan (not too much at once). Do you have any preference for the name of the category? Ie. "numerical" or "calculus" or something else? |
Beta Was this translation helpful? Give feedback.
-
The name of the folder can be "numerical". |
Beta Was this translation helpful? Give feedback.
-
Yes I like that best too 👍 |
Beta Was this translation helpful? Give feedback.
-
I have been browsing this repo and noticed there doesn't seem to be any functionality for numerical methods for integration, derivatives, interpolation, etc. Is that needed in this repository? I would love to start on that unless it is beyond the scope of this library.
Beta Was this translation helpful? Give feedback.
All reactions