diff --git a/Team25/shape.pro b/Team25/shape.pro index 4ade4b9b09e6c3caf397a9aad028da07f108822c..dc7f4923f67d089f7cfd4499252e9ebc99a5fb9a 100644 --- a/Team25/shape.pro +++ b/Team25/shape.pro @@ -106,7 +106,6 @@ Function{ nu[Region[{Domain,-Core}]] = 1/mu0; // linear dnudb2[] = dInterpolationLinear[SquNorm[$1]]{List[Mat1_nu_b2]} ; - dnudb_1[] = 2.0*dInterpolationLinear[SquNorm[$1]]{List[Mat1_nu_b2]}*SquDyadicProduct[$1]; dhdb_NL[Core] = 2*dnudb2[$1#1] * SquDyadicProduct[#1]; // This is the current density which feeds the inductor. @@ -321,30 +320,34 @@ PostProcessing { } } -PostOperation Get_ObjectiveConstraints UsingPost ObjectiveConstraints { - CreateDir[Opt_ResDir]; - Print[w, - OnGrid {(9.5e-3+2.25e-3)*Cos[$A],(9.5e-3+2.25e-3)*Sin[$A],0}{0:50*Pi/180:5*Pi/180,0,0}, - Format SimpleTable, File StrCat[Opt_ResDir,"w.txt"]]; - Print[bMag, - OnGrid {(9.5e-3+2.25e-3)*Cos[$A],(9.5e-3+2.25e-3)*Sin[$A],0}{0:50*Pi/180:5*Pi/180,0,0}, - Format SimpleTable, File StrCat[Opt_ResDir,"bMag.txt"]]; - Print[az, OnElementsOf Domain, Format NodeTable, File "", - SendToServer StrCat[Opt_ResDir_Onelab,"a"], Hidden 1]; - //Print[bMag, OnElementsOf Domain, File StrCat[Opt_ResDir,"az.pos"]]; - //Print[az, OnElementsOf Domain, File StrCat[Opt_ResDir,"az.pos"]]; - Print[bTarget, OnGrid {(9.5e-3+2.25e-3)*Cos[$A],(9.5e-3+2.25e-3)*Sin[$A],0}{0:50*Pi/180:5*Pi/180,0,0}, - File StrCat[Opt_ResDir,"bTarget.pos"]]; - Print[b, OnGrid {(9.5e-3+2.25e-3)*Cos[$A],(9.5e-3+2.25e-3)*Sin[$A],0}{0:50*Pi/180:5*Pi/180,0,0}, - File StrCat[Opt_ResDir,"b.pos"]]; - If(Flag_PrintLevel>5) - Print[mur, OnElementsOf Domain, File StrCat[Opt_ResDir,"mur.pos"]]; - Print[az, OnElementsOf Domain, File StrCat[Opt_ResDir,"az.pos"]]; - Print[a, OnElementsOf Domain, File StrCat[Opt_ResDir,"a.pos"]]; - Print[b, OnElementsOf Domain, File StrCat[Opt_ResDir,"b.pos"]]; - Print[bMag, OnElementsOf Domain, File StrCat[Opt_ResDir,"bMag.pos"]]; - Print[js, OnElementsOf Coil, File StrCat[Opt_ResDir,"js.pos"]]; - EndIf +PostOperation { + { Name Get_ObjectiveConstraints; NameOfPostProcessing ObjectiveConstraints; + Operation{ + CreateDir[Opt_ResDir]; + Print[w, + OnGrid {(9.5e-3+2.25e-3)*Cos[$A],(9.5e-3+2.25e-3)*Sin[$A],0}{0:50*Pi/180:5*Pi/180,0,0}, + Format SimpleTable, File StrCat[Opt_ResDir,"w.txt"]]; + Print[bMag, + OnGrid {(9.5e-3+2.25e-3)*Cos[$A],(9.5e-3+2.25e-3)*Sin[$A],0}{0:50*Pi/180:5*Pi/180,0,0}, + Format SimpleTable, File StrCat[Opt_ResDir,"bMag.txt"]]; + Print[az, OnElementsOf Domain, Format NodeTable, File "", + SendToServer StrCat[Opt_ResDir_Onelab,"a"], Hidden 1]; + //Print[bMag, OnElementsOf Domain, File StrCat[Opt_ResDir,"az.pos"]]; + //Print[az, OnElementsOf Domain, File StrCat[Opt_ResDir,"az.pos"]]; + Print[bTarget, OnGrid {(9.5e-3+2.25e-3)*Cos[$A],(9.5e-3+2.25e-3)*Sin[$A],0}{0:50*Pi/180:5*Pi/180,0,0}, + File StrCat[Opt_ResDir,"bTarget.pos"]]; + Print[b, OnGrid {(9.5e-3+2.25e-3)*Cos[$A],(9.5e-3+2.25e-3)*Sin[$A],0}{0:50*Pi/180:5*Pi/180,0,0}, + File StrCat[Opt_ResDir,"b.pos"]]; + If(Flag_PrintLevel>5) + Print[mur, OnElementsOf Domain, File StrCat[Opt_ResDir,"mur.pos"]]; + Print[az, OnElementsOf Domain, File StrCat[Opt_ResDir,"az.pos"]]; + Print[a, OnElementsOf Domain, File StrCat[Opt_ResDir,"a.pos"]]; + Print[b, OnElementsOf Domain, File StrCat[Opt_ResDir,"b.pos"]]; + Print[bMag, OnElementsOf Domain, File StrCat[Opt_ResDir,"bMag.pos"]]; + Print[js, OnElementsOf Coil, File StrCat[Opt_ResDir,"js.pos"]]; + EndIf + } + } } // ------------------------------------------------------------------------- @@ -359,9 +362,13 @@ PostProcessing{ } } -PostOperation Get_GradOf_w UsingPost Direct_MagSta { - Print[Lie_w, OnGrid {(9.5e-3+2.25e-3)*Cos[$A],(9.5e-3+2.25e-3)*Sin[$A], 0} { 0:50*Pi/180:5*Pi/180, 0, 0 }, - Format SimpleTable, File StrCat[Opt_ResDir,Sprintf["Grad_w_wrt_dv_%g.txt",VelocityTag]]]; +PostOperation{ + { Name Get_GradOf_w; NameOfPostProcessing Direct_MagSta; + Operation { + Print[Lie_w, OnGrid {(9.5e-3+2.25e-3)*Cos[$A],(9.5e-3+2.25e-3)*Sin[$A], 0} { 0:50*Pi/180:5*Pi/180, 0, 0 }, + Format SimpleTable, File StrCat[Opt_ResDir,Sprintf["Grad_w_wrt_dv_%g.txt",VelocityTag]]]; + } + } } // Show useful data @@ -374,10 +381,14 @@ PostProcessing { } } -PostOperation Show_shape UsingPost Show_shape{ - CreateDir[Opt_ResDir]; - Print[ VV, OnElementsOf Domain,File StrCat[Opt_ResDir, "velocity.pos"] ]; - Print[ Lie_az, OnElementsOf Domain,File StrCat[Opt_ResDir, "Lie_az.pos"] ]; +PostOperation{ + { Name Show_shape; NameOfPostProcessing Show_shape; + Operation { + CreateDir[Opt_ResDir]; + Print[ VV, OnElementsOf Domain,File StrCat[Opt_ResDir, "velocity.pos"] ]; + Print[ Lie_az, OnElementsOf Domain,File StrCat[Opt_ResDir, "Lie_az.pos"] ]; + } + } } // -------------------------------------------------------------------------