Question: Why isn't the result in a consistent form?

Can anyone explain the inconsistency in the following?

 

with(VectorCalculus):

f := proc (x, y) options operator, arrow; x^2+y^3 end proc:

Gradient(f(x, y), [x, y])

2*x*`#mover(mi("e"),mo("_"))`[x]+3*y^2*`#mover(mi("e"),mo("_"))`[y]

(1)

gradf := unapply(Gradient(f(x, y), [x, y]), [x, y]):

gradf(x, y)

2*x*`#mover(mi("e"),mo("_"))`[x]+3*y^2*`#mover(mi("e"),mo("_"))`[y]

(2)

gradf(1, 1)

Vector(2, {(1) = 2, (2) = 3})

(3)

``

Why is result from gradf(x,y) given as a linear combination of the appropriate unit vectors, but gradf(1,1) given as a column vector? How can consistency be acheived?

Download grad.mw

Please Wait...