2013-01-10 14 views
0

如何在Mathematica中創建和執行元組值函數的差異化。在數學中區分元組值函數

更具體而言,我具有以下功能,其中R表示實線

f:R^2 -> R^3 

g:R^3 -> R^3 

h: R^3 -> R^1 

我要考慮這些功能k中的組合物:R^2 - > R 2 1,即K = H( g(f(x,y)))並且我想要找到導數k_x,k_y,k_xx,k_yy,k_xy

如何在Mathematica中執行此操作?

回答

1

我假設你沒有f,g,h的表達式,但是你想要用f,g,h的導數表示組合的導數。

你總是可以減少問題的單值函數,通過使用像f[x_,y_] := {f1[x,y],f2[x,y],f3[x,y]}

例如一個定義:

f[x_, y_] := Through[{f1, f2, f3}[{x, y}]] 
g[x_, y_, z_] := Through[{g1, g2, g3}[{x, y, z}]] 

D[h @@ g @@ f[x, y], x] 

結果:

(Derivative[{1, 0}][f3][{x, y}]*Derivative[{0, 0, 1}][g3][{f1[{x, y}], f2[{x, y}], f3[{x, y}]}] + 
    Derivative[{1, 0}][f2][{x, y}]*Derivative[{0, 1, 0}][g3][{f1[{x, y}], f2[{x, y}], f3[{x, y}]}] + 
    Derivative[{1, 0}][f1][{x, y}]*Derivative[{1, 0, 0}][g3][{f1[{x, y}], f2[{x, y}], f3[{x, y}]}])* 
    Derivative[0, 0, 1][h][g1[{f1[{x, y}], f2[{x, y}], f3[{x, y}]}], g2[{f1[{x, y}], f2[{x, y}], f3[{x, y}]}], 
    g3[{f1[{x, y}], f2[{x, y}], f3[{x, y}]}]] + 
(Derivative[{1, 0}][f3][{x, y}]*Derivative[{0, 0, 1}][g2][{f1[{x, y}], f2[{x, y}], f3[{x, y}]}] + 
    Derivative[{1, 0}][f2][{x, y}]*Derivative[{0, 1, 0}][g2][{f1[{x, y}], f2[{x, y}], f3[{x, y}]}] + 
    Derivative[{1, 0}][f1][{x, y}]*Derivative[{1, 0, 0}][g2][{f1[{x, y}], f2[{x, y}], f3[{x, y}]}])* 
    Derivative[0, 1, 0][h][g1[{f1[{x, y}], f2[{x, y}], f3[{x, y}]}], g2[{f1[{x, y}], f2[{x, y}], f3[{x, y}]}], 
    g3[{f1[{x, y}], f2[{x, y}], f3[{x, y}]}]] + 
(Derivative[{1, 0}][f3][{x, y}]*Derivative[{0, 0, 1}][g1][{f1[{x, y}], f2[{x, y}], f3[{x, y}]}] + 
    Derivative[{1, 0}][f2][{x, y}]*Derivative[{0, 1, 0}][g1][{f1[{x, y}], f2[{x, y}], f3[{x, y}]}] + 
    Derivative[{1, 0}][f1][{x, y}]*Derivative[{1, 0, 0}][g1][{f1[{x, y}], f2[{x, y}], f3[{x, y}]}])* 
    Derivative[1, 0, 0][h][g1[{f1[{x, y}], f2[{x, y}], f3[{x, y}]}], g2[{f1[{x, y}], f2[{x, y}], f3[{x, y}]}], 
    g3[{f1[{x, y}], f2[{x, y}], f3[{x, y}]}]]