# The meaning of "clean = true" in the "Mat\<complex\> M(J, Loc, clean = true);"

**URL:** <https://community.freefem.org/t/the-meaning-of-clean-true-in-the-mat-complex-m-j-loc-clean-true/2877>\
**Category:** General Discussion\
**Created:** [January 11, 2024, 1:03pm UTC](https://community.freefem.org/t/the-meaning-of-clean-true-in-the-mat-complex-m-j-loc-clean-true/2877 "2024-01-11T13:03:39Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![WeiQLiu](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/weiqliu/32/1043_2.png) [@WeiQLiu](https://community.freefem.org/u/WeiQLiu)\
**Post date:** [January 11, 2024, 1:03pm UTC](https://community.freefem.org/t/the-meaning-of-clean-true-in-the-mat-complex-m-j-loc-clean-true/2877/1 "2024-01-11T13:03:39Z")

</div>

Dear all,  
I have recently been studying Eigenvalue problem in PETSc. This is FreeFem-sources/examples/hpddm–Eigenvalue problems. I find that some script have parameter “clean = true” in “Mat M(J, Loc, clean = true)”, but some don’t, e.g Mat M(J, Loc). I test a few of this scripts, like this:[navier-stokes-2d-SLEPc-complex.edp](https://github.com/FreeFem/FreeFem-sources/blob/develop/examples/hpddm/navier-stokes-2d-SLEPc-complex.edp). But I find that whether or not “clean = true” is added made no difference to the result. What does “clean = true” do?  
Thank you in advance!

---

<div class="post-metadata">

**Author:** ![prj](https://avatars.discourse-cdn.com/v4/letter/p/ecae2f/32.png) [@prj](https://community.freefem.org/u/prj)\
**Post date:** [January 12, 2024, 7:07am UTC](https://community.freefem.org/t/the-meaning-of-clean-true-in-the-mat-complex-m-j-loc-clean-true/2877/2 "2024-01-12T07:07:54Z")

</div>

It deletes the input FreeFEM `matrix` `Loc`. Not really needed unless you want to optimize aggressively memory consumption.

---

<div class="post-metadata">

**Author:** ![WeiQLiu](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/weiqliu/32/1043_2.png) [@WeiQLiu](https://community.freefem.org/u/WeiQLiu)\
**Post date:** [January 12, 2024, 7:18am UTC](https://community.freefem.org/t/the-meaning-of-clean-true-in-the-mat-complex-m-j-loc-clean-true/2877/3 "2024-01-12T07:18:17Z")

</div>

Thank you very much for you reply. I get it.
