https://github.com/perpendicooler/computational_fluid_dynamics
Numerical Methods
https://github.com/perpendicooler/computational_fluid_dynamics
2-dimensional-heat boundary-element-method computational-fluid-dynamics diffusion-models finite-difference-method finite-element-methods finite-volume-methods fluid-dynamics heat-equation heat-transfer jupyter-notebook matplotlib numerical-methods numpy odeint odeivp python rk4 scipy
Last synced: about 2 months ago
JSON representation
Numerical Methods
- Host: GitHub
- URL: https://github.com/perpendicooler/computational_fluid_dynamics
- Owner: perpendicooler
- License: mit
- Created: 2023-11-25T19:58:41.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-12-15T21:10:09.000Z (over 1 year ago)
- Last Synced: 2025-01-23T14:30:52.444Z (3 months ago)
- Topics: 2-dimensional-heat, boundary-element-method, computational-fluid-dynamics, diffusion-models, finite-difference-method, finite-element-methods, finite-volume-methods, fluid-dynamics, heat-equation, heat-transfer, jupyter-notebook, matplotlib, numerical-methods, numpy, odeint, odeivp, python, rk4, scipy
- Language: Jupyter Notebook
- Homepage:
- Size: 1.64 MB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Solving CFD Problems with Python and Various Numerical Methods
![]()
![]()
![]()
![]()
# Overview
This project aims to solve Computational Fluid Dynamics (CFD) problems related to the heat equation, wave equation, and heat transfer using Python. Various numerical methods, including Finite Volume Method, Runge-Kutta 4 (RK4), Finite Difference Method, and Finite Element Method, have been implemented for accurate and efficient simulations.# Implemented Methods
## Heat Equation
The heat equation describes the distribution of heat over time within a given region. I utilized the Finite Difference Method to discretize the partial differential equation and simulate the evolution of temperature. The RK4 method was employed for time integration, providing a stable and accurate solution.$$
\frac{\partial C}{\partial t} = D \frac{\partial^2 C}{\partial x^2}
$$$$
\frac{\partial C}{\partial x} = 0
$$$$
\rho \frac{dv}{dt} - \mu \left(\frac{d^2 v}{dr^2} + \frac{1}{r}\frac{dv}{dr}\right) = -\nabla p
$$$$
\rho C_p \frac{\partial T}{\partial t} + \rho C_p \bar{v} \cdot \nabla T + \nabla \cdot \left(-k \nabla T\right) = Q
$$
1. Numerical Method: Finite Difference Method
2. Time Integration: Runge-Kutta 4 (RK4)
# Wave Equation
The wave equation models the propagation of waves through a medium. Using the Finite Difference Method for spatial discretization and RK4 for time integration, I simulated the behavior of waves, showcasing the importance of accurate numerical methods in capturing wave dynamics.
1. Numerical Method: Finite Difference Method
2. Time Integration: Runge-Kutta 4 (RK4)
#Heat Transfer
Heat transfer is a critical aspect of many engineering applications. Implementing the Finite Volume Method allowed me to simulate heat transfer scenarios efficiently. This method discretizes the domain into control volumes, providing a robust approach for solving complex heat transfer problems.
1. Numerical Method: Finite Volume Method
# Finite Element Method
1. Numerical Method: Finite Element Method##Contributions
Contributions are welcome! Feel free to submit issues or pull requests.##License
This project is licensed under the MIT License.