# Export then read global solution

**URL:** <https://community.freefem.org/t/export-then-read-global-solution/2109>\
**Category:** General Discussion\
**Created:** [November 8, 2022, 6:24pm UTC](https://community.freefem.org/t/export-then-read-global-solution/2109 "2022-11-08T18:24:40Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Markov](https://avatars.discourse-cdn.com/v4/letter/m/f1d935/32.png) [@Markov](https://community.freefem.org/u/Markov)\
**Post date:** [November 8, 2022, 6:24pm UTC](https://community.freefem.org/t/export-then-read-global-solution/2109/1 "2022-11-08T18:24:40Z")

</div>

Hello,

I am running a code on parallel and I would like to export the global solution as one array, then I would like to read this array in another .edp file. Now I am familiar with exporting/importing data in FreeFEM, but how can I gather the solutions on all the processors in a simple real[int] array type.

---

<div class="post-metadata">

**Author:** ![aszaboa](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/aszaboa/32/2918_2.png) [@aszaboa](https://community.freefem.org/u/aszaboa)\
**Post date:** [November 9, 2022, 6:22am UTC](https://community.freefem.org/t/export-then-read-global-solution/2109/2 "2022-11-09T06:22:53Z")

</div>

The scipt [FreeFem-sources/navier-stokes-2d-PETSc.edp at develop · FreeFem/FreeFem-sources · GitHub](https://github.com/FreeFem/FreeFem-sources/blob/develop/examples/hpddm/navier-stokes-2d-PETSc.edp) illustrates how you can gather the distributed FE field into a global one (`uG`). Then, you can just save the global mesh (`ThBackup `) and the global solution vector (`uG[]`).
