Zhenyu, can you tell us what happens if you remove the h_elem term in your penalty formulation ? Usually, we just set the penalty to a very large number, and do not involve the mesh size in setting it. See example 3: http://libmesh.github.io/examples/introduction_ex3.html
On Tue, Mar 17, 2015 at 8:09 AM, Zhang <zyzh...@nuaa.edu.cn> wrote: > Dear Libmesher, > > I tried to write an incompressible Naiver-Stokes solver based Libmesh. > Following features includes: > coupled pressure-velocity method > TransientNonlinearImplicitSystem used with > compute_jacobian(..) and compute_residual(..) run separatedly > Lid-driven cavity case for initial tests > BDF1 time marching > QUAD4 element, > vel_order=2, pres-order=1, both LAGRANGE elements > Pressure pinned at node_id=0 > > I tried DirichletBoundary class to impose the velocity BC, the code runs > OK. > > Now the problem is : > I coded myself the common penalty method for term > \int_{\Gamma_D}dt*\gamma/h*u*v, > and applied the forms in boundary integral part of jacobian function > Jxw_face[qp_face]*dt*penalty/h_elem*phi_face_[j][qp_face] > *phi_face_[i][qp_face] > and > Jxw_face[qp_face]*dt*penalty/h_elem*phi_face_[i][qp_face] *(u-u_bc) > at counterparts of residual function > the results show the boundary velocity not fully applied ,esp. at the side > walls near > the two top corners. Actually there are nonzero u normal to the local side > wall. > So I wonder anybody here will kindly show me some hints. > > Furthermore, I tried applied the weak Dirichlet conditions by add futher > boundary integrals like > dt\int_{\partial\Omega} (-\mu\nabla \vec{ u}+pII)\cdot \vec{n}\cdot\vec{v} > + > dt\int_{\partial\Omega} (-\mu\nabla \vec{ v}+qII)\cdot \vec{n}\cdot\vec{u} > at left and > dt\int_{\partial\Omega} (-\mu\nabla \vec{ v}+qII)\cdot > \vec{n}\cdot\vec{u_bc} > > The case is even worse. > > I also attached the code, and I am looking forward to any suggestions. > Many thanks. > > Zhenyu > > > ------------------------------------------------------------------------------ > Dive into the World of Parallel Programming The Go Parallel Website, > sponsored > by Intel and developed in partnership with Slashdot Media, is your hub for > all > things parallel software development, from weekly thought leadership blogs > to > news, videos, case studies, tutorials and more. Take a look and join the > conversation now. http://goparallel.sourceforge.net/ > _______________________________________________ > Libmesh-users mailing list > Libmesh-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/libmesh-users > > -- Vikram Garg Postdoctoral Associate Predictive Engineering and Computational Science (PECOS) The University of Texas at Austin http://web.mit.edu/vikramvg/www/ http://vikramvgarg.wordpress.com/ http://www.runforindia.org/runners/vikramg ------------------------------------------------------------------------------ Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ _______________________________________________ Libmesh-users mailing list Libmesh-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libmesh-users