neurodiffeq
is a package for solving differential equations with neural networks. Differential equations are equations that relate some function with its derivatives. They emerge in various scientific and engineering domains. Traditionally these problems can be solved by numerical methods (e.g. finite difference, finite element). While these methods are effective and adequate, their expressibility is limited by their function representation. It would be interesting if we can compute solutions for differential equations that are continuous and differentiable.
As universal function approximators, artificial neural networks have been shown to have the potential to solve ordinary differential equations (ODEs) and partial differential equations (PDEs) with certain initial/boundary conditions. The aim of neurodiffeq
is to implement these existing techniques of using ANN to solve differential equations in a way that allow the software to be flexible enough to work on a wide range of user-defined problems.
Like most standard libraries, neurodiffeq
is hosted on PyPI. To install the latest stable relesase, simply use the pip
(or pip3
) tool.
pip install neurodiffeq
# or try: pip3 install neurodiffeq
Alternatively, you can install the library manually to get early access to our new features. This is the recommended way for developers who want to contribute to the library.
-
(optional) Create a new environment. With
conda
:conda create --name [name of the new environment] python=3.7
and activate the enviroment byconda activate [name of the new environment]
; Withvenv
:python3 -m venv temp [path to the new environment]
and activate the environment bysource [path to the new environment]/bin/activate
-
Clone the repo by
git clone https://github.com/odegym/neurodiffeq.git
andcd
into the root directory of the repo bycd neurodiffeq
-
Install the dependencies by
pip install -r requirements.txt
and installneurodiffeq
bypip install .
-
(optional) Run tests
cd tests && pytest
-
(optional) Deactivate the environment. With
conda
:conda deactivate
; Withvenv
:deactivate
For basic use of neurodiffeq
, please check the documentation hosted on ReadTheDocs.
In case ReadTheDocs' service is down (which rarely happens), you can refer to our self-hosted documentation site as a backup option.
In addition to the documentations, we have recently made a quick walkthrough demo video, the slides can be found here
Thanks for your interest to contribute!
When contributing to this repository, we consider the following process:
-
Open an issue to discuss the change you are planning to make
-
Make the change on a forked repository and update the README.md if changes are made to the interface
-
Open a pull request