GithubHelp home page GithubHelp logo

jholland1 / py_1d_heat Goto Github PK

View Code? Open in Web Editor NEW
3.0 2.0 2.0 39 KB

1D Heat Equation Model Problem for Field Inversion and Machine Learning Demonstration

License: GNU General Public License v3.0

Python 100.00%
fiml inversion adjoint adjoint-optimisation machine-learning machine-learning-algorithms

py_1d_heat's Introduction

py_1D_heat

1D Heat Equation Model Problem for Field Inversion and Machine Learning Demonstration

Python scripts used for the 1D heat equation model problem. Numerical methodology is detailed in my dissertation and other publications available on my researchgate page: https://www.researchgate.net/profile/Jonathan_Holland5


FI-Classic

Command to execute:
python heat.py

number of spatial points controled by "n" in script. This performs the field inversion portion. Truth equation solved in truth.py, the imperfect model and adjoint of imperfect model solved in model.py


FIML-Embedded

Command to execute:
python heat_backprop.py

Note that the gradient simply uses complex step differentiation (forward differentiation) so it is much more costly than the adjoint implementation in FI-Classic. This was needed because of the lack of robust autodiff tools for python. Some exist but have difficulty with numpy arrays. Therefore the forward differentiation was parallelized, and the number of processors used is controlled by nprocs variable in heat_backprop.py.


FIML-Direct

Command to execute:
python heat_nn.py

Adjoint is implemented in this application so runs just as efficiently as FI-Classic. Also note that a major advantage of FIML-Direct is that numerous cases (multiple Tinf) cases can be considered simultaneously in the a single inversion. This is demonstrated by defining Tinf as a vector. A "-1" executes the variable Tinf case.

py_1d_heat's People

Contributors

jholland1 avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

obidar gtc1030

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.