Skip to content

m4YnK-7/Numerical_Analysis_PINN_Approach

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Numerical Analysis of Kuramoto-Sakaguchi type Non-Local equations: A PINN Approach

  • Explicit Finite Volume Numerical Analysis Scheme

trspt_disc burg_sin id_pol ni_pol

  • Physics-Informed Neural Network

id_pol_nn

Dependencies: -

  1. Python
  2. C++
  3. matplotlib
  4. NumPy
  5. SciP
  6. PyTorch and related libraries
  7. Jupyter

(All shell commands are for a windows environment)

git clone https://github.com/nishantak/numerical_sim_PINN.git
cd numerical_sim_PINN
pip install -r requirements.txt

Transport_Burgers C++ Code

FV_sim.h and FV_sim.cpp constitute A CUSTOM NUMERICAL ANALYSIS LIBRARY that contains all the functions and scheme implementations. simulate.cpp contains all simulation parameters and the flux definition (f(u)).

cd cpp_Transport_Burgers
g++ simulate.cpp FV_sim.cpp -o simulate && ./simulate

Kuramoto Python Code

In their respective directory, scheme.py is the module that contains the respective numerical analysis scheme implementation. functions.py is the module that contains functionality functions. config.py contains all simulation parameters and the flux definition (f(u)). Set problem equation and simulation parameters in the config.py and kuramoto_main.py file

cd python_Kuramoto
python kuramoto_main.py

PINN Kuramoto

Trains a Physics Informed Neural Network with: -

  • 4 hidden layers
  • 64 units each
  • tanh activation

Predicts u(x). Check experiments and implementation in the Notebook


Numerical Simulation

The core concept of a Numerical Simulation is to Simulate a differential equation.

Differential equation, in it's essence, describes "change", or in more physics terms- "evolution".

So, the differential equation describes- "How a physical quantity evolves or changes with respect to other physical quantities, such as time or space."

Now, one easy way to find the value of this change would be to have the solution to the equation, right?. Just have the solution -> plug in the value of the parameters -> and get the value of the change for those parameters.

A solution would mean something like a formula such as "x = something"; where x is the change.

But, in real life we do not have such known solutions for every differential equation!

Hence, what do we do? We find the value of change from the differential equation itself. We calculate the equation via the computer (because doing so manually would be too tedious). And for small changes in the parameters, such as dx or dt, we plug in those values in our "scheme" and get the value of the change.

"Scheme" means how we are simulating the differential equation. We have implemented a Finite Volume Scheme, which is a type of scheme used for Numerical Analysis.

The graphs you may see in the README are representing the value of change, how the change evolves, how the physical quantity evolves w.r.t. the parameters which may be time or space.

About

Solving PDEs using Numerical Analysis and PINN

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors