Code Monkey home page Code Monkey logo

odeint's Introduction

odeint Build Status

Description

Go package with ordinary differential equations solvers for initial value problems to be solved by explicit methods. The package features methods for float32 float64 complex64 and complex128 types. The methods implemented so far are,

  • Euler
  • Mid point
  • Runge-Kutta 4

The package is easily extensible to provide other methods.

The docs,

The API is pretty consistent, and you'll get it easily,

Type specific docs,

Usage

Import the type you intend to use. For the recommended float64 just type

import "github.com/Daniel-M/odeint/float64"   

and you are ready to use methods. The stepper used (euler, mid point or Runge-Kutta-4) can be changed easily.

To get a feeling of the usage check the files under examples/brusselator. You will see that to change the method used you just need to change the integrator used (line 38 of examples/brusselator/rk4 source code).

FAQ

A subpackage for each numeric type?

You might be thinking, why does this guy have a subpackage for each numeric type? Well, though it makes the package harder to maintain, having type specific integrators is a priority for me. I could have used interface-based integrators but it would be at the expense of the extensibility of the integrators to more custom numerical types, a feature which I find relevant too.

TEST

You can run all tests with

go test -v ./...   

or individual type oriented tests as

go test -v ./float64 # For float64 type   

To Do

  • Support higher order methods.
  • Implement adaptative step methods.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.