<p>You can see why the sum of differences is giving a second derivative if you look at the derivative of a one-dimensional function <span class="math-container">$f$</span>. The derivative of <span class="math-container">$f$</span> at <span class="math-container">$x_0$</span> is
<span class="math-container">$$ \frac{df}{dx}(x_0) \approx \frac{f(x_0 + dx) - f(x_0)}{dx} $$</span>
The second derivative is then
<span class="math-container">\begin{eqnarray*}
\frac{d^2f}{dx^2}(x_0) &amp;\approx&amp; 
  \frac{df/dx(x_0) - df/dx(x_0-dx)}{dx} \\
  &amp;\approx&amp; \frac{\left(f(x_0+dx) - f(x_0)\right) -
                  \left(f(x_0) - f(x_0-dx)\right)}{dx^2} \\
  &amp;=&amp; \frac{\left(f(x_0+dx) - f(x_0)\right) +
                  \left(f(x_0-dx) - f(x_0)\right)}{dx^2},
\end{eqnarray*}</span>
i.e. the sum of the local differences, scaled by a distance factor <span class="math-container">$dx^2$</span>. In a <em>graph</em> Laplacian, you don't have any distances, just graph connections, so it's just the sum of the local differences.</p>
<p>When working on meshes, though, we typically want to take the geometry of the mesh into account. There are many ways to do this, but the most popular seems to be the <em>cotangent Laplacian</em>, where the local difference for each edge is weighted by the sum of the cotangents of the angles opposite that edge.</p>

CC BY-SA 4.0
2020-08-13T12:09:36.573Z
You've written out a finite difference Taylor expansion approximation that is valid on a regular grid. And while it gives some intuition, it doesn't answer the question imo.
lightxbulb
CC BY-SA 4.0
2020-08-14T08:15:07.247Z
I figured that an intuition as to how a sum of differences represents the second derivative was the required level here. The answers to [this recent MathOverflow question](https://mathoverflow.net/questions/368963) go far more in depth as to what a graph Laplacian is and what it represents.
gilgamec
CC BY-SA 4.0
2020-08-14T20:06:15.513Z
This is a great answer. Thanks for linking it for completeness.
lightxbulb
CC BY-SA 4.0
2020-08-13T07:59:45.873Z
2020-08-13T07:59:45.873Z
gilgamec
<p>I am starting to learn about the <a href="https://en.wikipedia.org/wiki/Laplace_operator" rel="nofollow noreferrer">laplacian operator</a> <span class="math-container">$\Delta = \nabla \cdot \nabla\phi(p)$</span></p>
<p>Which can be described as the divergence of the gradient of a scalar function <span class="math-container">$\phi$</span>. This is equivalent to the sum of the second order partial derivatives of the function.</p>
<p>However, it seems its <a href="https://en.wikipedia.org/wiki/Discrete_Laplace_operator" rel="nofollow noreferrer">graph equivalent</a> is just the sum of the differences of adjacent vertices. Am I reading that right? In my head that should be equivalent to the first order partial derivatives, not the second order ones.</p>
<p>(I didn't know whether to ask here or in math, I decided here is more relevant because this is in the context of geometry processing)</p>

<mathematics><computational-geometry><geometry>
Is the laplacian operator for meshes just the sum of the differences of neighbouring vertices?
Makogan
# Is the laplacian operator for meshes just the sum of the differences of neighbouring vertices?

(Asked by: username_0 on 2020-08-13)

I am starting to learn about the [laplacian operator](https://en.wikipedia.org/wiki/Laplace_operator) $\Delta = \nabla \cdot \nabla\phi(p)$

Which can be described as the divergence of the gradient of a scalar function $\phi$. This is equivalent to the sum of the second order partial derivatives of the function.

However, it seems its [graph equivalent](https://en.wikipedia.org/wiki/Discrete_Laplace_operator) is just the sum of the differences of adjacent vertices. Am I reading that right? In my head that should be equivalent to the first order partial derivatives, not the second order ones.

(I didn't know whether to ask here or in math, I decided here is more relevant because this is in the context of geometry processing)

**Tags:** mathematics, computational-geometry, geometry


---

## 1 answers

### Answer by username_1 on 2020-08-13. Score: 2 | Accepted answer

You can see why the sum of differences is giving a second derivative if you look at the derivative of a one-dimensional function $f$. The derivative of $f$ at $x\_0$ is
$$ \frac{df}{dx}(x\_0) \approx \frac{f(x\_0 + dx) - f(x\_0)}{dx} $$
The second derivative is then
\begin{eqnarray\*}
\frac{d^2f}{dx^2}(x\_0) &\approx&
\frac{df/dx(x\_0) - df/dx(x\_0-dx)}{dx} \\
&\approx& \frac{\left(f(x\_0+dx) - f(x\_0)\right) -
\left(f(x\_0) - f(x\_0-dx)\right)}{dx^2} \\
&=& \frac{\left(f(x\_0+dx) - f(x\_0)\right) +
\left(f(x\_0-dx) - f(x\_0)\right)}{dx^2},
\end{eqnarray\*}
i.e. the sum of the local differences, scaled by a distance factor $dx^2$. In a *graph* Laplacian, you don't have any distances, just graph connections, so it's just the sum of the local differences.

When working on meshes, though, we typically want to take the geometry of the mesh into account. There are many ways to do this, but the most popular seems to be the *cotangent Laplacian*, where the local difference for each edge is weighted by the sum of the cotangents of the angles opposite that edge.

> **Comments:**
> **username_2**: You've written out a finite difference Taylor expansion approximation that is valid on a regular grid. And while it gives some intuition, it doesn't answer the question imo.  
> **username_1**: I figured that an intuition as to how a sum of differences represents the second derivative was the required level here. The answers to [this recent MathOverflow question](https://mathoverflow.net/questions/368963) go far more in depth as to what a graph Laplacian is and what it represents.  
> **username_2**: This is a great answer. Thanks for linking it for completeness.  

---

