Forum Message

 

 

We have moved the forum to https://forum.ngsolve.org . This is an archived version of the topics until 05/05/23. All the topics were moved to the new forum and conversations can be continued there. This forum is just kept as legacy to not invalidate old links. If you want to continue a conversation just look for the topic in the new forum.

Notice

The forum is in read only mode.

How to set bondary conditions on a geometry from stl file?

More
1 year 11 months ago #4376 by mppavan
Hi,

I've created a geometry from an stl file using the following code. How do I specify boundary conditions at specific locations on the geometry. My geometry is an ellipsoid shell and I wish to have different BCs on 5 circular patches on the surface of my geometry. I know the approximate locations of the centers (It is okay if I find elements near to it). Is there a way to do it in python script?

My code:
from ngsolve import *
from netgen.meshing import *
from netgen.csg import *
import netgen.stl as ngstl

geo2 = ngstl.LoadSTLGeometry("../data/biotac_shell.stl")
mesh = geo2.GenerateMesh(maxh=1.0)

Thanks,
Pavan
Time to create page: 0.138 seconds