Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.
weak constraint and weak contribution
Posted 5 nov. 2013, 06:22 UTC−5 11 Replies
Please login with a confirmed email address before reporting spam
someone can explain me what is the difference between a weak constraint and weak contribution ?
thank you a lot
Please login with a confirmed email address before reporting spam
For a simple Poisson equation in a domain D : div(grad u) = f (with appropriate boundary conditions) you will get the integral of f*test(u) as weak contribution to the weak form (integrated over the domain D). Of course you get other contributions from the derivative in space. And other terms at the boundaries due to the integration by parts.
Suppose you want to add an extra term that does not fit into the general or coefficient form used by COMSOL, the weak form is the most general form to use.
By weak _constraint_ you should read "constraint added to the weak form of the equation".
It might be a constraint added in the domain, like the mean value of u=u0 for instance. Or more commonly it is simply a Dirichlet-like boundary condition : u=u0 at a boundary. The weak constraint means simply that it is added directly to the weak form (sometimes there is no strong form to express your constraint, or simply it is more practical to write the weak expression directly).
The usual way to add such a constraint still solving the problem consists of adding a Lagrange multiplier. It leads to a choice to make about which degrees of freedom you allow to be modified so that your problem is still well posed. This is a common question for multiphysics problems involving several unknowns : some of the unknown should drive the change whereas others might only follow. Sorry, this is probably better explained with some equations : You can read more in the documentation of COMSOL : COMSOL Multiphysics > Equation-Based Modeling > Modeling with PDEs > Specifying and Interpreting Boundary Conditions.
A really good book I strongly recommend for clear explanations about the finite element method, constraints, weak form, etc... is Will Zimmerman's "Multiphysics Modeling With Finite Element Methods" : see www.comsol.fr/books/mmwfem
It is not updated with version 4 of COMSOL but only a very small fraction of the content is outdated.
Good luck.
Eric Favre
Please login with a confirmed email address before reporting spam
I find your explanation very interesting, especially the following paragraph:
"The usual way to add such a constraint still solving the problem consists of adding a Lagrange multiplier. It leads to a choice to make about which degrees of freedom you allow to be modified so that your problem is still well posed. This is a common question for multiphysics problems involving several unknowns : some of the unknown should drive the change whereas others might only follow."
As I understand, a (weak) constraint serves as a boundary condition, and a boundary condition is introduced to determine a unique solution of PDE. In this sense, why do we need a Langrange multiplier to make the PDE well posed? Shouldn't the PDE be well posed with the boundary condition naturally? Or probably here the constraint means some extra condition besides normal boundary conditions, then a Langrange multiplier might be necessary.
This question may be very easy for many experts, but for me it's quite confusing... Would you please comment on my understanding, and correct me.
Thanks a lot!
--
Pu, ZHANG ??
Departamento de Física Teórica de la Materia Condensada,
Universidad Autónoma de Madrid,
Madrid, Spain.
Please login with a confirmed email address before reporting spam
---------------
it can be more general than a boundary condition : it can be anywhere, not only on a boundary. It can couple the unknown to its own time derivative, it can be non local and establish a relation between the unknown at one point of space with another one (see the PID example of COMSOL for instance), the possibilities are really wide here and COMSOL should be able to fit any such complicated condition with ease.
, and a boundary condition is introduced to determine a unique solution of PDE.
---------------
yes. Usually it has a direct relation with the physics involved.
In this sense, why do we need a Langrange multiplier to make the PDE well posed?
Shouldn't the PDE be well posed with the boundary condition naturally? Or probably here the constraint means some extra condition besides normal boundary conditions, then a Langrange multiplier might be necessary.
---------------
You are perfectly right. COMSOL tries first to remove those degrees of freedom where the solution is known (elimination technique). But in a number of cases where the boundary condition is more complicated that u=u0 where u0 is known, this is not sufficient and you need to use other techniques, more general, like the Lagrange multiplier technique.
See the doc COMSOL V4.3b :
COMSOL Multiphysics > Building a COMSOL Model > Boundary Conditions > Weak Constraints
I'll try to elaborate a longer answer later on. I'll keep you posted (you should be patient though ;) ).
Eric Favre
Please login with a confirmed email address before reporting spam
it helped me a lot.
thank you again
Please login with a confirmed email address before reporting spam
Its nice explanation . However the matrix is becoming singular whenever the weak constraint is used. Where can the problem be?
Thanks,
H.
Please login with a confirmed email address before reporting spam
a singular matrix often means that the problem is not well posed mathematically. If you add a Lagrange multiplier, (or a weak constraint with no special care of the "constraint force") you might need to add some feedback somewhere else in your system, otherwise you might just overconstrain the problem.
Another question to ask : why do you need to use the weak constraints? Answering this question would help to understand the issue you face.
Best regards
Eric Favre
Please login with a confirmed email address before reporting spam
Thank you for your reply.
I have long 3D cylinder and want to impose the following condition on bottom and top surfaces.
Integral(Stress_ij)=F_i ( Stress_ij are stress components and F_i are the external applied forces)
So I defined the integral operator and used weak constraint ( Integral(Stress_ij)-F_i -->0) by selecting the top and bottom surfaces. Finally i got "Singular matrix"
Then I changed the boundary condition with out integral
Stress_ij=F_i ( Stress_ij are stress components and F_i are the external applied forces)
This is working with no problem !
(Its obvious that there will be many possibilities of stress distributions that will satisfy the required integral condition . But by saint venant's principle for regions far away from top and bottom surfaces all possible stress distributions will have approximately the same effect and the problem will still be well-posed.)
Regards,
H.
Please login with a confirmed email address before reporting spam
Thanks for the details. I understand that this topic has been discussed in
www.comsol.fr/community/forums/general/thread/45191
Imposing integral constraints instead of distributed ones might make the problem ill-posed. Henrik mentions it is the case here. You perhaps might want to add constraints for preventing free rotations or translations, or taking into account possible symmetries or anti-symmetries (that fix some degrees of freedom implicitly), or anything that would help to reduce the non determination of the problem. As Henrik mentions, this is a case-dependent process that might be non trivial.
Saint-Venant's principle is a consequence of the modeling, not an hypothesis that you can rely on as an input into the equations. Even an inverse problem would fail : find the stress distribution so that you get one given result consistent with Saint Venant's principle.
You might perhaps approach the solution differently by a sensitivity analysis : any modification of the boundary condition would lead to some modification of the solution, that you want to evaluate (zero in your case).
There is a sensitivity interface in COMSOL that you might be interested in looking at if this option makes sense (Stationary Forward and Adjoint Sensitivity are included in COMSOL core package).
Good luck,
Eric Favre
COMSOL France
Please login with a confirmed email address before reporting spam
Thanks again for your detailed explanations.
What I actually want is to reproduce model problem of COMSOL3.5 (Moments in the Continuum Application Mode,,EXAMPLE: TORSIONAL MOMENT ON A CYLINDER)
Where the torsion is applied on boundary surface of the cylinder is given by stress distribution which corresponds to the moment as :
M=Integral (Taz_smsld*y-Tay_smsld*z) (Saint-Venant's principle)
Where "Taz_smsld" and "Tay_smsld" are stress components in Z and Y directions and the axis of the cylinder is along X axis )
then Global equation to apply a moment of 100 is defined as
Tau=M-100
Finally a boundary load is applied as Fx=Tau*r (r=sqrt(x^2+Y^2))
SO what is not so clear for me is why its necessary yo apply "Tau*r" as boundary load !
I have attached the model example of Version3.5
Thanks,
H.
Attachments:
Please login with a confirmed email address before reporting spam
Let me describe alightly differently the problem you refer to :
M=Integral (Taz_smsld*y-Tay_smsld*z) : this is the definition of M.
Tau=M-100 : this way of writing is actually not correct.
You should read :
Tau is the Lagrange Multiplier (new unknown scalar variable) that is defined such that the equation
M-100 = 0
is fulfilled.
(Tau is not equal to M-100).
Now you need to give a feedback to the initial problem so that the solution will change to meet the requirement M=100. Otherwise your problem is ill-posed (and you get a singular matrix error, typically).
The applied moment (force times radius) applied is :
Fx=Tau*r
You see here that Fx is adjusted in its intensity by Tau (you could input Fx=tau if you would not know that you actually want to apply a constant torque, so the force is linearly radius dependent). Since Fx is incorporated within the definition of M (through the integral), the problem is now well-posed.
To summarize :
You add a constraint (M=100) through a Lagrange Multiplier (Tau).
You need to let the solution change somewhere (feedback) : F=Tau*r at the boundary.
You could write F=Tau or F=Tau*r^2, or anything else, it depends on the problem you want to model.
I suggest to have a look at this model :
Loaded Spring—Using Global Equations to Satisfy Constraints
www.comsol.fr/model/using-global-equations-to-satisfy-constraints-9999
The principle is the same : adding a new unknown so that a new constraint is fulfilled (since you cannot have less unknowns than constraints).
I hope this makes it clear. Again, the "rigid connector" makes it straightforward within V4.4.
Good luck,
Eric Favre
Please login with a confirmed email address before reporting spam
Thanks for your explanations.I went through all and now I got the point. I want to apply it for bending cylinder( whose axis is along Z axis ) by applying a moment on top and bottom surfaces of the cylinder along Y-axis
--------------------------------------------
1- definition of moment
M=integral(y*pzd2.sz)
2- Global equations
Tau=M -100
3- Boundary loads
Fx=Tau
But Its not giving bending of the ncylinder. I have attached the picture of the displacements a
Thanks,
H.
Attachments:
Note that while COMSOL employees may participate in the discussion forum, COMSOL® software users who are on-subscription should submit their questions via the Support Center for a more comprehensive response from the Technical Support team.
Suggested Content
- FORUM How to make the 'Weak Inequality Constraint' converge as well as 'Contact' constraint in Solid Mechainc module?
- BLOG Nonstandard Constraints and the Power of Weak Contributions
- KNOWLEDGE BASE Warning: New Constraint Force Nodes Detected
- BLOG Implementing the Weak Form with a COMSOL App
- FORUM rotational constraint