[petsc-users] Unstructured mesh

Karthikeyan Chockalingam - STFC UKRI karthikeyan.chockalingam at stfc.ac.uk
Fri Dec 10 06:42:11 CST 2021

Hi Matt,

I intend to perform a scaling study – I have a few more questions from ex56
3D, tri-quadratic hexahedra (Q1), displacement finite element formulation.

i)                    What makes the problem non-linear? I believe SNES are used to solve non-linear problems.

ii)                   2,2,1 does it present the number of elements used in each direction?

iii)                 What makes the problem unstructured? I believe the geometry is a cube or cuboid – is it because it uses DMPlex?

iv)                 Do any external FEM package with an unstructured problem domain has to use DMPlex mat type?

v)                   What about -mat_type (not _dm_mat_type) ajicusparse – will it work with unstructured FEM discretised domains?

I tried to run two problems of ex56 with two different domain size ( - attached you find the log_view outputs of both on gpus) using _pc_type asm:

./ex56 -cells 2,2,1 -max_conv_its 2 -lx 1. -alpha .01 -petscspace_degree 1 -ksp_type cg -ksp_monitor -ksp_rtol 1.e-8 -pc_type asm -snes_monitor -use_mat_nearnullspace true  -snes_rtol 1.e-10 > output_221.txt

./ex56 -cells 10,10,5 -max_conv_its 2 -lx 1. -alpha .01 -petscspace_degree 1 -ksp_type cg -ksp_monitor -ksp_rtol 1.e-8 -pc_type asm -snes_monitor -use_mat_nearnullspace true  -snes_rtol 1.e-10 > output_221.txt

Below is the SNES iteration for problem with 2,2,1 cells which converges after two non-linear iterations:

0 SNES Function norm 0.000000000000e+00
  0 SNES Function norm 7.529825940191e+01
  1 SNES Function norm 4.734810707002e-08
  2 SNES Function norm 1.382827243108e-14

Below is the SNES iteration for problem with 10,10,5 cells– why does it first decrease and then increase to 0 SNES Function norm 1.085975028558e+01 and finally converge?

  0 SNES Function norm 2.892801019593e+01
  1 SNES Function norm 5.361683383932e-07
  2 SNES Function norm 1.726814199132e-14
  0 SNES Function norm 1.085975028558e+01
 1 SNES Function norm 2.294074693590e-07
  2 SNES Function norm 2.491900236077e-14

Kind regards,

From: Matthew Knepley <knepley at gmail.com>
Date: Thursday, 2 December 2021 at 10:57
To: "Chockalingam, Karthikeyan (STFC,DL,HC)" <karthikeyan.chockalingam at stfc.ac.uk>
Cc: "petsc-users at mcs.anl.gov" <petsc-users at mcs.anl.gov>
Subject: Re: [petsc-users] Unstructured mesh

On Thu, Dec 2, 2021 at 3:33 AM Karthikeyan Chockalingam - STFC UKRI <karthikeyan.chockalingam at stfc.ac.uk<mailto:karthikeyan.chockalingam at stfc.ac.uk>> wrote:

Are there example tutorials on unstructured mesh in ksp? Can some of them run on gpus?

There are many unstructured grid examples, e.g. SNES ex13, ex17, ex56. The solver can run on the GPU, but the vector/matrix
FEM assembly does not. I am working on that now.



Kind regards,

This email and any attachments are intended solely for the use of the named recipients. If you are not the intended recipient you must not use, disclose, copy or distribute this email or any of its attachments and should notify the sender immediately and delete this email from your system. UK Research and Innovation (UKRI) has taken every reasonable precaution to minimise risk of this email or any attachments containing viruses or malware but the recipient should carry out its own virus and malware checks before opening the attachments. UKRI does not accept any liability for any losses or damages which the recipient may sustain due to presence of any viruses.

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

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20211210/4f9ba483/attachment-0001.html>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: output_221.txt
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20211210/4f9ba483/attachment-0002.txt>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: output_10105.txt
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20211210/4f9ba483/attachment-0003.txt>

More information about the petsc-users mailing list