Defining mesh

19 views
Skip to first unread message

sadegh roudsari

unread,
Mar 26, 2022, 9:14:13 AM3/26/22
to fenics-support
RZ_Feature_StrategischerDialog_15.01.20.indd

Dear Fenics community,

I need to define the mesh with “RectangleMesh”  and not “UnitSquareMesh” using the following lines, with the mentioned dimension and number of cells:

import fenics

L =  8.0      # dimension L

H = -4.0      # dimension H

Nx = 8        # Number of cells in x-direction

Ny = 4        # Number of cells in y-direction

mesh = fenics.RectangleMesh(fenics.Point(-8,0), fenics.Point(L, H), Nx, Ny, "crossed")

fenics.plot(mesh)

 

I want to solve Nonlinear-Poisson equation with Combining Dirichlet and Neumann conditions using that mesh, but it is not working.

Your help is much appreciated.

 

Reply all
Reply to author
Forward
0 new messages