Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
tutorials
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
documentation
tutorials
Commits
5f52022f
Commit
5f52022f
authored
5 years ago
by
François Henrotte
Browse files
Options
Downloads
Patches
Plain Diff
reorganization
parent
ed717507
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
Conductors3D/w3d.geo
+5
-6
5 additions, 6 deletions
Conductors3D/w3d.geo
Conductors3D/w3d.pro
+316
-174
316 additions, 174 deletions
Conductors3D/w3d.pro
Conductors3D/w3d_common.pro
+33
-18
33 additions, 18 deletions
Conductors3D/w3d_common.pro
with
354 additions
and
198 deletions
Conductors3D/w3d.geo
+
5
−
6
View file @
5f52022f
...
@@ -6,19 +6,19 @@ Mesh.VolumeEdges = 0; // hide volume edges
...
@@ -6,19 +6,19 @@ Mesh.VolumeEdges = 0; // hide volume edges
Geometry
.
ExactExtrusion
=
0
;
// to allow rotation of extruded shapes
Geometry
.
ExactExtrusion
=
0
;
// to allow rotation of extruded shapes
Solver
.
AutoMesh
=
2
;
// always remesh if necessary (don't reuse mesh on disk)
Solver
.
AutoMesh
=
2
;
// always remesh if necessary (don't reuse mesh on disk)
lc1
=
(
Flag_Thin
)
?
MeshSizeThinWire
*
mm
:
MeshSize
Thin
Wire
*
mm
;
lc1
=
(
Flag_Thin
)
?
MeshSizeThinWire
*
mm
:
MeshSizeWire
*
mm
;
lc2
=
box
/
10
;
// mesh size at outer surface
lc2
=
box
/
10
;
// mesh size at outer surface
llWires
[]
=
{};
llWires
[]
=
{};
centerWires
[]
=
{};
centerWires
[]
=
{};
surfWires
[]
=
{};
surfWires
[]
=
{};
If
(
!
Flag_Thin
||
(
Flag_Thin
&&
Flag_
Corr
==
2
))
If
(
!
Flag_Thin
||
(
Flag_Thin
&&
Flag_
RegSleeve
))
// then circles are in the geometry
// then circles are in the geometry
// their radius is R=rw if Flag_Thin != 0
// their radius is R=rw if Flag_Thin != 0
// or R=rs in the "regular sleeve case" (Flag_Corr == 2)
// or R=rs in the "regular sleeve case" (Flag_Corr == 2)
R
=
(
!
Flag_Thin
)
?
r
w
:
r
s
;
R
=
(
Flag_Thin
)
?
r
s
:
r
w
;
For
i
In
{
1
:
NumWires
}
For
i
In
{
1
:
NumWires
}
pC
=
newp
;
Point
(
pC
)
=
{
WX
~
{
i
}
,
WY
~
{
i
}
,
0
,
lc1
};
pC
=
newp
;
Point
(
pC
)
=
{
WX
~
{
i
}
,
WY
~
{
i
}
,
0
,
lc1
};
...
@@ -96,7 +96,7 @@ If( !Flag_Thin ) // Wires with finite radius
...
@@ -96,7 +96,7 @@ If( !Flag_Thin ) // Wires with finite radius
e
[]
=
Extrude
{
0
,
0
,
Lz
}
{
Surface
{
s1
}
;
/*Layers{1}; Recombine;*/
}
;
e
[]
=
Extrude
{
0
,
0
,
Lz
}
{
Surface
{
s1
}
;
/*Layers{1}; Recombine;*/
}
;
Physical
Volume
(
"AIR"
,
1
)
=
{
e
[
1
]
};
Physical
Volume
(
"AIR"
,
1
)
=
{
e
[
1
]
};
ElseIf
(
Flag_
Corr
==
2
)
// regular sleeve
ElseIf
(
Flag_
RegSleeve
)
// regular sleeve
Wires
[]
=
{};
Wires
[]
=
{};
For
i
In
{
1
:
NumWires
}
For
i
In
{
1
:
NumWires
}
...
@@ -122,19 +122,18 @@ Else
...
@@ -122,19 +122,18 @@ Else
e
[]
=
Extrude
{
0
,
0
,
Lz
}
{
Surface
{
s1
}
;
/*Layers{1}; Recombine;*/
}
;
e
[]
=
Extrude
{
0
,
0
,
Lz
}
{
Surface
{
s1
}
;
/*Layers{1}; Recombine;*/
}
;
s2
=
e
[
0
];
s2
=
e
[
0
];
v1
=
e
[
1
];
v1
=
e
[
1
];
Physical
Volume
(
"AIR"
,
1
)
=
{
v1
};
For
i
In
{
1
:
NumWires
}
For
i
In
{
1
:
NumWires
}
e
[]
=
Extrude
{
0
,
0
,
Lz
}
{
Point
{
centerWires
[
i
-
1
]
}
;
/*Layers{1};*/
}
;
e
[]
=
Extrude
{
0
,
0
,
Lz
}
{
Point
{
centerWires
[
i
-
1
]
}
;
/*Layers{1};*/
}
;
//Printf("e=", e[]);
//Printf("e=", e[]);
Physical
Line
(
Sprintf
(
"LWIRE_%g"
,
i
),
50
+
i
)
=
{
e
[
1
]
};
Physical
Line
(
Sprintf
(
"LWIRE_%g"
,
i
),
50
+
i
)
=
{
e
[
1
]
};
Physical
Point
(
Sprintf
(
"PANODE_%g"
,
i
),
60
+
i
)
=
{
centerWires
[
i
-
1
]
};
Physical
Point
(
Sprintf
(
"PANODE_%g"
,
i
),
60
+
i
)
=
{
centerWires
[
i
-
1
]
};
Physical
Point
(
Sprintf
(
"PCATHODE_%g"
,
i
),
70
+
i
)
=
{
e
[
0
]
};
Physical
Point
(
Sprintf
(
"PCATHODE_%g"
,
i
),
70
+
i
)
=
{
e
[
0
]
};
Physical
Volume
(
"AIR"
,
1
)
=
{
v1
};
// embed line conductors in mesh
// embed line conductors in mesh
Point
{
centerWires
[
i
-
1
]
}
In
Surface
{
s1
};
Point
{
centerWires
[
i
-
1
]
}
In
Surface
{
s1
};
Point
{
e
[
0
]
}
In
Surface
{
s2
};
Point
{
e
[
0
]
}
In
Surface
{
s2
};
Curve
{
e
[
1
]
}
In
Volume
{
v1
};
Curve
{
e
[
1
]
}
In
Volume
{
v1
};
EndFor
EndFor
EndIf
EndIf
Physical
Surface
(
"INF"
,
2
)
=
{
CombinedBoundary
{
Volume
{
:
};
}
};
Physical
Surface
(
"INF"
,
2
)
=
{
CombinedBoundary
{
Volume
{
:
};
}
};
...
...
This diff is collapsed.
Click to expand it.
Conductors3D/w3d.pro
+
316
−
174
View file @
5f52022f
...
@@ -22,7 +22,7 @@ DefineConstant[
...
@@ -22,7 +22,7 @@ DefineConstant[
DefineConstant
[
DefineConstant
[
R_
=
{
"Dynamic"
,
Name
"GetDP/1ResolutionChoices"
,
Visible
0
},
R_
=
{
"Dynamic"
,
Name
"GetDP/1ResolutionChoices"
,
Visible
0
},
C_
=
{
"-sol
-pos
"
,
Name
"GetDP/9ComputeCommand"
,
Visible
0
},
C_
=
{
"-sol
ve -v2
"
,
Name
"GetDP/9ComputeCommand"
,
Visible
0
},
P_
=
{
""
,
Name
"GetDP/2PostOperationChoices"
,
Visible
0
}
P_
=
{
""
,
Name
"GetDP/2PostOperationChoices"
,
Visible
0
}
ResDir
=
"Res/"
ResDir
=
"Res/"
];
];
...
@@ -63,43 +63,33 @@ Group{
...
@@ -63,43 +63,33 @@ Group{
// Abstract regions
// Abstract regions
// Cette formulation peut contenir des conducteurs volumiques Vol_C
// et liniques lVol_C.
If
(
!
Flag_Thin
)
If
(
!
Flag_Thin
)
Vol_C
=
Region
[
VWIRES
];
Vol_C
=
Region
[
VWIRES
];
Vol_CC
=
Region
[
AIR
];
Vol_CC
=
Region
[
AIR
];
//lVol_C = Region[ {} ];
Else
Else
Vol_C
=
Region
[
{
LWIRES
}
];
Vol_C
=
Region
[
{
LWIRES
}
];
Vol_CC
=
Region
[
{
VWIRES
,
AIR
}
];
Vol_CC
=
Region
[
{
VWIRES
,
AIR
}
];
//lVol_C = Region[ LWIRES ];
EndIf
EndIf
Vol_nu
=
Region
[
{
Vol_C
,
Vol_CC
}
];
Vol_nu
=
Region
[
{
Vol_C
,
Vol_CC
}
];
Sur_Dirichlet_a
=
Region
[
INF
];
Sur_Dirichlet_a
=
Region
[
INF
];
Electrodes
=
Region
[
{
ANODES
,
CATHODES
}
];
Electrodes
=
Region
[
{
ANODES
,
CATHODES
}
];
Vol_Tree
=
Region
[
{
Vol_nu
}
];
Sur_Tree
=
Region
[
{
Sur_Dirichlet_a
/*, SKIN*/
}
];
// If( Flag_Corr!= 0 )
// Lin_Tree = Region[ { LWIRES /*, LINTREE*/ } ];
// Else
Lin_Tree
=
Region
[
{}
];
Dom_Hcurl_a
=
Region
[
Vol_nu
];
Dom_Hcurl_a
=
Region
[
Vol_nu
];
Dom_Hgrad_u
=
Region
[
Vol_C
];
Dom_Hgrad_u
=
Region
[
Vol_C
];
//Dom_Hregion_i = Region[ Vol_nu ];
Dom_Hregion_i
=
Region
[
Vol_C
];
// additional Groups for the local correction method
//Dom_Hthin_a = ElementsOf[ Vol_nu, OnOneSideOf LWIRES ];
Dom_Hthin_a
=
Region
[
Vol_nu
];
// additional Groups for the semi_analytic approach
Dom_Hthin_a
=
ElementsOf
[
Vol_nu
,
OnOneSideOf
LWIRES
];
// For integration on the volume elements (excluding line elements)
//Vol_Tree = ElementsOf[ Vol_nu, Not Dom_Hthin_a ];
// of the sleeve
Vol_Tree
=
Region
[
{
Vol_nu
}
];
Vol_Sleeve
=
ElementsOf
[
{
Vol_CC
},
OnOneSideOf
LWIRES
];
Sur_Tree
=
Region
[
{
Sur_Dirichlet_a
/*, SKIN*/
}
];
If
(
!
Flag_SemiAnalytic
)
Lin_Tree
=
Region
[
{}
];
Else
Lin_Tree
=
Region
[
{
LWIRES
}
];
EndIf
}
}
...
@@ -109,13 +99,13 @@ Function{
...
@@ -109,13 +99,13 @@ Function{
mur
=
1.
;
mur
=
1.
;
sigma
=
5.96e7
;
sigma
=
5.96e7
;
i
[]
=
Complex
[
0
,
1
];
mu
[]
=
mu0
;
mu
[]
=
mu0
;
nu
[]
=
1
/
mu
[];
nu
[]
=
1
/
mu
[];
sigma
[]
=
sigma
;
sigma
[]
=
sigma
;
skin_depth
=
Sqrt
[
2
/
(
omega
*
sigma
*
mu0
*
mur
)
];
skin_depth
=
Sqrt
[
2
/
(
omega
*
sigma
*
mu0
*
mur
)
];
// Functions for the semi-analytic approach
i
[]
=
Complex
[
0
,
1
];
tau
[]
=
Complex
[
-
1
,
1
]
/
skin_depth
*
rw
;
tau
[]
=
Complex
[
-
1
,
1
]
/
skin_depth
*
rw
;
J0
[]
=
JnComplex
[
0
,
$
1
];
J0
[]
=
JnComplex
[
0
,
$
1
];
J1
[]
=
JnComplex
[
1
,
$
1
];
J1
[]
=
JnComplex
[
1
,
$
1
];
...
@@ -140,8 +130,8 @@ Function{
...
@@ -140,8 +130,8 @@ Function{
AnalyticStatic_A
[]
=
mu0
/
(
2
*
Pi
)
*
// per Amp
AnalyticStatic_A
[]
=
mu0
/
(
2
*
Pi
)
*
// per Amp
((
$
1
>
rw
)
?
Log
[
rs
/
$
1
]
:
Log
[
rs
/
rw
]
+
mur
*
(
1
-
(
$
1
/
rw
)
^
2
)
/
2
);
((
$
1
>
rw
)
?
Log
[
rs
/
$
1
]
:
Log
[
rs
/
rw
]
+
mur
*
(
1
-
(
$
1
/
rw
)
^
2
)
/
2
);
Analytic_B
[]
=
// per Amp
Analytic_B
[]
=
// per Amp
((
$
1
>
rw
)
?
mu0
/
(
2
*
Pi
*
$
1
)
:
((
$
1
>
=
rw
)
?
mu0
/
(
2
*
Pi
*
$
1
)
:
mu0
*
mur
/
(
2
*
Pi
)
*
J1
[
tau
[]
*
$
1
/
rw
]
/
J1
[
tau
[]]
);
mu0
*
mur
/
(
2
*
Pi
*
rw
)
*
J1
[
tau
[]
*
$
1
/
rw
]
/
J1
[
tau
[]]
);
// Impedance of thin wire p.u. length
// Impedance of thin wire p.u. length
R_DC
=
1.
/
(
sigma
*
A_c
);
R_DC
=
1.
/
(
sigma
*
A_c
);
...
@@ -159,7 +149,7 @@ Function{
...
@@ -159,7 +149,7 @@ Function{
EndIf
EndIf
If
(
NumWires
==
3
)
If
(
NumWires
==
3
)
Exact_B
[]
=
Analytic_B
[
R_1
[]]
+
Analytic_B
[
R_2
[]]
+
Analytic_B
[
R_3
[]]
;
Exact_B
[]
=
Analytic_B
[
R_1
[]]
+
Analytic_B
[
R_2
[]]
+
Analytic_B
[
R_3
[]]
;
Correction_
A
[]
=
((
R_1
[]
<
rs
)
?
Analytic_B
[
R_1
[]]
:
Correction_
B
[]
=
((
R_1
[]
<
rs
)
?
Analytic_B
[
R_1
[]]
:
((
R_2
[]
<
rs
)
?
Analytic_B
[
R_2
[]]
:
((
R_2
[]
<
rs
)
?
Analytic_B
[
R_2
[]]
:
((
R_3
[]
<
rs
)
?
Analytic_B
[
R_3
[]]
:
0
)));
((
R_3
[]
<
rs
)
?
Analytic_B
[
R_3
[]]
:
0
)));
EndIf
EndIf
...
@@ -198,18 +188,18 @@ Constraint{
...
@@ -198,18 +188,18 @@ Constraint{
{
Name
Impose_U
;
{
Name
Impose_U
;
Case
{
Case
{
For
i
In
{
1
:
NumWires
}
For
i
In
{
1
:
NumWires
}
If
(
Flag_
Form
==
1
)
// massive
If
(
!
Flag_
Stranded
)
// massive
{
Region
ANODE
~
{
i
}
;
Value
0
;
}
{
Region
ANODE
~
{
i
}
;
Value
0
;
}
EndIf
EndIf
If
(
Flag_U
)
If
(
Flag_Form
==
1
)
// massive
If
(
Flag_U
)
If
(
!
Flag_Stranded
)
// massive
{
Region
CATHODE
~
{
i
}
;
Value
-
R_DC
*
Lz
*
WI
~
{
i
}
;
}
{
Region
CATHODE
~
{
i
}
;
Value
-
R_DC
*
Lz
*
WI
~
{
i
}
;
}
Else
// stranded
Else
// stranded
{
Region
VWIRE
~
{
i
}
;
Value
-
R_DC
*
Lz
*
WI
~
{
i
}
;
}
{
Region
VWIRE
~
{
i
}
;
Value
-
R_DC
*
Lz
*
WI
~
{
i
}
;
}
EndIf
EndIf
EndIf
EndIf
EndFor
EndFor
}
}
}
}
...
@@ -217,21 +207,19 @@ Constraint{
...
@@ -217,21 +207,19 @@ Constraint{
Case
{
Case
{
For
i
In
{
1
:
NumWires
}
For
i
In
{
1
:
NumWires
}
If
(
!
Flag_U
)
If
(
!
Flag_U
)
If
(
!
Flag_Stranded
)
// massive
If
(
Flag_Form
==
1
)
// massive
{
Region
ANODE
~
{
i
}
;
Value
WI
~
{
i
}
;
}
{
Region
ANODE
~
{
i
}
;
Value
WI
~
{
i
}
;
}
{
Region
CATHODE
~
{
i
}
;
Value
WI
~
{
i
}
;
}
{
Region
CATHODE
~
{
i
}
;
Value
WI
~
{
i
}
;
}
Else
// stranded
Else
// stranded
{
Region
VWIRE
~
{
i
}
;
Value
WI
~
{
i
}
;
}
{
Region
VWIRE
~
{
i
}
;
Value
WI
~
{
i
}
;
}
{
Region
LWIRE
~
{
i
}
;
Value
WI
~
{
i
}
;
}
{
Region
LWIRE
~
{
i
}
;
Value
WI
~
{
i
}
;
}
EndIf
EndIf
EndIf
EndIf
EndFor
EndFor
}
}
}
}
{
Name
Hcurl_a_3D
_ac
;
Type
Assign
;
{
Name
Hcurl_a_3D
;
Type
Assign
;
Case
{
Case
{
{
Region
Region
[
Sur_Dirichlet_a
];
Value
0.
;
}
{
Region
Region
[
Sur_Dirichlet_a
];
Value
0.
;
}
}
}
...
@@ -240,7 +228,27 @@ Constraint{
...
@@ -240,7 +228,27 @@ Constraint{
{
Name
GaugeCondition_a
;
Type
Assign
;
{
Name
GaugeCondition_a
;
Type
Assign
;
Case
{
Case
{
{
Region
Vol_Tree
;
SubRegion
Region
[
{
Sur_Tree
,
Lin_Tree
}
];
{
Region
Vol_Tree
;
SubRegion
Region
[
{
Sur_Tree
,
Lin_Tree
}
];
Value
0.
;
}
Value
0
;
}
}
}
// Semi-analytic approach
{
Name
Impose_corr
;
Case
{
For
i
In
{
1
:
NumWires
}
{
Region
LWIRE
~
{
i
}
;
Value
1.
;
}
EndFor
}
}
{
Name
Hcurl_acorr_3D
;
Type
Assign
;
Case
{
{
Region
Region
[
Sur_Dirichlet_a
];
Value
0.
;
}
If
(
Flag_Thin
)
For
i
In
{
1
:
NumWires
}
{
Region
Region
[
LWIRE
~
{
i
}
];
Value
1
;
}
EndFor
EndIf
}
}
}
}
}
}
...
@@ -256,7 +264,7 @@ FunctionSpace {
...
@@ -256,7 +264,7 @@ FunctionSpace {
}
}
Constraint
{
Constraint
{
{
NameOfCoef
ac
;
{
NameOfCoef
ac
;
EntityType
Auto
;
NameOfConstraint
Hcurl_a_3D
_ac
;
}
EntityType
Auto
;
NameOfConstraint
Hcurl_a_3D
;
}
{
NameOfCoef
ac
;
EntityType
EdgesOfTreeIn
;
EntitySubType
StartingOn
;
{
NameOfCoef
ac
;
EntityType
EdgesOfTreeIn
;
EntitySubType
StartingOn
;
NameOfConstraint
GaugeCondition_a
;
}
NameOfConstraint
GaugeCondition_a
;
}
}
}
...
@@ -280,10 +288,11 @@ FunctionSpace {
...
@@ -280,10 +288,11 @@ FunctionSpace {
}
}
}
}
// Electric current per regionl for stranded conductors
{
Name
Hregion_i_3D
;
Type
Vector
;
{
Name
Hregion_i_3D
;
Type
Vector
;
BasisFunction
{
BasisFunction
{
{
Name
sr
;
NameOfCoef
ir
;
Function
BF_RegionZ
;
{
Name
sr
;
NameOfCoef
ir
;
Function
BF_RegionZ
;
Support
Dom_H
thi
n_
a
;
Entity
Vol_C
;
}
Support
Dom_H
regio
n_
i
;
Entity
Vol_C
;
}
}
}
GlobalQuantity
{
GlobalQuantity
{
{
Name
Is
;
Type
AliasOf
;
NameOfCoef
ir
;
}
{
Name
Is
;
Type
AliasOf
;
NameOfCoef
ir
;
}
...
@@ -295,15 +304,53 @@ FunctionSpace {
...
@@ -295,15 +304,53 @@ FunctionSpace {
}
}
}
}
// For the local correction method
// Function spaces for the semi-analytical approach
{
Name
Hcurl_acorr_3D
;
Type
Form1
;
// { Name Hcurl_acorr_3D; Type Form1;
// BasisFunction {
// { Name sw; NameOfCoef aw; Function BF_Edge;
// Support Dom_Hthin_a; Entity EdgesOf[ Vol_nu, ConnectedTo LWIRES ]; }
// }
// Constraint {
// { NameOfCoef aw;
// EntityType Auto; NameOfConstraint Hcurl_a_3D; }
// { NameOfCoef aw; EntityType EdgesOfTreeIn ; EntitySubType StartingOn ;
// NameOfConstraint GaugeCondition_a ; }
// }
// }
{
Name
Hcurl_athin_3D
;
Type
Form1
;
BasisFunction
{
BasisFunction
{
{
Name
sw
;
NameOfCoef
aw
;
Function
BF_Edge
;
{
Name
si
;
NameOfCoef
ai
;
Function
BF_GroupOfEdges
;
Support
Vol_nu
;
Entity
EdgesOf
[
Vol_nu
,
ConnectedTo
LWIRES
];
}
Support
Dom_Hcurl_a
;
Entity
GroupsOfEdgesOf
[
LWIRES
];
}
{
Name
sj
;
NameOfCoef
aj
;
Function
BF_Edge
;
Support
Dom_Hcurl_a
;
Entity
EdgesOf
[
Vol_nu
,
Not
LWIRES
];
}
}
GlobalQuantity
{
{
Name
F
;
Type
AliasOf
;
NameOfCoef
ai
;
}
{
Name
I
;
Type
AssociatedWith
;
NameOfCoef
ai
;
}
}
}
Constraint
{
Constraint
{
// { NameOfCoef aw; EntityType EdgesOfTreeIn ; EntitySubType StartingOn ;
{
NameOfCoef
I
;
EntityType
Region
;
NameOfConstraint
Impose_corr
;
}
// NameOfConstraint GaugeCondition_a ; }
{
NameOfCoef
aj
;
EntityType
Auto
;
NameOfConstraint
Hcurl_a_3D
;
}
{
NameOfCoef
aj
;
EntityType
EdgesOfTreeIn
;
EntitySubType
StartingOn
;
NameOfConstraint
GaugeCondition_a
;
}
}
}
{
Name
Hcurl_asleeve_3D
;
Type
Form1
;
BasisFunction
{
{
Name
si
;
NameOfCoef
ai
;
Function
BF_GroupOfEdges
;
Support
Dom_Hthin_a
;
Entity
GroupsOfEdgesOf
[
LWIRES
];
}
{
Name
sj
;
NameOfCoef
aj
;
Function
BF_Edge
;
Support
Dom_Hthin_a
;
Entity
EdgesOf
[
Vol_nu
,
ConnectedTo
LWIRES
];
}
}
GlobalQuantity
{
{
Name
F
;
Type
AliasOf
;
NameOfCoef
ai
;
}
{
Name
I
;
Type
AssociatedWith
;
NameOfCoef
ai
;
}
}
Constraint
{
{
NameOfCoef
I
;
EntityType
Region
;
NameOfConstraint
Impose_corr
;
}
{
NameOfCoef
aj
;
EntityType
Auto
;
NameOfConstraint
Hcurl_a_3D
;
}
}
}
}
}
}
}
...
@@ -311,7 +358,11 @@ FunctionSpace {
...
@@ -311,7 +358,11 @@ FunctionSpace {
Formulation
{
Formulation
{
{
Name
MagnetoDynamics
;
Type
FemEquation
;
{
Name
MagnetoDynamics
;
Type
FemEquation
;
If
(
Flag_Form
==
1
)
// Massive conductor
If
(
!
Flag_SemiAnalytic
)
// Conventional massive and stranded conductor formulation
// If Flag_Thin is true, naive thine wire formulations
If
(
!
Flag_Stranded
)
// Massive conductor
Quantity
{
Quantity
{
{
Name
a
;
Type
Local
;
NameOfSpace
Hcurl_a_3D
;
}
{
Name
a
;
Type
Local
;
NameOfSpace
Hcurl_a_3D
;
}
...
@@ -337,7 +388,6 @@ Formulation {
...
@@ -337,7 +388,6 @@ Formulation {
}
}
Else
// stranded conductor
Else
// stranded conductor
If
(
Flag_Corr
==
0
)
// naive thin wire model
Quantity
{
Quantity
{
{
Name
a
;
Type
Local
;
NameOfSpace
Hcurl_a_3D
;
}
{
Name
a
;
Type
Local
;
NameOfSpace
Hcurl_a_3D
;
}
...
@@ -363,27 +413,37 @@ Formulation {
...
@@ -363,27 +413,37 @@ Formulation {
In
Vol_C
;
Jacobian
Vol
;
Integration
I1
;}
In
Vol_C
;
Jacobian
Vol
;
Integration
I1
;}
GlobalTerm
{
[
Dof
{
Us
}
*
A_c
,
{
Is
}
];
In
Vol_C
;
}
GlobalTerm
{
[
Dof
{
Us
}
*
A_c
,
{
Is
}
];
In
Vol_C
;
}
}
}
Else
// use local correction method
EndIf
EndIf
If
(
Flag_SemiAnalytic
)
// Semi-analytic correction methods
Quantity
{
Quantity
{
{
Name
a
;
Type
Local
;
NameOfSpace
Hcurl_a_3D
;
}
{
Name
a
;
Type
Local
;
NameOfSpace
Hcurl_athin_3D
;
}
{
Name
as
;
Type
Local
;
NameOfSpace
Hcurl_acorr_3D
;
}
{
Name
F
;
Type
Global
;
NameOfSpace
Hcurl_athin_3D
[
F
];
}
{
Name
I
;
Type
Global
;
NameOfSpace
Hcurl_athin_3D
[
I
];
}
{
Name
i
;
Type
Local
;
NameOfSpace
H
region_i
_3D
;
}
{
Name
as
;
Type
Local
;
NameOfSpace
H
curl_asleeve
_3D
;
}
{
Name
I
s
;
Type
Global
;
NameOfSpace
H
region_i
_3D
[
Is
];
}
{
Name
F
s
;
Type
Global
;
NameOfSpace
H
curl_asleeve
_3D
[
F
];
}
{
Name
U
s
;
Type
Global
;
NameOfSpace
H
region_i
_3D
[
Us
];
}
{
Name
I
s
;
Type
Global
;
NameOfSpace
H
curl_asleeve
_3D
[
I
];
}
}
}
Equation
{
Equation
{
/*
Integral
{
[
nu
[]
*
Dof
{
d
a
}
,
{
d
a
}
];
Integral
{
[
nu
[]
*
Dof
{
d
a
}
,
{
d
a
}
];
In
Vol_nu
;
Jacobian
Vol
;
Integration
I1
;
}
In
Vol_nu
;
Jacobian
Vol
;
Integration
I1
;
}
Integral
{ [ -Dof{
i}/A_c
, {
a
} ];
GlobalTerm
{
[
-
Dof
{
I
}
*
1e1
,
{
F
}
];
In Vol_
C; Jacobian Vol; Integration I1
; }
In
Vol_
nu
;
}
*/
Integral
{
[
nu
[]
*
Dof
{
d
as
}
,
{
d
as
}
];
Integral
{
[
nu
[]
*
Dof
{
d
as
}
,
{
d
as
}
];
In
Vol_nu
;
Jacobian
Vol
;
Integration
I1
;
}
In
Vol_nu
;
Jacobian
Vol
;
Integration
I1
;
}
Integral
{
[
-
Dof
{
i
}
/
A_c
,
{
as
}
];
GlobalTerm
{
[
-
Dof
{
Is
}
*
1e1
,
{
Fs
}
];
In
Vol_C
;
Jacobian
Vol
;
Integration
I1
;
}
In
Vol_nu
;
}
// Integral { [ -Dof{i}/A_c , {as} ];
// In Vol_C; Jacobian Vol; Integration I1; }
/*
/*
GlobalTerm { [ Analytic_R[] * Dof{Is} , {Is} ];
GlobalTerm { [ Analytic_R[] * Dof{Is} , {Is} ];
...
@@ -399,7 +459,6 @@ Formulation {
...
@@ -399,7 +459,6 @@ Formulation {
*/
*/
}
}
EndIf
EndIf
EndIf
}
}
}
}
...
@@ -443,10 +502,25 @@ PostProcessing {
...
@@ -443,10 +502,25 @@ PostProcessing {
{
Name
b
;
{
Name
b
;
Value
{
Local
{
[
{
d
a
}];
In
Dom_Hcurl_a
;
Jacobian
Vol
;
}}}
Value
{
Local
{
[
{
d
a
}];
In
Dom_Hcurl_a
;
Jacobian
Vol
;
}}}
{
Name
by
;
{
Name
by
;
Value
{
Local
{
[
Re
[
Cart2Pol
[
CompY
[
{
d
a
}]]
]
];
Value
{
Local
{
[
Cart2Pol
[
Norm
[
{
d
a
}]]
];
In
Dom_Hcurl_a
;
Jacobian
Vol
;
}}}
In
Dom_Hcurl_a
;
Jacobian
Vol
;
}}}
If
(
Flag_Form
==
1
)
// massive
If
(
Flag_SemiAnalytic
)
{
Name
bs
;
Value
{
Local
{
[
{
d
as
}
];
In
Vol_nu
;
Jacobian
Vol
;
}}}
{
Name
bsy
;
Value
{
Local
{
[
Norm
[
{
d
as
}
]
];
In
Vol_nu
;
Jacobian
Vol
;
}}}
{
Name
bbsy
;
Value
{
Local
{
[
Norm
[
{
d
a
}
-
{
d
as
}
]
];
In
Vol_nu
;
Jacobian
Vol
;
}}}
{
Name
bcorry
;
Value
{
Local
{
[
Norm
[
{
d
a
}
-
{
d
as
}
]
+
Correction_B
[]
];
In
Vol_nu
;
Jacobian
Vol
;
}}}
EndIf
If
(
!
Flag_SemiAnalytic
)
If
(
!
Flag_Stranded
)
// massive
{
Name
J
;
{
Name
J
;
Value
{
Local
{
[
-
sigma
[]
*
(
Dt
[{
a
}]
+
{
d
v
}
)
];
Value
{
Local
{
[
-
sigma
[]
*
(
Dt
[{
a
}]
+
{
d
v
}
)
];
In
Vol_C
;
Jacobian
Vol
;
}}}
In
Vol_C
;
Jacobian
Vol
;
}}}
...
@@ -460,7 +534,7 @@ PostProcessing {
...
@@ -460,7 +534,7 @@ PostProcessing {
Value
{
Term
{
[
Im
[
-
{
U
}
/
{
I
}
/
omega
/
Lz
]
];
In
Electrodes
;
}}}
Value
{
Term
{
[
Im
[
-
{
U
}
/
{
I
}
/
omega
/
Lz
]
];
In
Electrodes
;
}}}
Else
// stranded
Else
// stranded
{
Name
J
;
{
Name
J
;
Value
{
Local
{
[
{
i
}
/
A_c
];
Value
{
Local
{
[
{
Is
}
/
A_c
];
In
Vol_C
;
Jacobian
Vol
;
}}}
In
Vol_C
;
Jacobian
Vol
;
}}}
{
Name
U
;
{
Name
U
;
Value
{
Term
{
[
{
Us
}
];
In
Vol_C
;
}}}
Value
{
Term
{
[
{
Us
}
];
In
Vol_C
;
}}}
...
@@ -471,13 +545,22 @@ PostProcessing {
...
@@ -471,13 +545,22 @@ PostProcessing {
{
Name
L
;
// actually total flux/I
{
Name
L
;
// actually total flux/I
Value
{
Term
{
[
Im
[
-
{
Us
}
/
{
Is
}
/
omega
/
Lz
]
];
In
Vol_C
;
}}}
Value
{
Term
{
[
Im
[
-
{
Us
}
/
{
Is
}
/
omega
/
Lz
]
];
In
Vol_C
;
}}}
EndIf
EndIf
EndIf
If
(
(
Flag_Form
==
2
)
&&
Flag_Corr
)
If
(
Flag_SemiAnalytic
)
{
Name
bs
;
{
Name
F
;
Value
{
Local
{
[
{
d
as
}];
In
Dom_Hthin_a
;
Jacobian
Vol
;
}}}
Value
{
Term
{
[
{
F
}
];
In
Vol_C
;
}}}
{
Name
bcorry
;
{
Name
I
;
Value
{
Local
{
[
Re
[
Cart2Pol
[
CompY
[{
d
a
}
-
{
d
as
}]]]
+
Correction_B
[]
];
Value
{
Term
{
[
{
I
}
];
In
Vol_C
;
}}}
In
Dom_Hthin_a
;
Jacobian
Vol
;
}}}
{
Name
J
;
Value
{
Local
{
[
{
I
}
/
A_c
];
In
Vol_C
;
Jacobian
Vol
;
}}}
{
Name
U
;
Value
{
Term
{
[
i
[]
*
omega
*
{
F
}
*
10
+
Analytic_R
[]
*
{
I
}
];
In
Vol_C
;
}}}
{
Name
R
;
Value
{
Term
{
[
Analytic_R
[]
+
{
I
}
*
0
];
In
Vol_C
;
}}}
{
Name
L
;
// actually total flux/I
Value
{
Term
{
[
{
F
}
/
{
I
}
/
Lz
];
In
Vol_C
;
}}}
EndIf
EndIf
}
}
...
@@ -485,19 +568,26 @@ PostProcessing {
...
@@ -485,19 +568,26 @@ PostProcessing {
}
}
PostOperation
map
UsingPost
MagnetoDynamics
{
PostOperation
map
UsingPost
MagnetoDynamics
{
Print
[
J
,
OnElementsOf
Vol_C
,
File
"j.pos"
];
Print
[
b
,
OnElementsOf
Vol_nu
,
File
"b.pos"
];
Print
[
b
,
OnElementsOf
Vol_nu
,
File
"b.pos"
];
If
(
(
Flag_Form
==
2
)
&&
Flag_Corr
)
If
(
!
Flag_SemiAnalytic
)
Print
[
J
,
OnElementsOf
Vol_C
,
File
"j.pos"
];
Else
Print
[
bs
,
OnElementsOf
Vol_nu
,
File
"bs.pos"
];
Print
[
bs
,
OnElementsOf
Vol_nu
,
File
"bs.pos"
];
PrintGroup
[
EdgesOf
[
Vol_nu
,
ConnectedTo
LWIRES
],
PrintGroup
[
EdgesOf
[
Vol_nu
,
ConnectedTo
LWIRES
],
In
Vol_nu
,
File
"group.pos"
];
In
Vol_nu
,
File
"group.pos"
];
EndIf
EndIf
PrintGroup
[
EdgesOfTreeIn
[
{
Vol_Tree
},
StartingOn
{
Sur_Tree
,
Lin_Tree
}
],
In
Vol_Tree
,
File
"Tree.pos"
];
//PrintGroup[ _CO_Entity_44, In Vol_nu, File "Tree.pos"];
}
}
PostOperation
integaz
UsingPost
MagnetoDynamics
{
PostOperation
integaz
UsingPost
MagnetoDynamics
{
For
i
In
{
1
:
NumWires
}
For
i
In
{
1
:
NumWires
}
If
(
Flag_
Form
==
1
)
// massive
If
(
!
Flag_
SemiAnalytic
)
If
(
!
Flag_Stranded
)
// massive
Print
[
U
,
OnRegion
CATHODES
,
File
>
"U.dat"
,
Format
Table
,
Print
[
U
,
OnRegion
CATHODES
,
File
>
"U.dat"
,
Format
Table
,
SendToServer
Sprintf
[
"Results/1Voltage/Wire %g"
,
i
]];
SendToServer
Sprintf
[
"Results/1Voltage/Wire %g"
,
i
]];
Print
[
I
,
OnRegion
CATHODES
,
File
>
"I.dat"
,
Format
Table
,
Print
[
I
,
OnRegion
CATHODES
,
File
>
"I.dat"
,
Format
Table
,
...
@@ -516,14 +606,28 @@ PostOperation integaz UsingPost MagnetoDynamics {
...
@@ -516,14 +606,28 @@ PostOperation integaz UsingPost MagnetoDynamics {
Print
[
L
,
OnRegion
Vol_C
,
File
>
"Z.dat"
,
Format
Table
,
Print
[
L
,
OnRegion
Vol_C
,
File
>
"Z.dat"
,
Format
Table
,
SendToServer
Sprintf
[
"Results/4Inductance p.u.l./Wire %g"
,
i
]];
SendToServer
Sprintf
[
"Results/4Inductance p.u.l./Wire %g"
,
i
]];
EndIf
EndIf
EndIf
If
(
Flag_SemiAnalytic
)
Print
[
F
,
OnRegion
Vol_C
,
File
>
"Flux.dat"
,
Format
Table
,
SendToServer
Sprintf
[
"Results/0Flux/Wire %g"
,
i
]];
Print
[
U
,
OnRegion
Vol_C
,
File
>
"U.dat"
,
Format
Table
,
SendToServer
Sprintf
[
"Results/1Voltage/Wire %g"
,
i
]];
Print
[
I
,
OnRegion
Vol_C
,
File
>
"I.dat"
,
Format
Table
,
SendToServer
Sprintf
[
"Results/2Current/Wire %g"
,
i
]];
Print
[
R
,
OnRegion
Vol_C
,
File
>
"Z.dat"
,
Format
Table
,
SendToServer
Sprintf
[
"Results/3Resistance p.u.l./Wire %g"
,
i
]];
Print
[
L
,
OnRegion
Vol_C
,
File
>
"Z.dat"
,
Format
Table
,
SendToServer
Sprintf
[
"Results/4Inductance p.u.l./Wire %g"
,
i
]];
EndIf
EndFor
EndFor
}
}
NbPoints
=
400
;
NbPoints
=
1000
;
Xmax
=
0.15
*
box
;
Xcut
=
0.1
*
box
;
Zcut
=
Lz
/
2
;
PostOperation
cut
UsingPost
MagnetoDynamics
{
PostOperation
cut
UsingPost
MagnetoDynamics
{
Print
[
by
,
OnLine
{
{
-
X
max
,
0
,
0
}
{
X
max
,
0
,
0
}
}{
NbPoints
},
Print
[
by
,
OnLine
{
{
-
X
cut
,
0
,
0
}
{
X
cut
,
0
,
Zcut
}
}{
NbPoints
},
Format
Gmsh
,
File
"by.pos"
];
Format
Gmsh
,
File
"by.pos"
];
Echo
[
StrCat
[
"l=PostProcessing.NbViews-1;"
,
Echo
[
StrCat
[
"l=PostProcessing.NbViews-1;"
,
"View[l].Name = 'cut by';"
,
"View[l].Name = 'cut by';"
,
...
@@ -531,15 +635,53 @@ PostOperation cut UsingPost MagnetoDynamics {
...
@@ -531,15 +635,53 @@ PostOperation cut UsingPost MagnetoDynamics {
"View[l].LineWidth = 3;"
,
"View[l].LineWidth = 3;"
,
"View[l].Type = 2;"
],
"View[l].Type = 2;"
],
File
"tmp.geo"
,
LastTimeStepOnly
];
File
"tmp.geo"
,
LastTimeStepOnly
];
If
(
(
Flag_Form
==
2
)
&&
Flag_Corr
)
Print
[
bcorry
,
OnLine
{
{
-
Xmax
,
0
,
0
}
{
Xmax
,
0
,
0
}
}{
NbPoints
},
If
(
Flag_SemiAnalytic
)
Format
Gmsh
,
File
"by.pos"
];
Print
[
bsy
,
OnLine
{
{
-
Xcut
,
0
,
0
}
{
Xcut
,
0
,
Zcut
}
}{
NbPoints
},
Format
Gmsh
,
File
"bcorry.pos"
];
Echo
[
StrCat
[
"l=PostProcessing.NbViews-1;"
,
Echo
[
StrCat
[
"l=PostProcessing.NbViews-1;"
,
"View[l].Name = 'cut b
y
';"
,
"View[l].Name = 'cut b
sy
';"
,
"View[l].Axes = 3;"
,
"View[l].Axes = 3;"
,
"View[l].LineWidth = 3;"
,
"View[l].LineWidth = 3;"
,
"View[l].Type = 2;"
],
"View[l].Type = 2;"
],
File
"tmp.geo"
,
LastTimeStepOnly
];
File
"tmp.geo"
,
LastTimeStepOnly
];
Print
[
bbsy
,
OnLine
{
{
-
Xcut
,
0
,
0
}
{
Xcut
,
0
,
Zcut
}
}{
NbPoints
},
Format
Gmsh
,
File
"bcorry.pos"
];
Echo
[
StrCat
[
"l=PostProcessing.NbViews-1;"
,
"View[l].Name = 'cut by-bsy ';"
,
"View[l].Axes = 3;"
,
"View[l].LineWidth = 3;"
,
"View[l].Type = 2;"
],
File
"tmp.geo"
,
LastTimeStepOnly
];
Print
[
bcorry
,
OnLine
{
{
-
Xcut
,
0
,
0
}
{
Xcut
,
0
,
Zcut
}
}{
NbPoints
},
Format
Gmsh
,
File
"bcorry.pos"
];
Echo
[
StrCat
[
"l=PostProcessing.NbViews-1;"
,
"View[l].Name = 'cut by corrected';"
,
"View[l].Axes = 3;"
,
"View[l].LineWidth = 3;"
,
"View[l].Type = 2;"
],
File
"tmp.geo"
,
LastTimeStepOnly
];
EndIf
// cuts in txt format for Gnuplot
// Print [ exact, OnLine { {0,0,0} {Xcut,0,0} } {NbPoints},
// Format SimpleTable, File "Cut_analytic.txt" ];
If
(
!
Flag_SemiAnalytic
)
Print
[
by
,
OnLine
{
{
0
,
0
,
0
}
{
Xcut
,
0
,
0
}
}
{
NbPoints
},
Format
SimpleTable
,
File
"Cut_byref.txt"
];
Else
Print
[
by
,
OnLine
{
{
0
,
0
,
0
}
{
Xcut
,
0
,
0
}
}
{
NbPoints
},
Format
SimpleTable
,
File
"Cut_by.txt"
];
Print
[
bsy
,
OnLine
{
{
0
,
0
,
0
}
{
Xcut
,
0
,
0
}
}
{
NbPoints
},
Format
SimpleTable
,
File
"Cut_bsy.txt"
];
Print
[
bbsy
,
OnLine
{
{
0
,
0
,
0
}
{
Xcut
,
0
,
0
}
}
{
NbPoints
},
Format
SimpleTable
,
File
"Cut_bbsy.txt"
];
Print
[
bcorry
,
OnLine
{
{
0
,
0
,
0
}
{
Xcut
,
0
,
0
}
}
{
NbPoints
},
Format
SimpleTable
,
File
"Cut_bcorry.txt"
];
EndIf
EndIf
}
}
...
...
This diff is collapsed.
Click to expand it.
Conductors3D/w3d_common.pro
+
33
−
18
View file @
5f52022f
...
@@ -4,32 +4,43 @@ deg = 180/Pi;
...
@@ -4,32 +4,43 @@ deg = 180/Pi;
/*
/*
Expected inductance of a rectilinear 1mm radius wire: 4 nH/cm
Expected inductance of a rectilinear 1mm radius wire: 4 nH/cm
git/documentation/models/Inductor/magstadyn_av_js0_3d.pro
*/
*/
DefineConstant
[
DefineConstant
[
NumWires
=
{
1
,
Name
"Parameters/0Number of wires"
,
NumWires
=
{
1
,
Name
"Parameters/
0
0Number of wires"
,
Choices
{
1
=
"1"
,
2
=
"2"
,
3
=
"3"
},
Visible
1
}
Choices
{
1
=
"1"
,
2
=
"2"
,
3
=
"3"
},
Visible
1
}
Flag_Form
=
{
2
,
Name
"Parameters/1Conductor type"
,
Visible
1
,
Choices
{
1
=
"Massive"
,
2
=
"Stranded"
}}
Flag_Thin
=
{
1
,
Name
"Parameters/01Thin wires"
,
Flag_Thin
=
{
1
,
Name
"Parameters/2Use thin wires"
,
Choices
{
0
,
1
},
Visible
1
}
Choices
{
0
,
1
},
Visible
1
}
Flag_Corr
=
{
1
,
Name
"Parameters/3Correction method"
,
Flag_RegSleeve
=
{
0
,
Name
"Parameters/02Regular sleeves"
,
Visible
(
Flag_Form
==
2
)
&&
Flag_Thin
,
Choices
{
0
,
1
},
Visible
Flag_Thin
}
Choices
{
0
=
"None"
,
1
=
"Raw sleeve"
,
2
=
"regular sleeve"
}}
Flag_U
=
{
0
,
Name
"Parameters/4Impose U"
,
Choices
{
0
,
1
},
Visible
1
}
Flag_SemiAnalytic
=
{
1
,
Name
"Parameters/03Semi-analytic approach"
,
Choices
{
0
,
1
},
Visible
Flag_Thin
}
Flag_Stranded
=
{
0
,
Name
"Parameters/04Stranded conductors"
,
Choices
{
0
,
1
},
Visible
!
Flag_SemiAnalytic
||
!
Flag_Thin
}
Flag_Dual
=
{
0
,
Name
"Parameters/05Dual approach"
,
Choices
{
0
,
1
},
Visible
Flag_SemiAnalytic
&&
Flag_Thin
}
Flag_U
=
{
0
,
Name
"Parameters/06Impose U"
,
Choices
{
0
,
1
},
Visible
1
}
WireRadius
=
{
1
,
Name
"Parameters/10Wire radius [mm]"
}
MeshSizeWire
=
{
0.25
,
Name
"Parameters/11Mesh size in wire [mm]"
,
Visible
!
Flag_Thin
}
MeshSizeThinWire
=
{
2
,
Name
"Parameters/12Mesh size on thin wire [mm]"
,
Visible
Flag_Thin
}
//SleeveRadius = {2, Name "Parameters/13Sleeve radius [mm]", Visible Flag_RegSleeve}
box
=
{
100
*
mm
,
Name
"Parameters/5box half-width [m]"
}
Flag_Maps
=
{
1
,
Name
"Input/2Display maps"
,
Choices
{
0
,
1
},
Visible
1
}
Flag_Maps
=
{
1
,
Name
"Input/2Display maps"
,
Choices
{
0
,
1
},
Visible
1
}
LogFreq
=
{
4
,
Min
1
,
Max
8
,
Step
0.25
,
Name
"Input/4Log of frequency"
}
LogFreq
=
{
4
,
Min
1
,
Max
8
,
Step
0.25
,
Name
"Input/4Log of frequency"
}
Freq
=
10
^
LogFreq
Freq
=
10
^
LogFreq
WireRadius
=
{
1
,
Name
"Parameters/5Wire radius [mm]"
}
MeshSizeWire
=
{
1
,
Name
"Parameters/6Mesh size in wire [mm]"
,
Visible
!
Flag_Thin
}
MeshSizeThinWire
=
{
1
,
Name
"Parameters/7Mesh size on thin wire [mm]"
,
Visible
Flag_Thin
}
SleeveRadius
=
{
2
,
Name
"Parameters/8Sleeve radius [mm]"
}
box
=
{
100
*
mm
,
Name
"Parameters/9box half-width [m]"
}
rw
=
WireRadius
*
mm
rw
=
WireRadius
*
mm
rs
=
SleeveRadius
*
mm
rs
=
MeshSizeThinWire
*
mm
A_c
=
Pi
*
rw
^
2
// wire cross section
A_c
=
Pi
*
rw
^
2
// wire cross section
rout
=
box
rout
=
box
Lz
=
10
*
mm
Lz
=
10
*
mm
...
@@ -41,6 +52,10 @@ DefineConstant[
...
@@ -41,6 +52,10 @@ DefineConstant[
*/
*/
];
];
If
(
Flag_SemiAnalytic
)
SetNumber
(
"Parameters/01Thin wires"
,
1
);
Flag_Thin
=
1
;
EndIf
Xlocs
()
=
{
0
,
5
*
mm
,
-
5
*
mm
};
Xlocs
()
=
{
0
,
5
*
mm
,
-
5
*
mm
};
...
@@ -50,7 +65,7 @@ For i In {1:NumWires}
...
@@ -50,7 +65,7 @@ For i In {1:NumWires}
WX
~
{
i
}
=
{
Xlocs
(
i
-
1
),
// place wires symmetrically around x=0
WX
~
{
i
}
=
{
Xlocs
(
i
-
1
),
// place wires symmetrically around x=0
Name
Sprintf
(
"Parameters/Wire %g/0X position [m]"
,
i
),
Closed
}
Name
Sprintf
(
"Parameters/Wire %g/0X position [m]"
,
i
),
Closed
}
WY
~
{
i
}
=
{
Ylocs
(
i
-
1
),
Name
Sprintf
(
"Parameters/Wire %g/0Y position [m]"
,
i
)
}
WY
~
{
i
}
=
{
Ylocs
(
i
-
1
),
Name
Sprintf
(
"Parameters/Wire %g/0Y position [m]"
,
i
)
}
WI
~
{
i
}
=
{
1
.23456
,
Name
Sprintf
(
"Parameters/Wire %g/2Current [A]"
,
i
)
}
WI
~
{
i
}
=
{
1
,
Name
Sprintf
(
"Parameters/Wire %g/2Current [A]"
,
i
)
}
WP
~
{
i
}
=
{
0
*
NumWires
*
(
i
-
1
),
WP
~
{
i
}
=
{
0
*
NumWires
*
(
i
-
1
),
Name
Sprintf
(
"Parameters/Wire %g/3Phase [deg]"
,
i
)
}
Name
Sprintf
(
"Parameters/Wire %g/3Phase [deg]"
,
i
)
}
];
];
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment