Question: 1-D standing wave equation with variable propagation speed

I am not sure whether this should be in "create a post" or "ask a question." Let me know if this is more appropriate in "ask a question"

The standing wave equation is given by:

PDE:=diff(u(x,t),t,t)=c^2*diff(u(x,t),x,x)

IBC := {u(x, 0) = A0*cos(Pi*x/L), D[1](u)(0, t) = 0, D[1](u)(L, t) = 0, D[2](u)(x, 0) = 0}

pdsolve(PDE,IBC,numeric)

In my problem, the material is a magneto-elastic material where c, the speed of the acoustic wave, is a function of a magnetic field H.  The material is nonlinear and saturable.  I define it by a 3 segment piecewise nonlinear function of H.  The material response is a result of a sinusoidal H field.  I am interested in solving u(x,t).  

With that, c in the PDE has to be rewritten as c(H(t)), pdsolve gives an error as PDE has to be expressed as a function of u,t, or x.  So I redefine c(H(t)) as c(t).  I ran into another error in pdsolve as the piecewise has to be based on t or x and not H.  

The problem is that depending on H I can go through all 3 segments and back in one cycle and I have to find the corresponding t's for the piecewise.  Now I am driving the material with 100 cycles, I have to find and list all those piecewise transition points which is hardly practical.

Is there any other ways to approach and solve this problem?

Please Wait...