Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Improve formula presentation #697

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 13 additions & 9 deletions docs/src/dev/how_it_works.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ the result. For example, to calculate the partial derivatives for the gradient o
\vdots \\
x_N + \epsilon_N
\end{bmatrix}
\to
\mapsto
f(\vec{x}_{\epsilon}) = f(\vec{x}) + \sum_{i=1}^N \frac{\delta f(\vec{x})}{\delta x_i} \epsilon_i
```

Expand All @@ -102,24 +102,28 @@ two calls to ``f`` to evaluate the gradient:
x_3 \\
x_4
\end{bmatrix}

\vec{x}_{\epsilon} = \begin{bmatrix}
```
1st call:
```math
\to \vec{x}_{\epsilon} = \begin{bmatrix}
x_1 + \epsilon_1 \\
x_2 + \epsilon_2 \\
x_3 \\
x_4
\end{bmatrix}
\to
f(\vec{x}_{\epsilon}) = f(\vec{x}) + \frac{\delta f(\vec{x})}{\delta x_1} \epsilon_1 + \frac{\delta f(\vec{x})}{\delta x_2} \epsilon_2

\vec{x}_{\epsilon} = \begin{bmatrix}
\mapsto
f(\vec{x}_{\epsilon}) = f(\vec{x}) + \frac{\delta f(\vec{x})}{\delta x_1} \epsilon_1 + \frac{\delta f(\vec{x})}{\delta x_2} \epsilon_2,
```
2nd call:
```math
\to \vec{x}_{\epsilon} = \begin{bmatrix}
x_1 \\
x_2 \\
x_3 + \epsilon_1 \\
x_4 + \epsilon_2
\end{bmatrix}
\to
f(\vec{x}_{\epsilon}) = f(\vec{x}) + \frac{\delta f(\vec{x})}{\delta x_3} \epsilon_1 + \frac{\delta f(\vec{x})}{\delta x_4} \epsilon_2
\mapsto
f(\vec{x}_{\epsilon}) = f(\vec{x}) + \frac{\delta f(\vec{x})}{\delta x_3} \epsilon_1 + \frac{\delta f(\vec{x})}{\delta x_4} \epsilon_2.
```

This seeding process is similar for Jacobians, so we won't rehash it here.
Loading