18.11.2012 Views

Advanced Techniques For Greater Accuracy, Capacity and Speed ...

Advanced Techniques For Greater Accuracy, Capacity and Speed ...

Advanced Techniques For Greater Accuracy, Capacity and Speed ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>Advanced</strong> <strong>Techniques</strong> for <strong>Greater</strong><br />

<strong>Accuracy</strong>, <strong>Capacity</strong>, <strong>and</strong> <strong>Speed</strong><br />

using Maxwell 11<br />

Julius Saitz<br />

Ansoft Corporation


Overview<br />

• Curved versus Faceted Surfaces<br />

• Mesh Operations<br />

• Data Link<br />

• <strong>Advanced</strong> Field Plotting <strong>Techniques</strong><br />

• Scripting<br />

• Magnetization modeling<br />

• Useful hints


Curved vs. Faceted Surfaces<br />

• The Maxwell 11 interface encourages the use of curved<br />

surfaces<br />

• Many CAD programs use curved surfaces<br />

• Curved surfaces do not directly translate into a better<br />

solution, due to the nature of the finite tetrahedral mesh<br />

elements – there is always some deviation from the curved<br />

surface <strong>and</strong> the meshed surface<br />

• Using faceted surfaces can be more robust in many cases<br />

• Faceted surfaces may converge in fewer iterations <strong>and</strong><br />

may use fewer mesh elements – therefore, there is a<br />

possible large speed improvement!


Curved vs. Faceted Surfaces<br />

Curved Faceted


Curved vs. Faceted Surfaces<br />

• Calculate force until 1% force change <strong>and</strong> 1% Energy Error<br />

Initial mesh<br />

(tets)<br />

Adaptive<br />

Passes<br />

Final mesh<br />

(tets)<br />

Simulation<br />

Time<br />

Curved Faceted<br />

3331 1535<br />

9 7<br />

22020 7484<br />

03:53 min 01:08 min


Mesh Operations<br />

• Mesh operations provide a tool of manually refining the<br />

mesh in/on selected objects<br />

• The mesh determines both the field solution as well as<br />

the consistency of the results – mesh operations can be<br />

used to assist both<br />

• The initial mesh is determined by the geometry only –<br />

mesh operations improve the mesh consistency <strong>and</strong><br />

improve the solution process – this is especially<br />

important for transient simulations<br />

• Importing or linking a mesh is an advanced mesh<br />

technique that allows for efficient mesh use<br />

• To assign different mesh operation select an object or<br />

face <strong>and</strong> choose Maxwell > Mesh Operations > Assign


Mesh Operations – Surface<br />

Approximation


Mesh Operations – Surface<br />

Initial Surface Normal<br />

Deviation – 5 deg<br />

(default 15 deg)<br />

Approximation<br />

Maximum<br />

Aspect Ratio – 3<br />

(default 10)<br />

Both


Mesh Operations – Skin Depth<br />

Based


Mesh Operations – Skin Depth<br />

Initial<br />

Based<br />

Top <strong>and</strong> bottom face Side face


Mesh Operations – Model<br />

Resolution<br />

Small box subtracted from the cylinder


Mesh Operations – Model<br />

Resolution<br />

• Select the object <strong>and</strong> specify the size of the small feature<br />

that needs to be ignored


Mesh Operations – Model<br />

Resolution<br />

No model resolution Model resolution larger that the small<br />

box edge length


Data Link - Mesh<br />

• <strong>For</strong> identical geometries Maxwell allows to reuse the<br />

existing mesh in another Design or Project through the<br />

Data Link<br />

• As an example consider a solenoid which we wish to solve<br />

at two different current levels for the same position of the<br />

armature:<br />

I1 = 1000 At<br />

I2 = 5000 At


1) Solve Design 1 (5000 At)<br />

using adaptive technology<br />

Data Link - Mesh<br />

2) Link mesh from Design 1 to<br />

Design 2<br />

3) Solve Design 2 (1000 At)


Data Link - Mesh


1) Solve Eddy Current<br />

problem in Maxwell<br />

Data Link - Mesh<br />

2) Link losses (Joule <strong>and</strong><br />

possibly core) from Maxwell to<br />

ePhysics)<br />

3) Solve ePhysics problem for<br />

temperature distribution


<strong>Advanced</strong> Field Plotting<br />

<strong>Techniques</strong><br />

• Multiple windows can be opened <strong>and</strong> arranged to<br />

show geometry, field plots, 2D <strong>and</strong> 3D graphs <strong>and</strong><br />

tables<br />

• Multiple field plots can be created, overlaid <strong>and</strong><br />

displayed in flexible <strong>and</strong> general formats<br />

• Field plots can be animated <strong>and</strong> exported<br />

• Any quantity that can be derived from the solved<br />

quantities can be plotted using the functionality of<br />

the Fields Calculator


Multiple windows


Multiple plots


• Allows to define any arbitrary<br />

expression by manipulating<br />

computed field quantities <strong>and</strong><br />

geometrical <strong>and</strong> mathematical<br />

functions<br />

Fields Calculator<br />

• Example: radial component of B<br />

Brad = Bx*cos(phi) + By*sin(phi)


Plot on a line<br />

• Any calculated quantity or expression defined in the Fields Calculator can<br />

be plotted on a line or surface


Multiple windows with multiple<br />

plots


Surface plot - tone<br />

• Color varies continuously between isovalues


Surface plot - lines<br />

• Lines are drawn along the isovalues


Surface plot – outlined fringe<br />

• Color is constant between isovalues


Multiple surface plot


Animation of slice plots


Transient animation


Current density plot


Transient animation


Scripting<br />

• Scripting is a powerful tool of automation<br />

• In Maxwell everything starting from preprocessing<br />

(geometry creation), materials <strong>and</strong><br />

boundary assignment, through analysis setup,<br />

ending with post-processing <strong>and</strong> export of data<br />

can be scripted<br />

• VB Script used by default (Tools > Record/Run<br />

Script)<br />

• Matlab <strong>and</strong> Java Scripts can be used if desired


Scripting – VB Script<br />

• Simple example: create a regular polyhedron


Scripting – Matlab<br />

• Replace CreateObject comm<strong>and</strong> with actxserver():<br />

Set oAnsoftApp = CreateObject("AnsoftMaxwell.MaxwellScriptInterface")<br />

iMaxwell = actxserver('AnsoftMaxwell.MaxwellScriptInterface');<br />

• Remove Set from the Object definitions:<br />

Set oDesktop = oAnsoftApp.GetAppDesktop()<br />

Desktop = iMaxwell.GetAppDesktop();<br />

• Use Invoke to execute the comm<strong>and</strong>:<br />

oEditor.CreateRegularPolyhedron<br />

invoke(Editor, 'CreateRegularPolyhedron', ...


Scripting – Matlab<br />

• Replace all Arrays with the proper elements enclosed in { }:<br />

• End Maxwell session with:<br />

• <strong>For</strong> any strings replace “ with ‘<br />

Array("NAME:CylinderParameters,…<br />

{'NAME:CylinderParameters',…<br />

Delete(iMaxwell)


Scripting – Matlab<br />

• Simple example: create a regular polyhedron


User Defined Primitives<br />

• Allow automated creation <strong>and</strong> parameterization of complicated<br />

geometrical structures


Radial Magnetization


Radial Magnetization<br />

• Create 2 magnet materials – positive <strong>and</strong> negative<br />

direction of magnetization (R component + 1 <strong>and</strong> -1)<br />

• Choose Cylindrical material coordinate system type


Parallel Magnetization


Parallel Magnetization


Parallel Magnetization


Parallel Magnetization<br />

• Create 2 magnet materials – positive <strong>and</strong> negative direction of<br />

magnetization (X or Y component + 1 <strong>and</strong> -1)<br />

• Choose Cartesian material coordinate system type<br />

• Create as many rotated or face coordinate systems as many there are<br />

magnets in the design<br />

• Associate each magnet with appropriate coordinate system


Arbitrary Magnetization - Script<br />

• Create as many magnet segments as desired (magnet discretization)<br />

• Create as many different materials as many there are segments<br />

• Each material will have a unique Coercive Field, Relative Permeability<br />

<strong>and</strong> Direction of Magnetization<br />

• Assign appropriate material to each magnet segment


Arbitrary Magnetization - Script


Spin<br />

• Observe the geometry or field plot on a self-rotating model<br />

• View > Spin


Select All Object Faces<br />

• Objects may consist of many faces that need to be<br />

selected typically for boundary assignment<br />

• Edit > Select > All Object Faces


Visualize History of Objects<br />

• Visualization is updated on subsequent history playback<br />

• Tools > Options > 3D Modeler Options > Display Tab


Point <strong>and</strong> Dialog Entry Modes<br />

• Editing properties of new primitives: use F3 <strong>and</strong> F4 to<br />

switch between Point <strong>and</strong> Dialog entry modes<br />

Dialog entry mode window


Maxwell Keyboard Shortcuts<br />

General Shortcuts<br />

�F1: Help<br />

�Shift + F1: Context help<br />

�CTRL: + F4: Close program<br />

�CTRL + C: Copy<br />

�CTRL + N: New project<br />

�CTRL + O: Open...<br />

�CTRL + S: Save<br />

�CTRL + P: Print...<br />

�CTRL + V: Paste<br />

�CTRL + X: Cut<br />

�CTRL + Y: Redo<br />

�CTRL + Z: Undo<br />

�CTRL + 0: Cascade windows<br />

�CTRL + 1: Tile windows<br />

horizontally<br />

�CTRL + 2: Tile windows<br />

vertically<br />

3D Modeller Shortcuts<br />

�B: Select face/object behind current<br />

selection<br />

�F: Face select mode<br />

�O: Object select mode<br />

�CTRL + A: Select all visible objects<br />

�CTRL + SHIFT + A: Deselect all<br />

objects<br />

�CTRL + D: Fit view<br />

�CTRL + E: Zoom in, screen center<br />

�CTRL + F: Zoom out, screen center<br />

�CTRL + Enter: Shifts the local<br />

coordinate system temporarily<br />

�SHIFT + Left Mouse Button: Drag<br />

�Alt + Left Mouse Button: Rotate model<br />

�Alt + SHIFT + Left Mouse Button:<br />

Zoom in / out<br />

�F3: Switch to point entry mode (i.e.<br />

draw objects by mouse)<br />

�F4: Switch to dialogue entry mode<br />

(i.e. draw object solely by entry in<br />

comm<strong>and</strong> <strong>and</strong> attributes box.)<br />

�F6: Render model wire frame<br />

�F7: Render model smooth shaded<br />

Left<br />

�Alt + Double Click Left Mouse Button at points<br />

on screen: Sets model projection to st<strong>and</strong>ard<br />

isometric projections (see diagram below).<br />

�ALT + Right Mouse Button + Double Click Left<br />

Mouse Button at points on screen: give the<br />

nine opposite projections.<br />

Predefined View Angles<br />

Top<br />

Bottom<br />

Right


Summary<br />

• Curved surfaces can be conveniently used in Maxwell 11, however,<br />

their usage may slow down the mesh generation <strong>and</strong> solution process<br />

• Maxwell 11 comes with variety of different Mesh Operations that<br />

provide opportunities for user to control the mesh generation if desired<br />

• Data Link technology in Maxwell 11 allows powerful data exchange<br />

between different projects <strong>and</strong> designs within Maxwell as well as<br />

between Maxwell <strong>and</strong> other Ansoft products (e.g. Maxwell – ePhysics)<br />

• Any basic quantity along with any arbitrarily defined expression in<br />

Fields Calculator can be graphically displayed using range of Field<br />

Plotting <strong>Techniques</strong> available in Maxwell 11<br />

• Maxwell 11 is fully scripted which makes from this simulation software<br />

a powerful tool of design automation

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!