[Gmsh] Applying Boundary conditions using gmsh
Vaibhav Deshpande
vaibhavd85 at gmail.com
Wed Nov 4 20:04:21 CET 2009
Hi,
I am Vaibhav Deshpande a Graduate student at University of Wisconsin
Madison, In one of my projects I have implemented Quad4 plane stress element
and I am using gmsh as my mesher, the geometry I am using is of a cantilever
beam made of lines
1-2
2-3
3-4
4-1
where 1 2 3 4 are the coordinates of geometrical points
x y coordinates for nodes are
1, 0 0
2, 10 0
3, 10 1
4,0 1
what I want to do now is apply a pressure on line that
joins geometrical points 3 and 4 I was able to find the mesh lines
corresponding to geometrical line 3-4 using the code given below. I need to
find Jacobian of all the elements whose sides have an applied pressure. The
Jacobian is a function of coordinates of that element.
Simply put given a side I want to know which elements are made up of that
side. I can imagine that gmsh has that piece of information in some or the
other way, but I was not able to get that information as an output.
I am using following geometry file.
/*********************************************************************
*
* Gmsh cantilever beam
*
*********************************************************************/
lc = 0.5;
Point(1) = {0, 0, 0, lc};
Point(2) = {10, 0, 0, lc} ;
Point(3) = {10, 1, 0, lc} ;
Point(4) = {0, 1, 0, lc} ;
Line(1) = {1,2} ;
Line(2) = {3,2} ;
Line(3) = {3,4} ;
Line(4) = {4,1} ;
Line Loop(5) = {4,1,-2,3} ;
Plane Surface(6) = {5} ;
MyLineThree = 3;
Physical Line (MyLineThree) = {3} ;
MyLineFour = 4;
Physical Line (MyLineFour) = {4} ;
Physical Surface("Mesh") = {6} ;
the boundary conditions I want to apply are on line 4 is Dirichlet boundary
condition, which I was able to figure out,
the second boundary condition is on line 3 I want to apply a pressure on all
the elements on the top that share an edge with line 3 how should I access
this information?
Please let me know how I can go about it. Thanks a lot.
--
Regards,
Vaibhav Deshpande
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.geuz.org/pipermail/gmsh/attachments/20091104/c455e792/attachment.html>