Hi Oscar, In this context, it is sufficient to think of a differential of a function f as being given by the formula
d f = Df dt, where Df is the total derivative. See also http://en.wikipedia.org/wiki/Total_derivative The line f = F(x^2 + y + sin(z)) turns the function x^2 + y + sin(z) into a "differential form of degree 0". Technically, f is still the same function, but now interpreted in the realm of differential forms so that you can take the exterior derivative by writing f.diff(). Note that diff() doesn't take any arguments, but as you can see from inspecting the result (the differential d f), the various partial derivatives are computed and put together in the right order. All the best, Joris. On 9 okt, 19:53, Oscar Lazo <[email protected]> wrote: > On Oct 9, 2:58 pm, jvkersch <[email protected]> wrote: > > > > > Hi Oscar, > > > In Sage 4.6 (currently 4.6alpha2) you will be able to do this using > > differential forms: > > > sage: x, y, z = var('x, y, z') > > sage: U = CoordinatePatch((x, y, z)) > > sage: F = DifferentialForms(U) > > > sage: f = F(x^2 + y + sin(z)); f > > (x^2 + y + sin(z)) > > sage: g = f.diff(); g > > cos(z)*dz + 2*x*dx + dy > > > sage: g.parent() > > Algebra of differential forms in the variables x, y, z > > > It's only a small step from having d f to obtaining D f. > > > All the best, > > J. > > That's great, from your example it seems like it shouldn't be too > difficult to make an analog to mathematicas Dt. I'm not familiarized > with differential forms. I what way is your f=f = F(x^2 + y + sin(z)) > different to f(x,y,z) = x^2 + y + sin(z) ? > > Oscar -- To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/sage-support URL: http://www.sagemath.org
