Skip to content
Snippets Groups Projects
Commit 4e8a94fb authored by Guillaume Demesy's avatar Guillaume Demesy
Browse files

back to working example

parent c42a3ee9
No related branches found
No related tags found
1 merge request!1Debug curved mesh
......@@ -139,8 +139,10 @@ Integration {
{ GeoElement Point ; NumberOfPoints 1 ; }
{ GeoElement Line ; NumberOfPoints 4 ; }
{ GeoElement Line2 ; NumberOfPoints 4 ; }
{ GeoElement Line3 ; NumberOfPoints 4 ; }
{ GeoElement Triangle ; NumberOfPoints 6 ; }
{ GeoElement Triangle2; NumberOfPoints 12 ; }
{ GeoElement Triangle3; NumberOfPoints 12 ; }
}
}
}
......@@ -148,53 +150,52 @@ Integration {
}
FunctionSpace {
{ Name Hgrad_perp; Type Form1P;
{ Name Hgrad_perp; Type Form1P;
BasisFunction {
// // for second order mesh elements - Lagrange P3 :
// un : BF_Node // order 2 is automatic (since all nodes are in NodesOf, even mid-edge ones)
// un3e : BF_Node_3E // we add part of order 3 basis functions
// un3f : BF_Node_3F // we add the rest of order 3 basis functions
{ Name sn; NameOfCoef un; Function BF_PerpendicularEdge_1N; Support Region[Om]; Entity NodesOf[All]; }
If(flag_o2g==0) // for curved elements, mid-edge nodes are already included in BF_PerpendicularEdge_1N
{ Name sn2; NameOfCoef un2; Function BF_PerpendicularEdge_2E; Support Region[Om]; Entity EdgesOf[All]; }
If(flag_o2g==0)
// for curved elements, mid-edge nodes are already included in BF_PerpendicularEdge_1N
// But for Mesh.ElementOrder=1, we need to add them explicitely
{ Name sn2e; NameOfCoef un2e; Function BF_PerpendicularEdge_2E; Support Region[Om]; Entity EdgesOf[All]; }
EndIf
If(flag_o2i==1) // TODO: Check P3 and P4 (_3E)
{ Name sn3; NameOfCoef un3; Function BF_PerpendicularEdge_2F; Support Region[Om]; Entity FacetsOf[All]; }
// { Name sn4; NameOfCoef un4; Function BF_PerpendicularEdge_3E; Support Region[Om]; Entity EdgesOf[All]; }
{ Name sn5; NameOfCoef un5; Function BF_PerpendicularEdge_3F; Support Region[Om]; Entity FacetsOf[All]; }
If(flag_o2i==1)
{ Name sn3e; NameOfCoef un3e; Function BF_PerpendicularEdge_3E; Support Region[Om]; Entity EdgesOf[All]; }
{ Name sn3f; NameOfCoef un3f; Function BF_PerpendicularEdge_3F; Support Region[Om]; Entity FacetsOf[All]; }
EndIf
}
Constraint {
{ NameOfCoef un; EntityType NodesOf ; NameOfConstraint BlochX; }
If(flag_o2g==0)
{ NameOfCoef un2; EntityType EdgesOf ; NameOfConstraint BlochX; }
{ NameOfCoef un2e; EntityType EdgesOf ; NameOfConstraint BlochX; }
EndIf
If(flag_o2i==1) // TODO: Check P3 and P4 (_3E)
// //{ NameOfCoef un3; EntityType FacetsOf ; NameOfConstraint BlochX; }
// { NameOfCoef un4; EntityType EdgesOf ; NameOfConstraint BlochX; }
// //{ NameOfCoef un5; EntityType FacetsOf ; NameOfConstraint BlochX; }
If(flag_o2i==1)
{ NameOfCoef un3f; EntityType EdgesOf ; NameOfConstraint BlochX; }
EndIf
}
}
{ Name Hgrad; Type Form0;
BasisFunction {
{ Name sn; NameOfCoef un; Function BF_Node; Support Region[Om]; Entity NodesOf[All]; }
If(flag_o2g==0) // for curved elements, mid-edge nodes are already included in BF_Node
{ Name sn2; NameOfCoef un2; Function BF_Node_2E; Support Region[Om]; Entity EdgesOf[All]; }
{ Name sn; NameOfCoef un; Function BF_Node_1N; Support Region[Om]; Entity NodesOf[All]; }
If(flag_o2g==0) // for curved elements, mid-edge nodes are already included in BF_PerpendicularEdge_1N
{ Name sn2e; NameOfCoef un2e; Function BF_Node_2E; Support Region[Om]; Entity EdgesOf[All]; }
EndIf
If(flag_o2i==1) // TODO: Check P3 and P4 (_3E)
{ Name sn3; NameOfCoef un3; Function BF_Node_2F; Support Region[Om]; Entity FacetsOf[All]; }
// { Name sn4; NameOfCoef un4; Function BF_PerpendicularEdge_3E; Support Region[Om]; Entity EdgesOf[All]; }
{ Name sn5; NameOfCoef un5; Function BF_Node_3F; Support Region[Om]; Entity FacetsOf[All]; }
If(flag_o2i==1)
{ Name sn3e; NameOfCoef un3e; Function BF_Node_3E; Support Region[Om]; Entity EdgesOf[All]; }
{ Name sn3f; NameOfCoef un3f; Function BF_Node_3F; Support Region[Om]; Entity FacetsOf[All]; }
EndIf
}
Constraint {
{ NameOfCoef un; EntityType NodesOf ; NameOfConstraint BlochX; }
If(flag_o2g==0)
{ NameOfCoef un2; EntityType EdgesOf ; NameOfConstraint BlochX; }
{ NameOfCoef un2e; EntityType EdgesOf ; NameOfConstraint BlochX; }
EndIf
If(flag_o2i==1) // TODO: Check P3 and P4 (_3E)
// //{ NameOfCoef un3; EntityType FacetsOf ; NameOfConstraint BlochX; }
// { NameOfCoef un4; EntityType EdgesOf ; NameOfConstraint BlochX; }
// //{ NameOfCoef un5; EntityType FacetsOf ; NameOfConstraint BlochX; }
If(flag_o2i==1)
{ NameOfCoef un3f; EntityType EdgesOf ; NameOfConstraint BlochX; }
EndIf
}
}
......@@ -351,8 +352,8 @@ Formulation {
}
}
{Name modal_helmholtz_PEP_h; Type FemEquation;
Quantity {{ Name u ; Type Local; NameOfSpace Hgrad_perp ;}}
// Quantity {{ Name u ; Type Local; NameOfSpace Hgrad ;}}
// Quantity {{ Name u ; Type Local; NameOfSpace Hgrad_perp ;}}
Quantity {{ Name u ; Type Local; NameOfSpace Hgrad ;}}
Equation {
Galerkin { [-1/epsr_nod[]* om_d_1^2 * Dof{d u}, {d u} ]; In Om_2; Jacobian JSur; Integration Int_1;}
Galerkin { Eig[ 1/epsr_nod[]*eps_oo_1*gam_1* Dof{d u}, {d u} ]; Order 1; In Om_2; Jacobian JSur; Integration Int_1;}
......
......@@ -55,13 +55,13 @@ DefineConstant[
paramaille = {4 , Name StrCat[pp4 , "0number of mesh elements per period []"] , Highlight Str[colorpp4], Min 2, Max 10} ,
flag_Tmesh = {0 , Name StrCat[pp4 , "2locally structured mesh?"] , Choices {0="unstruct",1="struct"} },
flag_o2g = {0 , Name StrCat[pp4 , "3Geometrical order"] , Choices {0="order 1 (linear)",1="order 2 (curved)"} },
flag_o2g = {1 , Name StrCat[pp4 , "3Geometrical order"] , Choices {0="order 1 (linear)",1="order 2 (curved)"} },
flag_o2i = {1 , Name StrCat[pp4 , "4Interpolation order"] , Choices {0="order 1",1="full order 2"}, ServerAction "ResetDatabase"},
flag_rounding = {1 , Name StrCat[pp4 , "5Corner rounding/0Do it!"], Choices{0,1}, ServerAction "ResetDatabase"},
corner_rad_frac= {0.1 , Name StrCat[pp4 , "5Corner rounding/1corner radius (fraction of square side)"] , Highlight Str[colorpp2] , Min 0.01, Max 0.49},
flag_rounding = {1 , Name StrCat[pp4 , "5Corner rounding/0Enable rounding of corners!"], Choices{0,1}, ServerAction "ResetDatabase"},
corner_rad_frac= {0.05 , Name StrCat[pp4 , "5Corner rounding/1corner radius (fraction of square side)"] , Highlight Str[colorpp2] , Min 0.005, Max 0.49},
flag_outEigvec = {1 , Name StrCat[pp4 , "7output eigenvector?"], Choices{0,1}},
flag_res = {4 , Name StrCat[pp5 , "0resolution type"],
flag_res = {2 , Name StrCat[pp5 , "0resolution type"],
// Choices {0="Aux_E" ,1="PEP_E" ,2="NEP_E" ,3="Lag_E" ,4="PEP_h", 5="all"},ServerAction "ResetDatabase"},
Choices {0="Aux_E" ,1="PEP_E" ,2="NEP_E" ,3="Lag_E" ,4="PEP_h"},ServerAction "ResetDatabase"}
];
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment