# Error in Adapt function

**URL:** <https://community.freefem.org/t/error-in-adapt-function/3756>\
**Category:** General Discussion\
**Created:** [February 18, 2025, 7:38am UTC](https://community.freefem.org/t/error-in-adapt-function/3756 "2025-02-18T07:38:51Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![goutham2023](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/goutham2023/32/1759_2.png) [@goutham2023](https://community.freefem.org/u/goutham2023)\
**Post date:** [February 18, 2025, 7:38am UTC](https://community.freefem.org/t/error-in-adapt-function/3756/1 "2025-02-18T07:38:51Z")

</div>

Hi FF++ users,  
I am trying to implement a material removal problem with mesh movement. However, after running for some time, I encounter a Bamg error when using the adaptmesh command. I have shared a picture of the error in the comments.  
Could you please suggest the correct way to use movemesh and adaptmesh? Additionally, I would appreciate guidance on how to perform interpolation afterward.

Thanks for your time!

 ![Capture](https://canada1.discourse-cdn.com/flex030/uploads/freefem/original/2X/0/0751f889f307db1cc9f25ec6dc5343d41e758510.jpeg)

---

<div class="post-metadata">

**Author:** ![frederichecht](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/frederichecht/32/15_2.png) [@frederichecht](https://community.freefem.org/u/frederichecht)\
**Post date:** [February 24, 2025, 12:33pm UTC](https://community.freefem.org/t/error-in-adapt-function/3756/2 "2025-02-24T12:33:13Z")

</div>

Please see the mesh, I think you will see the problem graphically.
