Repository navigation
Add shared RK4 solvers for scalar and vector ODE initial-value problems - #313
Draft
PawelTroka wants to merge 1 commit into
Draft
PawelTroka wants to merge 1 commit into
PawelTroka wants to merge 1 commit into
Conversation
This was referenced Oct 30, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Refs #45. Computator.NET has shared integration, differentiation and root-finding methods, but it does not expose an ordinary differential equation initial-value solver through TSL. For example, this scalar problem has the analytic answer
7, but currently fails compilation becauseDifferentialEquationis unknown:Change
Expose the existing, pinned Math.NET Numerics 5.0.0 classical fourth-order Runge–Kutta implementation through one shared
DifferentialEquationclass, with scalar and real-vector overloads:samplescounts stored states including both endpoints; default 101, accepted range 2–1,000,001. Descending intervals work. Equal bounds repeat the initial state without calling the derivative.ToCodealgorithm is introduced.This is a fixed-step initial-value method. Adaptive error control, stiff solvers, event detection, boundary-value solving and a dedicated desktop ODE panel remain outside this change. The guide explains convergence checks, floating-point limits and the dependence of memory/cost on system dimension and callback behavior.
Validation
Published Git tree
1bd9b590b5f37155973fa53344f0c9220e1d6f51exactly matches the validated local tree, based on masterfe1aba49b5f9538355ffaaa3d1683f69a23d2d9c.Fresh local runs used .NET SDK 10.0.403, Release, Linux x64:
OdeExecutionTestsregressions fail on the unchanged implementation withCS0103: The name 'DifferentialEquation' does not exist in the current context.--check: passes. All 1,220 existing article blocks are byte-identical; one article is added for two overloads. The local inventory combines the authenticated baseline Windows inventory with the new type's output from the production reflection/signature source, using a portable UI shell. Native catalogue coverage remains part of Windows CI.Computator.NET.Core.Testscross-build: succeeds with 0 errors, plus two existing unused-field warnings inToolStripRadioButtonMenuItem. It includes new tests for legacy/precompiled evaluator paths and production completion/reference attachment. Those native Windows tests have not been executed on Linux. Native Windows/Mono acceptance and the platform-specific Cake gate remain CI/reviewer checks.Commands used (with
dotnetresolved to SDK 10.0.403 and the local NuGet cache):Relationship to existing work
Open pull requests, GitHub issues and the current shared engine functionality were inspected before selecting this work. No existing open PR provides the ODE API requested by #45. This branch is independent of the concurrent charting/platform, parsing, secant, translation, special-function, integration-count and Euclidean-algorithm changes. It deliberately reuses the established Engine/TSL/reference architecture and leaves those implementations untouched.
Draft for owner review and native CI. No merge performed.
Combined compatibility check — 2026-10-30
Also tested the final contributions in #311, #313, #314 and #315 together with the seven existing maintenance PRs (#304–#310), using the existing #312 candidate
189d28c0ec7acbf77d380f14f95ef450e7bfbd84as the local integration base.Eight shared paths required composition resolutions. These preserved all Euclid/ODE/polynomial aliases, completion and authoring registrations; Debye/unitary documentation; and Find/Replace/printing methods, test-source links and documentation entries. No feature behavior or numerical algorithm needed changing to combine the contributions. The independently published PRs remain based on master.
Combined local tree:
63225a973ea2883974a91ab26afcdc83d866e77b, SDK 10.0.403, Linux x64. The reference check used the authenticated master inventory plus current production reflection for changed entries through a portable UI shell. Native Windows tests, full native catalog execution and printer acceptance remain pending. The existing #312 PR was not changed by this local verification.