Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

1D wave equation open boundary

  1. Jul 7, 2010 #1
    I am trying to write a solver for a 1D wave equation in MATLAB, and I have run into interesting problem that I just can't find a way out of.

    I start with the wave equation, and then discretize it, to arrive at the following,

    U{n+1}(j)=a*(U{n}(j+1)-2*U{n}(j)+U{n}(j-1))+2*U{n}(j)-U{n-1}(j) (for (j=1...end-1))

    I'm trying to simulate an open end string (perturbate it in the middle for example, and I want the wave to dissapear on the border)

    Usually it is done (correct me if I'm wrong) with applying zero gradient boundary condition, which in my case is:
    and leads to:

    Unfortunately this condition creates a partial reflection from the end which is supposed to be free.

    Please help

  2. jcsd
  3. Jul 9, 2010 #2
  4. Jul 12, 2010 #3

    Ben Niehoff

    User Avatar
    Science Advisor
    Gold Member

    Well, there ARE partial reflections from a free end, I think...the energy cannot transfer into the surrounding air with perfect efficiency.

    But to eliminate as much reflection as possible, you should look up "absorbing boundary conditions". These are a bit tricky to implement and it may take a fair bit of reading to get them right.
  5. Jul 13, 2010 #4
    Thank you, it is what I was looking for. You hae put me on the right track.
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook