# Vector Analysis: Why are the Grad, Laplacian and Div being evaluated to zero

For the non linear partial differential equation below, why are the Gradient, Laplacian and Divergence being evaluated to zero despite using the VectorAnalysis package.

Needs["VectorAnalysis"]
Needs["DifferentialEquationsInterpolatingFunctionAnatomy"];
Bo = 1/300;
\[Delta] = 10^-3;
\[Epsilon] = 10^-6;
r = 0;
m = 0.05;
\!$$\*SubscriptBox[\(\[PartialD]$$, $$t$$]$$h[x, y, t]$$\) +
Div[-h[x, y, t]^3 Bo Grad[h[x, y, t]] +
Laplacian[h[x, y, t]]] + ((\[Delta] h[x, y, t]^3) Grad[
h[x, y, t]])/(Bi h[x, y, t] + K1)^3 +
m (h[x, y, t]/(K1 + Bi h[x, y, t]))^2 Grad[
h[x, y, t]]] + \[Epsilon]/(Bi h[x, y, t] + K1) + r \!$$\*SubscriptBox[\(\[PartialD]$$, $$x$$]$$( \*SubscriptBox[\(\[PartialD]$$, $$x$$]
\*FractionBox[
SuperscriptBox[$$h[x, y, t]$$, $$2$$], $$K1 + Bi\ h[x, y, t]$$]\
\*SuperscriptBox[$$h[x, y, t]$$, $$3$$])\)\)

I am doing this because I'd like to evaluate the magnitude of each of these terms at a certain time step.

Here is a simple sample code without the Vector Analysis package that works fine:

I solve a PDE using NDSolve and then plot each term (I call each of the two terms Eq1 and Eq2 here) at a certain time step.

sol = u /.
NDSolve[{D[u[t, x], t] ==
0.5 D[u[t, x], x, x] + u[t, x] D[u[t, x], x],
u[t, -Pi] == u[t, Pi] == 0 , u[0, x] == Sin[x]},
u, {t, 0, 2}, {x, -Pi, Pi}][[1]];

Eq1 = 0.5 D[u[t, x], x, x];
Magnitude1[t_, x_] = Eq1 /. u -> sol
Plot[Magnitude1[1.5, x], {x, -\[Pi], \[Pi]}]

Eq2 = u[t, x] D[u[t, x], x];
Magnitude2[t_, x_] = Eq2 /. u -> sol
Plot[Magnitude2[1.5, x], {x, -\[Pi], \[Pi]}]

• Did you do SetCoordinates[Cartesian[x,y,z]]? It does the trick for me :-) Oct 16, 2012 at 20:23
• @chris Boy, do I feel like an idiot. Should I delete this question? Oct 16, 2012 at 20:26
• may be you should check if its already been asked. otherwise its useful idiocy ;-) Oct 16, 2012 at 20:27
• @chris I checked. This hasn't been asked before. If you feel it's useful idiocy, I'll let it be. I am thinking however, I should receive negative points for dumb-itude such as this. Oct 16, 2012 at 20:28
• Interestingly, 6 of the 8 posts involving SetCoordinates were asked by you... :-) Oct 16, 2012 at 22:20