[petsc-users] Reading user generated Cartesian grid into DMXX
Matthew Knepley
knepley at gmail.com
Mon Apr 24 08:47:58 CDT 2023
On Mon, Apr 24, 2023 at 7:33 AM 吉兴洲 <jixingzhou918 at gmail.com> wrote:
> Dear all,
>
> I'm solving a fluid problem and it has multiple square cylinders in the
> flow area. Unfortunately, I have to use a Cartesian grid (nonuniform) which
> can't generated by Gmsh.
>
> I have noticed that the object *DMDA* and *DMFOREST* typically have there
> own intrinsic methods such as *DMDACreate2d *to generate a structured
> grid or index. But in my case (multiple cylinders in the whole area), it is
> quite complicated or maybe impossible to use these intrinsic methods
> generating a Cartesian grid, if I'm not missing something in the *DM *
> tutorial.
>
> So I wonder if I can somehow define my own DMXX to directly read my
> generated grid. Or is there any other way to deal with (meaning reading the
> topology and geometry) this "complex" Cartesian grid?
>
By "Cartesian grid", we generally mean a regular rectangular grid, where we
have a m x n grid of cells. This is also often called a "structured grid".
If you mean an irregular arrangement of square cells, then this is an
"unstructured grid" using "quadrilateral cells". DMForest deals with
"structured adaptive" grids, meaning structured grids where we allow cells
to be divided without dividing neighbors. This creates hanging nodes which
must be dealt with somehow in the discretization.
What kind of mesh are you talking about?
Thanks,
Matt
> All the best,
> Xingzhou
>
--
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener
https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20230424/a783dfea/attachment.html>
More information about the petsc-users
mailing list