Toggle navigation
Egison
Documentations
Try It Out
Online Tools
Online Egison Interpreter
Online Egison Tutorial
Online Demonstrations
Poker Hands
Mahjong
Prime Numbers
Trees
Graph (Bellman-Ford Algorithm)
Randomized 3-SAT
Time-Series Data
Math
Blog
Community
Exterior Derivative
Nov 20 2017
-- -- Exterior Derivative -- def N : Integer := 3 def params : Vector MathExpr := [|x, y, z|] def g : Matrix Integer := [|[|1, 0, 0|], [|0, 1, 0|], [|0, 0, 1|]|] def d {a} (X: a) : DiffForm a := WedgeApplyExpr (ApplyExpr (VarExpr "flip") [VarExpr "\8706/\8706"]) [VarExpr "params",VarExpr "X"] def f : MathExpr := function (x, y, z) -- The exterior derivative of f is the gradient 1-form assertEqual "d(f)" (d f) [| f|1 x y z, f|2 x y z, f|3 x y z |] -- The exterior derivative of d(f) is 0 (d^2 = 0) assertEqual "d(d(f)) = 0 (Poincaré lemma)" (dfNormalize (d (d f))) [| [| 0, 0, 0 |], [| 0, 0, 0 |], [| 0, 0, 0 |] |]
Links
Back to the Table of Contents
This website in other langauge:
English
,
日本語