# \[ParallelStencil\] Boundary Conditions

**URL:** <https://discourse.julialang.org/t/parallelstencil-boundary-conditions/70171>\
**Category:** Modelling & Simulations\
**Created:** [October 21, 2021, 6:54pm UTC](https://discourse.julialang.org/t/parallelstencil-boundary-conditions/70171 "2021-10-21T18:54:04Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![apattyn](https://avatars.discourse-cdn.com/v4/letter/a/ee7513/32.png) [@apattyn](https://discourse.julialang.org/u/apattyn)\
**Post date:** [October 22, 2021, 1:22am UTC](https://discourse.julialang.org/t/parallelstencil-boundary-conditions/70171/3 "2021-10-22T01:22:55Z")

</div>

Thanks, I know a popular toolbox used in my field - [k-wave](http://www.k-wave.org/), uses a PML. I thought that was primary due to them using a spectral method to solve the acoustic wave equation though. I wasn’t sure if a hacky solution of just setting the pressure at the edges to zeros constantly would be feasible.

But once I include acoustic attenuation it should be relatively easy to implement a PML - hopefully 😅

But thank you for the hints relating to “sponge” boundaries!

---

_[View the full topic](https://discourse.julialang.org/t/parallelstencil-boundary-conditions/70171)._
