Finite difference method Definition and 50 Threads

  1. T

    Engineering Multi-point Boundary Value Problems Using Finite Difference Method

    Hi all, I am learning how to solve differential equtions using the finite diference method. In particular, for beams under a uniformly distributed load. For a simply supported beam this is quite easy. The boundary conditions are that at each end the displacement equal zero, and using the fourth...
  2. person123

    Python My Python Library For Finite Difference Method

    I recently made a Python library for modelling (very basic) finite difference problems. The Github readme goes into details of what it does and how it works, and I put together a Google Colab with some examples (diffusion, advection, water wave refraction) with interactive visuals. I'd love to...
  3. yashabyadav

    A Need help implementing finite difference method for BPM

    I am trying to apply finite difference scheme for Beam propagation method by following this paper. I was wondering if anyone can share their code if they have implemented this method. I can share my code which is not working as expected and can get some insights if possible.
  4. Z

    Python Tackling Boundary Conditions in Python (Griffins Example)

    How to run a numerical simulation of Laplace equation if one of the boundary condition is like this: $$V(x,y) = 0 \text{ when } x \to \infty$$ I am trying to use Python to plot the solution of this Example 3.5. in Griffins EM
  5. T

    Matlab report help please (Finite Difference Method)

    We have to submit a Matlab (my worst module) assignment to show the heat transfer on a plate. However, I have the 2 codes almost done but I am struggling to write the report. To calculate the temperature on a 2D aluminum plate we need to use the Explicit Finite Difference Method. The problem...
  6. person123

    I Boundary Conditions For Modelling of a Fluid Using Euler's Equations

    Hi! I want to use Euler's equations to model a 2 dimensional, incompressible, non-viscous fluid under steady flow (essentially the simplest case I can think of). I'm trying to use the finite difference method and convert the differential equations into matrices to be solved using MATLAB. I set...
  7. L

    Finite difference method for the diffusion-advection equation

    So for my scheme I obtained ##\frac{\mu}{h^2} U_{p}+(\frac{v_{1}}{2 h}-\frac{\mu}{h^2})U_{E}+(\frac{v_{2}}{2 h} - \frac{\mu}{h^2})U_{N} - (\frac{v_{1}}{2 h}+\frac{\mu}{h^2})U_{W} - (\frac{v_{2}}{2 h} + \frac{\mu}{h^2})U_{N} + \tau = f## however I am not sure this is correct. I am quite new to...
  8. patrykh18

    I Numerical solution to the Schrodinger eqn. using Finite Difference Method

    As part of my project I was asked to use the finite difference method to solve Schrodinger equation. I see how you can turn it into a matrix equation, but I don't know how to solve it if the energy eigenvalues are unknown. Are there any recommended methods I can use to determine those...
  9. C

    MATLAB_Quantum Well_Finite Difference Method

    Homework Statement Hi, I am new to MATLAB and have an assignment where I have to construct a Hamiltonian matrix, apply boundary conditions, then find corresponding eigenvalues and eigenvectors for the electron in a box problem. I am stumped where to start. From our class we learned that you...
  10. yecko

    Conduction - finite difference method

    Homework Statement Homework Equations Finite difference method The Attempt at a Solution I have tried two different approaches, but still i am wrong in the question. Can anyone guide me how to attempt this question? Thank you
  11. T

    Finite difference method; finding the 'Stencil'

    Homework Statement Determine the Finite Difference Method stencil for approximating a second derivative u''(x) at a discrete set of nodes with maximum accuracy for stencil of sizes (0,4) (off-centered). My questions: I think I am able to answer the question I am just not sure about what is...
  12. Riverbirdy

    Finite difference Method of Wave Equation

    Hi, Physics forum! Just a little push of my doubts I hope somebody could help me with my confusion of one of our home works. I know that all boundary conditions are zero. My doubt is how do I interpret (x,y,0)=0.01 source in the figure? Where is it located in the grid. I am hoping someone...
  13. F

    Finite difference method derivation PDE

    Homework Statement Which algebraic expressions must be solved when you use finite difference approximation to solve the following Possion equation inside of the square : $$U_{xx} + U_{yy}=F(x,y)$$[/B] $$0<x<1$$ $$0<y<1$$ Boundary condition $$U(x,y)=G(x,y)$$ Homework Equations Central...
  14. A

    I Finite difference method for Schrödinger equation

    Suppose I want to solve the time-independent Schrödinger equation (ħ2/2m ∂2/∂x2 + V)ψ = Eψ using a numerical approach. I then discretize the equation on a lattice of N points such that x=(x1,x2,...,xN) etc. Finally I approximate the second order derivative with the well known central difference...
  15. F

    MATLAB Finite difference numerical integration or ode45?

    I'm trying to numerically solve the time dependent Schrödinger equation and I've been told that the best approach is to numerically integrate using a finite difference method, however I don't understand why I couldn't just use ode45 to solve it?! Is the finite difference (interpolation) method...
  16. Federico Navarrete

    FDM for a 3 metal layers 3D, heat transfer

    Dear members, Some days ago, I received the following exercise but I have never studied thermodynamics before and I don't know very well where to start, the exercise is about Heat Transfer and the Finite Difference Method and I must program the solution using Petsc and C++. About the Finite...
  17. I

    Finite difference method to solve first-order, multivariable

    I'm trying to replicate the model presented in this [paper](http://www.sciencedirect.com/science/article/pii/S1359431103000474), which is basically to model heat and mass transfer along a one-dimensional duct. There are four characteristic equations for this problem : Momentum conservation...
  18. N

    Finite Difference Method for non-square grid

    Hi, I have written some codes for the finite difference solution of diffusion equation (\frac{\partial c}{\partial t}= D {\nabla^2 c}, where c is the species concentration and D is the diffusion coefficient) as follows: DO k= 1, tsteps+1 DO i = 2, zsteps DO j = 2, rsteps...
  19. Last-cloud

    Finite difference method nonlinear PDE

    i want to solve a nonlinear PDE with finite difference method ,but using just discretization like in linear PDE , it will lead to nowhere , what's the right way to use FDM to solve nonlinear PDE or could someone provide me with book's titles or articles that can help me solving a nonlinear pdf...
  20. R

    Poisson equation with finite difference method

    Hi guys , i am solving this equation by Finite difference method. (dt2/dx2 + dt2/dy2 )= -Q(x,y) i have developed a program on this to calculate the maximum temperature, when i change the mesh size the maximum temperature is also changing, Should the maximum temperature change with mesh...
  21. M

    Finite Difference method to solve diffusion equation

    Homework Statement Plot the transient conduction of a material with k = 210 w/m K, Cp = 350 J/kg K, ρ = 6530 kg/m3 Where the material is a cylinder, with constant cross sectional area and is well insulated. The boundary conditions for the cylinder: T(0,t) = 330K T(l,t) = 299K...
  22. M

    MHB Implicit finite difference method

    Hey! :o I have a implicit finite difference method for the wave equation. At step 0, we set: $W_j^0=v(x_j), j=0,...,J$ At the step 1, we set: $W_j^1=v(x_j)+Dtu(x_j)+\frac{Dt^2}{2}(\frac{v(x_{j-1})-2v(x_j)+v(x_{j+1})}{h^2}+f(x_j,0)), j=0,...,J$ Can that be that at the step 1 $j$ begins from...
  23. M

    MHB The finite difference method for the heat equation-error

    Hey! :o I am implementing in a program the finite difference method for the heat equation. The problem is the following: $$u_t(x,t)=(g(x,t)u_x(x,t))_x+f(x,t), \forall (x,t) \in [0,1]x[0,1]$$ $$u(0,t)=u(1,t)=0, \forall t \in [0,1]$$ $$u(x,0)=0, \forall x \in [0,1]$$ where $f(x,t)=\pi x...
  24. S

    Five point scheme Finite Difference Method

    For possion equation $$u_{xx}+u_{yy}=f$$ I know the general five point scheme is in the form $$a_{1}U_{i,j-1}+a_{2}U_{i-1,j}+a_{3}U_{i,j}+a_{4}U_{i+1,j}+a_{5}U_{i,j+1}=f_{i,j}$$ But , is there have the form...
  25. W

    Finite Difference Method, Leapfrog (2,4) CFL Condition

    Hi. I'm trying to determine the CFL condition for the fourth-order leapfrog scheme. I'm finding 2 as what's published, which does not match what I'm getting. Does anyone know where I can find a von Neumann (or Fourier) stability analysis of the leapfrog (2,4) scheme (so I can compare my work)...
  26. A

    Solving by finite difference method

    hi; I have 3 hyperbolic electrodes ,one as a ring and 2 others as endcap electrodes which have potential v and 0 respectively.(quadrupole ion trap) I want to solve potential inside the trap by finite difference method. I don't know how general equations for unshaped materials will change...
  27. E

    Use finite difference method to solve for eigenvalue E

    Use finite difference method to solve for eigenvalue E from the following second order ODE: - y'' + (x2/4) y = E y I discretize the equation so that it becomes yi-1 - [2 + h2(x2i/4)] yi + yi+1 = - E h2 yi where xi = i*h, and h is the distance between any two adjacent mesh points. This...
  28. A

    Finite Difference Method - clarification of a term

    Homework Statement I'm doing a class on Numerical Solutions of DE and I have my first assignment. The problem is stated: Consider the following second order boundary value problem: \epsilon \frac{d^{2}y}{dx^{2}} + \frac{1}{2+x-x^{2}} \frac{dy}{dx}-\frac{2}{1+x}y = 4sin(3x), y(0) = 2, y(2) =...
  29. N

    Finite difference method for even potential in QM

    Hello to everyone, while solving homework course Nanotechnology and Nanocomponents, I have encountered a problem in FD method that is applied in even potential. In my homework assignment it is explicitly said that it must be done only in x>0 part of the domain, where my problem starts with...
  30. H

    Nonlinear PDE finite difference method

    Hello I want to resolve a nonlinear partial differential equation of second order with finite difference method in matlab. the equation is in the pdf file attached. Thanks
  31. I

    Difference between Central Difference Method and Finite Difference Method

    Hello all, I am in the process of solving a finite elements problem involving obtaining deflection of a simple mass-spring-damper 2nd order ODE system with a defined forcing function. While going through my class notes, I came across the idea of the central difference method, which is...
  32. R

    Taylor series and the forward finite difference method

    Given a partial differential equation, how would one go about implementing the forward finite difference method to the Taylor series?
  33. I

    Finite Difference method to solve PDEs

    Hello: I am looking to solve a set of 1D PDEs. I thought the finite difference method would be a good way to go about it. So I decided to pick a simple first order forward difference scheme to obtain preliminary results. I just have 1 question: According to my scheme, at the last node...
  34. C

    Solving Diffusion PDE By Finite difference Method in fortran

    Hey, I want to solve a parabolic PDE with boundry conditions by using FINITE DIFFERENCE METHOD in fortran. (diffusion) See the attachment for the problem The problem is that there is a droplet on a leaf and it is diffusing in the leaf the boundry conditions are dc/dn= 0 at the upper...
  35. C

    Solving Diffusion Equation By Finite difference Method in fortran

    Hey, I want to solve a parabolic PDE with boundry conditions by using FINITE DIFFERENCE METHOD in fortran. (diffusion) See the attachment for the problem The problem is that there is a droplet on a leaf and it is diffusing in the leaf the boundry conditions are dc/dn= 0 at the upper...
  36. 1

    MATLAB Finite difference method with matlab- square grid, cavity inside

    Hi, I'm here for help and hope somebody could give a hand on this because I'm noob in this. I'm now constructing a MATLAB program to find Electrical field and potential within a square grid mesh with square cavity inside. like the picture above. I only manage up to this...
  37. E

    Using Finite Difference Method In Excel

    ------Question------ a) Research the three finite difference approximations mentioned above (forward, backward and central). Use a spreadsheet to demonstrate each of these numerical methods for the function below. y=x3 −x2 +0.5x Investigate the derivative over the range x = [0,1], using...
  38. S

    Solving Fick's Law by Finite Difference Method

    Hi, i need help in solving a Fick's Law [ (∂c_k)/∂t = D_k (∂^2 c_k)/(∂x^2 ) ] by Finite Difference Method. Previously, I tried solving the Fick's Law by using the Separation of Variable method but that was not the correct way as told by my Prof as the correct way is to use Finite Difference...
  39. S

    Plotting Solutions Using Finite Difference Method with M = N = 20

    How do I use the finite difference method with M = N = 20 to obtain a plot of the solution of \nabla2u = 1, 0 < x < 1, 0 < y < 1, u(x,0) = x(1-x), u(x,1) = x(1-x), 0 \leq y \leq 1, u(0,y) = 0, u(1,y) = 0, 0 \leq y \leq 1.
  40. E

    Newton–Raphson method - Finite difference method

    Hi I am trying to solve a nonlinear differential equation with the use of the finite difference method and the Newton-Raphson method. Is there anyone that knows where I can find some literature about the subject? I am familiar with the use of the finite difference method, when solving...
  41. K

    Solving a PDE Using Finite Difference Method

    Hi The equation is: \frac{dP}{dt}-A*\frac{{d}^2P}{dx^2}-B*\frac{dC}{dt}=0 dP/dt=A*d2P/dx^2 was solved using a finite difference method. If the function C(x,t) is known, is it possible to solve the whole equation by using the finite difference solution as a supplement to the complete solution...
  42. W

    How is Finite Difference Method?

    I'm going to take a finite difference linear and non-linear PDE course next semester. I'm wondering how enjoyable the material is, and how difficult it may be. I'm actually looking forward to the fact there may only be one test throughout the semester, if any, and it's a mid-term. The rest of...
  43. M

    Nonlinear parabolic equations: finite difference method

    To the moderator: please move this to the section on differential equations if you think it would be better there. I'm looking at a reaction-diffusion equation of the form \frac{\partial u}{\partial t} = \frac{\partial^2 u}{\partial x^2} + f(u), where, e.g., f(u) = u(1-u) for the...
  44. L

    Benefit of using Nodal method instead of finite difference method?

    Nodal Method?? What's the benefit of using Nodal method instead of finite difference method in solving a diffusion problem?
  45. A

    BLASIUS EQUATION Solution with Finite Difference Method

    1) Using a similarity variable, the boundary layer equations for a two-dimensional, incompressible flow over a flat plate can be written below: 2f'''+ff''=0 The boundary conditions are: a) f ' (0) = 0, no slip at the wall b) f(0)=0, solid wall c) f ' (n) goes 1 as n goes infinity...
  46. A

    BLASIUS EQUATION Solutıon with Finite Difference Method

    1) Using a similarity variable, the boundary layer equations for a two-dimensional, incompressible flow over a flat plate can be written below: 2f'''+ff''=0 The boundary conditions are: a) f ' (0) = 0, no slip at the wall b) f(0)=0, solid wall c) f ' (n) goes 1 as n goes...
  47. C

    MATLAB Matlab and finite difference method

    computer engineering and mathematics,do you understand both of them?if u understand pls meet me.ı have a homework contains MATLAB course.ı can not write a program
  48. C

    Can Someone Help with MATLAB Programming for Finite Difference Method?

    :confused: my question y''(t)=-exp(-2t)+5y(t) accuracy on 5*10^(-3) by finite difference method and this question's MATLAB program. is there anyone who can do it ? it is very important for me.ı can not do and write a program in matlab.ı am a student ,my department is mathematics but ı can not...
  49. S

    Can Excel be Used to Solve for 2-D Transient Finite Difference in Heat Transfer?

    I am curious to know if anyone has a program that will solve for 2-D Transient finite difference I have an assignment in a heat transfer class and I am supposed to use Matlab to solve for this. The governing equation (given in the attachement) is to solve using finite difference method using...
  50. M

    MATLAB Finite Difference Method using Matlab

    I am curious to know if anyone has a program that will solve for 2-D Transient finite difference. I have a project in a heat transfer class and I am supposed to use Matlab to solve for this. However, when I took the class to learn Matlab, the professor was terrible and didnt teach much at...
Back
Top