summaryrefslogtreecommitdiffstats
path: root/Smoke/report/chapter5.tex
diff options
context:
space:
mode:
Diffstat (limited to 'Smoke/report/chapter5.tex')
-rw-r--r--Smoke/report/chapter5.tex12
1 files changed, 6 insertions, 6 deletions
diff --git a/Smoke/report/chapter5.tex b/Smoke/report/chapter5.tex
index d12f159..7907667 100644
--- a/Smoke/report/chapter5.tex
+++ b/Smoke/report/chapter5.tex
@@ -1,22 +1,22 @@
\chapter{Divergence}
-The divergence shows the amount of mass which is compressed or expanded. If mass enters the field at some point, called a source point, then that point will have a
-positive divergence value. If mass exits the field at some point, called a sink point, then that point will have a negative divergence value. \\
+After implementing the glyphs it was time for the divergence. This is a value which can be calculated using the already known value at each vertex and that of its
+neighbors. \\
\section{Description}
-After implementing the glyphs it was time for the divergence. This is a value which can be calculated using the already known value at each vertex and that of its
-neighbors. \\
+The divergence shows the amount of mass which is compressed or expanded. If mass enters the field at some point, called a source point, then that point will have a
+positive divergence value. If mass exits the field at some point, called a sink point, then that point will have a negative divergence value. \\
\section{Implementation}
-The calculation of the divergence is rather simple. For the divergence of the velocity it looks like:
+The calculation of the divergence is rather simple, once you get it. For the divergence of the velocity it looks like:
$$ \nabla \cdot v = \frac{\partial v}{\partial x} + \frac{\partial v}{\partial y} = $$
$$ \frac{v_x(i + 1, j) - v_x(i, j)}{cell_x} + \frac{v_y(i + 1, j) - v_y(i, j)}{cell_y}$$
Where $ v_x(i, j) $ is the x-value at the gridpoint (i, j) and similar for the y-value. The $ cell_x $ and $ cell_y $ are the width and height of the cell. We also
-implemented the divergence of the force field. \\
+implemented the divergence of the force field with the same formula. \\
The definition of the divergence says high values should appear where matter is injected and low values where matter exits the field. This means high values should
appear in front of the mouse while dragging and low values behind it. \\