From add909743b4cae9ef2dacf0c016d4abbb9d33499 Mon Sep 17 00:00:00 2001 From: Nicola Demo Date: Thu, 17 Feb 2022 12:29:01 +0100 Subject: [PATCH] Update README.md --- README.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 1cf69ac..d5ee953 100644 --- a/README.md +++ b/README.md @@ -37,9 +37,7 @@ * [Examples and Tutorials](#examples-and-tutorials) - -* [How to cite](#how-to-cite) - * [References](#references) +* [References](#references) * [Authors and contributors](#authors-and-contributors) * [How to contribute](#how-to-contribute) @@ -56,9 +54,10 @@ PINN is a novel approach that involves neural networks to solve supervised learn First step is formalization of the problem in the PINA framework. We take as example here a simple Poisson problem, but PINA is already able to deal with **multi-dimensional**, **parametric**, **time-dependent** problems. Consider:

- Poisson approximation + Poisson approximation

where *D* is a square domain, *Gamma*s are the boundaries and *u* the unknown field. The translation in PINA code becomes a new class containing all the information about the domain, about the `conditions` and nothing more: + ```python class Poisson(SpatialProblem): spatial_variables = ['x', 'y'] @@ -85,6 +84,7 @@ class Poisson(SpatialProblem): #### Problem solution After defining it, we want of course to solve such a problem. The only things we need is a `model`, in this case a feed forward network, and some samples of the domain and boundaries, here using a Cartesian grid. In these points we are going to evaluate the residuals, which is nothing but the loss of the network. + ```python poisson_problem = Poisson() @@ -100,9 +100,9 @@ pinn.train(1000, 100) plotter = Plotter() plotter.plot(pinn) ``` -After the training we can infer our model, save it or just plot the PINN approximation. +After the training we can infer our model, save it or just plot the PINN approximation. Below the graphical representation of the PINN approximation, the analytical solution of the problem and the absolute error, from left to right.

- Poisson approximation + Poisson approximation