# How to implement jump(u^3) for nonlinear DG flux in FreeFEM++

**URL:** https://community.freefem.org/t/how-to-implement-jump-u-3-for-nonlinear-dg-flux-in-freefem/4054
**Category:** General Discussion
**Created:** [September 4, 2025, 11:29am UTC](https://community.freefem.org/t/how-to-implement-jump-u-3-for-nonlinear-dg-flux-in-freefem/4054 "2025-09-04T11:29:33Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![ds2201](https://avatars.discourse-cdn.com/v4/letter/d/48db29/32.png) [@ds2201](https://community.freefem.org/u/ds2201)
#### Post date: [September 4, 2025, 11:29am UTC](https://community.freefem.org/t/how-to-implement-jump-u-3-for-nonlinear-dg-flux-in-freefem/4054/1 "2025-09-04T11:29:33Z")

</div>

Hi, I am implementing a DG scheme in FreeFEM++ for a nonlinear diffusion problem.

I need to write the jump of b(u)=u+u^3/3 in `intalledges`. Writing it directly gives me the compilation error. Can `jump()` handle nonlinear expressions like `u^3`? If not, what is the correct way to implement the jump of `b(u)` across DG faces in FreeFEM++?

---

<div class="post-metadata">

### Author: ![fb77](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/fb77/32/3796_2.png) [@fb77](https://community.freefem.org/u/fb77)
#### Post date: [September 4, 2025, 12:52pm UTC](https://community.freefem.org/t/how-to-implement-jump-u-3-for-nonlinear-dg-flux-in-freefem/4054/2 "2025-09-04T12:52:12Z")

</div>

You can set w=u+u^3/3 (w declared in the same fespace as u), and then put jump(w).

---

<div class="post-metadata">

### Author: ![ds2201](https://avatars.discourse-cdn.com/v4/letter/d/48db29/32.png) [@ds2201](https://community.freefem.org/u/ds2201)
#### Post date: [September 5, 2025, 6:04am UTC](https://community.freefem.org/t/how-to-implement-jump-u-3-for-nonlinear-dg-flux-in-freefem/4054/3 "2025-09-05T06:04:28Z")

</div>

Thank you. This is helpful.
