Code Monkey home page Code Monkey logo

pde-viz's Introduction

Visualization for Partial Differential Equations

I made this repository to practice using Julia for solving and visualizing partial differential equations. Right now there is only code for solving the heat equation and wave equation in 1D with Dirichlet boundary conditions.

After getting your Julia environment set up, run

julia --project=. main.jl

to reproduce the plots.

Heat Equation

Case 1

Uniform 0 initial conditions, with both ends of the rod held at 1.

uₜ = uₓₓ

u(0, t) = u(10, t) = 1

u(x, 0) = 0

Case 1

Case 2

The initial condition is 1 everywhere, with the boundaries set to 0.

uₜ = uₓₓ

u(0, t) = u(10, t) = 0

u(x, 0) = 1

Case 2

Case 3

0 initial condition, with one boundary condition at zero and the other at 1.

uₜ = uₓₓ

u(0, t) = 0

u(10, t) = 1

u(x, 0) = 0

Case 3

Wave Equation

Case 1

Standing sine wave.

uₜₜ = uₓₓ

u(0, t) = u(10, t) = 0

u(x, 0) = sin(π x / 5)

uₓ(x, 0) = 0

Case 1

Case 2

uₜₜ = 4 uₓₓ

u(0, t) = u(1, t) = 0

uₓ(x, 0) = -x

u(x, 0) = x

Case 2

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.