11-09-2014, 02:29 PM

A diff() problem:

Example: f(x,y):+x²-2*x*y+3*y²+2*x-2*y

1.) diff(f(x,y),x) ---> 2.*x-2.*y+2.

2.) diff(f(x,y),y) ---> -2*x+6*y-2

x - direction:

3.) diff(diff(f(x,y),x)) ---> 2

4.) diff( 2.*x-2.*y+2,x) ---> 2

5.) diff(f(x,y),x$2) ---> 2

y - direction:

6.) diff(diff(f(x,y),y)) ---> -2

7.) diff(-2*x+6*y-2,y) ---> 6

8.) diff(f(x,y),y$2) ---> 6

The second derivative in the x-direction worked properly.

The second derivative in the y-direction worked improperly in the red highlighted case(??)

(The template key entry method worked properly for these examples.)

Example: f(x,y):+x²-2*x*y+3*y²+2*x-2*y

1.) diff(f(x,y),x) ---> 2.*x-2.*y+2.

2.) diff(f(x,y),y) ---> -2*x+6*y-2

x - direction:

3.) diff(diff(f(x,y),x)) ---> 2

4.) diff( 2.*x-2.*y+2,x) ---> 2

5.) diff(f(x,y),x$2) ---> 2

y - direction:

6.) diff(diff(f(x,y),y)) ---> -2

7.) diff(-2*x+6*y-2,y) ---> 6

8.) diff(f(x,y),y$2) ---> 6

The second derivative in the x-direction worked properly.

The second derivative in the y-direction worked improperly in the red highlighted case(??)

(The template key entry method worked properly for these examples.)