bueler / p4pdes

C and Python examples from my book on using PETSc and Firedrake to solve PDEs
MIT License
179 stars 69 forks source link

How to create an unstructured(dmplex) mesh from a *.poly file with p2pdes? #47

Closed MrNGS closed 4 years ago

MrNGS commented 4 years ago

This package has been (and truly still is) a very very helpful for learning Petsc for PDEs. Although i am still exploring the library, I am impatient to find out how to generate an unstructured simplicial meshes ( triangular and tetrahedral one using Triangle/Tetgen software). As petsc may install those generators, I would like to know how to give the solver just a *.poly file and then it will generate the desired mesh.

All the best, zaq

bueler commented 4 years ago

After drafting some examples using triangle in the past, my book now used Gmsh exclusively. There are examples in c/ch10/ and Firedrake examples in python/ch13/ and python/ch14/. Unstructured triangulations in all cases. Send me an email at elbueler@alaska.edu and I'll send you PDFs of those chapters. (The book is now in production ... appearing late 2020 I hope.)

I suppose if you have installed with --download-triangle and look around in the petsc tree you will find the triangle executable. But I don't know how petsc is using the triangle install, really. Same (i.e. ignorance) with tetgen.

MrNGS commented 4 years ago

Thank you very much for the answer. Ok, i wll leave an email.