Post Reply 
Directional Derivative
01-29-2015, 04:36 PM (This post was last modified: 02-05-2015 07:02 PM by salvomic.)
Post: #2
RE: Directional Derivative
I'm trying this program:

Code:

#cas
// Directional derivative: dot(grad(f0), normalize(v))
derivdir(f,v):=
BEGIN
local g:=grad(f,[x,y,z]);
// gradient
local w:=normalize(v);
// versor
m:=dot(g,w);
// dot product
return m;
END;
#end

It seems to works with f as a function (expression), f(0), like (x^2-x*y) and v as vector (also not normalized), like [3,4] or [x,3y]; the program first normalize the vector finding its versor, and then return the symbolic directional derivative in the direction of that vector...

Any help to make it better?
There is a way to have the function listed in the Toolbox -> User?

Thank you :-)

salvo
Visit this user's website Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
Directional Derivative - salvomic - 01-29-2015, 12:17 PM
RE: Directional Derivative - salvomic - 01-29-2015 04:36 PM
RE: Directional Derivative - Han - 01-29-2015, 06:57 PM
RE: Directional Derivative - salvomic - 01-29-2015, 07:08 PM



User(s) browsing this thread: 1 Guest(s)