On Mon, Jan 28, 2019 at 12:15 AM Bin Liu <[email protected]> wrote:
> Hi John,
> The following codes are used for import and export mesh and solution.
>
> //============= import mesh ===============
> DistributedMesh mesh(init.comm());
> mesh.read("BOX.cpr");
> //=======================================
>
> //============ export solution ==============
> MeshSerializer serialize(mesh);
> Nemesis_IO(mesh).write_equation_systems (file_name.str(),equation_systems);
> //=======================================
>
> In fact, I was trying to avoid using "MeshSerializer", since it took too
> much memory. Did I miss anything to ouptut solution in nemesis format?
> Should I write out mesh as well? Could you suggest a successful example to
> write out solution and mesh in parallel through each processor?
>
You should not use a MeshSerializer when using the Nemesis_IO format... Can
you try replacing those two lines of code with the following, and let us
know what happens?
Nemesis_IO(mesh).write_timestep("filename.e", equation_systems,
/*timestep=*/1, /*time=*/0.);
--
John
_______________________________________________
Libmesh-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/libmesh-users