I am trying to define a function for future NDSolve use
oweqn = (1/(c)^2) D[y[t, x], {t, 2}] - D[y[t, x], {x, 2}] + k1 y[t, x] = 0
Where I predefined $c$ to be a given function of $x$. Everything works perfectly until I entered the above code with which mathematica returned:
Set::write: Tag Plus in y[t,x]-(y^(0,2))[t,x]+(1+2 Sech[x]^2) (y^(2,0))[t,x] is Protected.
I could not see which character in my code is in conflict with predefined mathematica character.
= 0
to==0
and see if fixes it. $\endgroup$FullForm
to see what your expression really looks like. In fact, you do the assignmentPlus[...]=0
instead of building an equationPlus[...]==0
. Clearly, one cannot assign a zero to thePlus
tag. $\endgroup$