Automatic differentiation
Definition
Let be open and let be given by an evaluation trace. Its first variables are the inputs . The others are given for by where and each is a differentiable elementary function, such as , , or . The outputs are some of the .
- Forward mode takes a direction , sets , and computes along with each the value .
- Reverse mode first evaluates the trace and takes . It sets the adjoint of each output to its entry of and all other adjoints to . Then for it adds to for each .
Automatic differentiation is the computation of derivatives of by these propagation rules. Forward mode returns , where is the Jacobian matrix. Reverse mode returns , where .
Remarks
Example: has the trace , , . Forward mode at with gives , , , which is the partial derivative at . Reverse mode with gives , then and , the full gradient in one backward sweep. Non-example: the difference quotient is not automatic differentiation; it does not use the trace and has a truncation error of order . Forward mode can be described with dual numbers , : evaluating the program on gives .
Reading path
To understand this page from the ground up, read these 8 pages in order. The foundations come first.
Show the path as a graph
- no evidence level
- Derivative concept
- Euclidean space object
- Function concept
- Total derivative concept
- Function of several variables concept
- Partial derivative concept
- Jacobian matrix concept
- Automatic differentiation definition
Further reading
About this page
| Tag | KDZN92Z8JR |
|---|---|
| URI | m2://KDZN92Z8JR |
| Kind | definition |
| Writing | W0 stub |
| MSC | 65D25, 68W30 |
| Defines | Automatic differentiation |
| Uses | Derivative, Partial derivative, Jacobian matrix |
Markdown · JSON · Edit on GitHub
What this page needs for W1
- an inventory row: the row of the inventory that the node accounts for (0 of 1)
- a source with a locator (0 of 1)
The writing levels say how complete the text of a page is. They do not measure its truth.
What links here
No page links to this page yet.