User Tools

Site Tools


xfem

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
xfem [2008/06/27 13:52] rumacikxfem [2008/09/29 12:42] (current) stephane.bordas
Line 4: Line 4:
 Discussion on the design of the implementation of Xfem into Oofem. The discussion is based on the description of the implementation in the paper Bordas S et al., An extended finite element library, //Int. J. Numer. Meth. Engng, 2007// Discussion on the design of the implementation of Xfem into Oofem. The discussion is based on the description of the implementation in the paper Bordas S et al., An extended finite element library, //Int. J. Numer. Meth. Engng, 2007//
  
-==== Comments to the paper ==== 
 ---- ----
-=== General comments === +==== General comments ==== 
-  * The most serious thing is that the xfem implementation in the article requires changes on the level of parent classes. If you want to implement a derived class, you inherit it from parent class and from the parent class it should be obvious which functions should be implemented (for more see specific comments in Element and Node class).---[[bp]] +  * The most serious thing is that the xfem implementation, as described in the articlerequires changes on the level of basic FEM classes, i.e. modification (extensions) of basic element and node classes. This has two principal drawbacks: 
-  * I generally agree with classes EnrichmentItemEnrichmentFunction, GeometryEntity and IntegrationRule (already existing in oofem). I think that it will be possible to implement EnrichmentDetector, CrackGrowthDirLaw, CrackGrowthIncrementLaw into the rest of the classesE.g. EnrichmentItem can have a method Grow. In case the EnrichmentItem is a crack, it will implement the functionality CrackGrowthDirLaw and CrackGrowthIncrementLaw.---[[bp]]+    - if someone will want just the classic Element without xfem, he will be probably confused as what he should implement, when looking at base Element class. I want to keep basic element interface as simple as possible. This problem can be elegantly solved by interfaces (I got inspired in Javabecause C++ does not have them, I use the inheritance). In case I need some specific functionality on an element, I declare it in a class, say xyElementInterface, and if the element implements this functionality, it inherits also from xyElementInterface. Then I have a method, which finds out whether the element implements the interface and a method, which returns the Interface. ---[[bp]] 
 +    - the modification of basic fem classes will also introduce some variables declared at this level, that are only related to xfemFor analyses without xfem this will lead to wasting of space. ---[[bp]]
   * In the article method domain->solveFractureMechanicsProblemAt() is mentioned. For the representation of the problem we have a class EngngModel ---[[bp]]   * In the article method domain->solveFractureMechanicsProblemAt() is mentioned. For the representation of the problem we have a class EngngModel ---[[bp]]
  
 + 
 ---- ----
 +==== Class Element and Node ====
  
-=== Class Element and Node === +== Changes at the parent class level == 
- +  * See also general comments   
-== Change at the parent class level == +  * We can think about whether not to have two versions of an element e.g. PlaneStress2D and PlaneStress2dXfem. PlaneStress2dXfem would inherit from PlaneStress2d and solely added the Xfem interface. Everything is also motivated by saving memory. ---[[bp]] 
-  * The most serious thing is that the xfem implementation in the article requires changes on the level of parent classes. If you want to implement a derived class, you inherit it from a parent class and from the parent class it should be obvious which functions should be implemented. In case an xfem support is added into class Element and someone will want just the classic Element without xfem, he will probably be confused as what he should implement. This problem I solve by interfaces (I got inspired in Java, because C++ does not have them, I use the inheritance). In case I need something specific on an element, I declare it in a class, say xyElementInterface, and if the element implements this functionality, it inherits also from xyElementInterface. Then I have a method, which finds out whether the element implements the interface and a method, which returns the Interface. ---[[bp]] +* I am personally not in favor of doing so, because the enrichment does not live at the element level, but at the patch level (node level). The rest of the structure should not have to know about it directly, only through the node, at least, this is how I see it right now. If we want to solve problems with different physics, we also need to know which field is enriched with what. A possible way to do this is probably to use the dof Manager. [[spab]]
-  * We can also think about whether not have two versions of an element e.g. PlaneStress2D and PlaneStress2dXfem. PlaneStress2dXfem would inherit from PlaneStress2d and solely added the Xfem interface.Everything is also motivated by saving memory. ---[[bp]]+
   * In fact, the same problem is in Node class, but that we will probably have to accept. It would not probably be a good idea to have Node and XfemNode ---[[bp]]   * In fact, the same problem is in Node class, but that we will probably have to accept. It would not probably be a good idea to have Node and XfemNode ---[[bp]]
 +* I agree, it would not be a good idea... [[spab]]
 +  * I am not very happy about this solution. Probably there could be an XFEMManager (Domain attribute), which keeps the list of enrichment on each node. In this way we could get around the problem of keeping this information on the Node. Nothing would have to be added to the Node class.---[[bp]]
 +* EnrichmentManager is a possibility to avoid the info being held at the node level. I think we are trying here to go around a problem which is realted to the fact that we are not defining function spaces really. We could simply have something like a function space manager, and function spaces could live on different parts of the domain, this way, we avoid all that trouble. I think... [[spab]]
 +  * As I understand, all the xfem functions apart from resolveLinearDependency (see below) should be added to the parent class Node. ---[[rhc]]
  
-As I understand, all the xfem functions apart from resolveLinearDependency (see below) should be added to the parent class Node. ---[[rhc]] 
- 
-I am not very happy about this solution. Probably there could be an XFEMManager (Domain attribute), which keeps the list of enrichment on each node. In this way we could get around the problem of keeping this information on the Node. Nothing would have to be added to the Node class.---[[bp]] 
  
 == resolveLinearDependency() == == resolveLinearDependency() ==
-Both Element and Node class have a function resolveLinerDependency().I think that is a potential problem, because this method at least partly contains code which is connected to a particular type of Enrichment. This I slightly mind. I would more like to see it in the implementation of EnrichmentFunction. Otherwise everytime you add an EnrichmentFunction you will have to change classes Node and Element.---[[bp]] +Both Element and Node clases have a function resolveLinerDependency(). I think that is a potential problem, because this method at least partly contains code which is connected to a particular type of Enrichment. This I slightly mind. I would like to see it in the implementation of EnrichmentFunction. Otherwise every time you add an EnrichmentFunction you will have to change classes Node and Element.---[[bp]] 
- +* This is a very good point, the enrichment should clearly be able to solve their own dependency problems, that was a mistake on our part. [[spab]] 
-It is definitely true, that linear dependency is connected to EnrichmentFunction. In case of Heaviside function, this method decides whether the enriched node changes to non-enriched, if one part of the cut nodal support is too big compared to the other one. So I think, in the paper they put it into Node class since they need to operate with the nodal support. I would probably solve it by an interface LinearDependency(), which will be inherited by EnrichmentFunction in case it suffers from it. The interface would have a reference to EnrichmentItem and a virtual function resolveLinearDependency().---[[rhc]] +It is definitely true, that linear dependency is connected to EnrichmentFunction. In case of Heaviside function, this method decides whether the enriched node changes to non-enriched, if one part of the cut nodal support is too big compared to the other one. So I think, in the paper they put it into Node class since they need to operate with the nodal support. I would probably solve it by an interface LinearDependency(), which will be inherited by EnrichmentFunction in case it suffers from it. The interface would have a reference to EnrichmentItem and a virtual function resolveLinearDependency().---[[rhc]]
- +
-I do not think, the dependency is so exceptional. I would directly put it as a method of class EnrichmentFunction. We also have to think whether the linear dependency cannot be caused also by an interaction of two different enrichment functions. I think that is generally possible, so we should think how to solve it.---[[bp]]+
  
 +* I do not think, the dependency is so exceptional. I would directly put it as a method of class EnrichmentFunction. We also have to think whether the linear dependency cannot be caused also by an interaction of two different enrichment functions. I think that is generally possible, so we should think how to solve it.---[[bp]]
 +* Yes, we should try and solve this dependency problem in a general way. The ingredients that come into it are the types of enrichment, and the mesh. We can also say it is the enrichment geometry and the mesh. In the general case, each enrichment function should know how to resolve this problem with the mesh. But the enrichment function is strongly dependent on the geometry of the enrichment feature, which means that this could be resolved at the mesh geometry interaction level. [[spab]]
 ---- ----
- +==== Class CrackTip ====
-=== Class CrackTip ===+
 == std::vector<Material*>* matArray == == std::vector<Material*>* matArray ==
 I do not understand why material is an attribute of the CrackTip class ---[[rhc]] I do not understand why material is an attribute of the CrackTip class ---[[rhc]]
Line 52: Line 53:
  
 ---- ----
 +==== Class EnrichmentDetector ====
 + * I generally agree with classes EnrichmentItem, EnrichmentFunction, GeometryEntity and IntegrationRule (already existing in oofem). I think that it will be possible to implement EnrichmentDetector, CrackGrowthDirLaw, CrackGrowthIncrementLaw into the rest of the classes. E.g. EnrichmentItem can have a method Grow. In case the EnrichmentItem is a crack, it will implement the functionality CrackGrowthDirLaw and CrackGrowthIncrementLaw.---[[bp]]
 +
  
-=== Class EnrichmentDetector === +I would leave existence or non-existence of this class open. I have a feeling that lots of people are looking at how the changes in the enriched domain influence the solution. For this reason I find the existence of the class useful. ---[[rhc]]
-I would leave existence or non-existence of this class open. I have a feeling that lots of people are looking at how the changes in the enriched domain influence the solution. For this reason I find the existence of the class useful. ---[[rhc]]+
  
 ---- ----
  
-=== Class CrackGrowthDirectionLaw and CrackGrowthIncrementLaw === +==== Class CrackGrowthDirectionLaw and CrackGrowthIncrementLaw ==== 
-You mentioned that you would like to have it implemented as a part of the rest of the classes. In fact I liked the idea of having them as a base abstract class.---[[rhc]]+You mentioned that you would like to have it implemented as a part of the rest of the classes. In fact I liked the idea of having them as a base abstract class.---[[rhc]]
  
-Ok, we can dicuss it. I do not generally like to waste lots of classes for a particular problem. These two classes are basically just for the representation of discrete cracks, which is a small part of xfem. They will have lots of derived classes. Instead, there could be one class with an optional parameter, which decides on the direction law etc. But I do agree, that the idea is nicely with the object-oriented design.---[[bp]]+Ok, we can dicuss it. I do not generally like to waste lots of classes for a particular problem. These two classes are basically just for the representation of discrete cracks, which is a small part of xfem. They will have lots of derived classes. Instead, there could be one class with an optional parameter, which decides on the direction law etc. But I do agree, that the idea is nicely with the object-oriented design.---[[bp]]
  
  
xfem.txt · Last modified: 2008/09/29 12:42 by stephane.bordas