[Getdp] 3D a-v - what is different if I use hexahedrons instead oftetrahedrons?

Kubicek Bernhard Bernhard.Kubicek at arsenal.ac.at
Tue Jun 12 14:55:36 CEST 2007


I am quite sorry to say that I don't find a mistake in your .pro at the first glance.
I used to have heavy troubles with hexahedral meshes either, but in my case the problem was that in the Gauge constraint I had multiple Regions:

{ Region Domain_Mag ; SubRegion OuterBoundary1; Value 0.; }
{ Region Domain_Mag ; SubRegion OuterBoundary2; Value 0.; }
This did only (more or less) work with tetrahedral meshes.
The clean solution was to create only one Surface, which you set zero.
But in your .pro, this seems allright.

Another possible problem could be that maybe the numbering of the nodes in the cells is strange, which happend initially when my mesh-conversion routines were still buggy. Maybe one can test with the gmsh-integrate plugin, to check if all cells' volumes are reasonable.

very nice greetings,
 Bernhard

-----Ursprüngliche Nachricht-----
Von: getdp-bounces at geuz.org [mailto:getdp-bounces at geuz.org] Im Auftrag von Thomas Jung
Gesendet: Dienstag, 12. Juni 2007 12:14
An: getdp at geuz.org
Betreff: [Getdp] 3D a-v - what is different if I use hexahedrons instead oftetrahedrons?


Hello there,

I am using a  3D a-v formulation, which works fine for purely tetrahedral meshes (have compared and verified my results with other programs), but not for purely hexagonal meshes. I am absolutely no finite element expert - could someone please give me a hint?

Thank you very much!

Thomas

here the pro-file:


Group {
  Air = Region[101];
  Coil = Region[102];
  GroundZeroBottom = Region[11];
  GroundBottom = Region[12];
  OuterBoundary = Region[{1,2,3,4,5,6}];
  DomainS_Mag = Region[Coil];

  /* all conducting regions */
  DomainC_Mag = Region[Coil];

  /* non-conducting regions = DomainCC_Mag */
  DomainCC_Mag = Region[Air];

  /* entire domain */
  Domain_Mag = Region[{DomainC_Mag, DomainCC_Mag}];
}

// list: time - potential
Include "HeizerUntenSmoothed.dat"

Function {
  epsr[Air] = 1.;
  epsr[Coil] = 1.;
}

Function {
  sigma[Coil]=7.2e4;
  sigma[Air]=0.;
}

Function {
    mu0 = 4.e-7 * Pi;
    nu [ Domain_Mag]  = 1. / mu0;
}

Function {
    Side2[] = 0.2* ($Time<0.002 ?
$Time/0.002:1)*InterpolationLinear[Fmod[$Time,0.02]]{List[HeizerUnten]};
}

Constraint {

  { Name ElectricScalarPotential; Type Assign;
    Case {
      { Region GroundZeroBottom; Value 0.; }
      { Region GroundBottom; Value 1.; TimeFunction Side2[];}
    }
  }

  { Name a; Type Assign;
    Case {
       { Region OuterBoundary ; Value 0.; }
    }
  }

  { Name Gauge; Type Assign;
  Case {
	{ Region Domain_Mag ; SubRegion OuterBoundary; Value 0.; }
    }
  }

}

Jacobian {
  { Name Vol ;
    Case { { Region All; Jacobian Vol; }
    }
  }
}

Integration {
    { Name CurlCurl ;
    Case { {Type Gauss ;
    Case { { GeoElement Triangle    ; NumberOfPoints  4 ; }
    { GeoElement Quadrangle  ; NumberOfPoints  4 ; }
    { GeoElement Tetrahedron    ; NumberOfPoints  4 ; }
    { GeoElement Hexahedron  ; NumberOfPoints  6 ; }
    { GeoElement Pyramid  ; NumberOfPoints  8 ; }
    { GeoElement Prism       ; NumberOfPoints  9 ; } }
    }
    }
    }
}

eps0 = 8.854187818e-12;

Group {
  DefineGroup[ Domain_Mag, DomainS_Mag,DomainCC_Mag, DomainC_Mag ]; }

Function {
  DefineFunction[ epsr ];
}

Function {
  DefineFunction[ sigma ];
}

Function {
    DefineFunction[ nu ];
}

/* for electric potential */

FunctionSpace {
  { Name v_Ele; Type Form0;
    BasisFunction {
      { Name sn; NameOfCoef vn; Function BF_Node;
        Support DomainC_Mag; Entity NodesOf[ All ]; }
    }
    Constraint {
      { NameOfCoef vn; EntityType NodesOf;
        NameOfConstraint ElectricScalarPotential; }
    }
  }

  // Magnetic vector potential a (b = curl a)
  { Name Hcurl_a_Mag_3D; Type Form1;
    BasisFunction {
	{ Name se; NameOfCoef ae; Function BF_Edge;
        Support Domain_Mag; Entity EdgesOf[ All ]; }
    }
    Constraint {
	{ NameOfCoef ae; EntityType EdgesOf;NameOfConstraint a; }
	{ NameOfCoef ae; EntityType EdgesOfTreeIn; EntitySubType StartingOn; NameOfConstraint Gauge; }
    }
  }

}

  { Name MagnetoDynamics_a_3D; Type FemEquation;
    Quantity {
      { Name a ; Type Local; NameOfSpace Hcurl_a_Mag_3D; }
      { Name v; Type Local; NameOfSpace v_Ele; }
    }
    Equation {
	Galerkin { [ nu[] * Dof{d a} , {d a} ]; In Domain_Mag; Jacobian Vol; Integration CurlCurl; }
	Galerkin { DtDof [ sigma[] * Dof{a} , {a} ]; In DomainC_Mag; Jacobian
Vol; Integration CurlCurl; }
	Galerkin { [ sigma[] * Dof{d v} , {a} ]; In DomainC_Mag; Jacobian Vol; Integration CurlCurl; }
	Galerkin { DtDof [ sigma[] * Dof{a} , {d v} ]; In DomainC_Mag;	Jacobian
Vol; Integration CurlCurl; }
	Galerkin { [ sigma[] * Dof{d v} , {d v} ]; In DomainC_Mag; Jacobian
Vol; Integration CurlCurl; }
    }
  }
}

Resolution {

  { Name Magdyn ;
    System {
      { Name A2 ; NameOfFormulation MagnetoDynamics_a_3D;}
    }
    Operation {
	InitSolution[A2]; SaveSolution[A2];
	TimeLoopTheta[0,0.08, 0.0001, 1] {
	 Generate[A2]; Solve[A2];
	    SaveSolution[A2];
        }
    }
  }

}

_______________________________________________
getdp mailing list
getdp at geuz.org
http://www.geuz.org/mailman/listinfo/getdp