File:VFPt cylindrical magnet thumb potential+contour.svg

Original file(SVG file, nominally 220 × 165 pixels, file size: 45 KB)

Captions

Captions

Add a one-line explanation of what this file represents

Summary

edit
Description
English: Magnetic field of an ideal cylindrical magnet with its axis of symmetry inside the image plane. The shape of the magnetic field lines is accurately computed, assuming uniform magnetization along the symmetry axis. The magnetic scalar potential 𝜓 is shown in the background from positive (fuchsia) through zero (yellow) to negative (aqua) together with uniformely spaced equipotential lines.
This is a thumbnail version optimized for 220px.
Date
Source Own work
Author Geek3
Other versions VFPt_cylindrical_magnet_thumb_potential.svg
SVG development
InfoField
 
The SVG code is valid.
 
This plot was created with VectorFieldPlot.
Source code
InfoField

Python code

VectorFieldPlot source
# paste this code at the end of VectorFieldPlot 2.4
doc = FieldplotDocument('VFPt_cylindrical_magnet_thumb_potential+contour',
    width=220, height=165, unit=30, commons=True)
r = 0.5 + 0.5 / 30
Lhalf = 1.5
# note: the two fields are identical outside the magnetized volume
field_B = Field([ ['coil', {'x':0, 'y':0, 'phi':0, 'R':r, 'Lhalf':Lhalf, 'I':1./(pi*r**2)}] ])
field_H = Field([ ['charged_disc', {'x0':Lhalf, 'y0':-r, 'x1':Lhalf, 'y1':r, 'Q':.5/Lhalf}],
                 ['charged_disc', {'x0':-Lhalf, 'y0':-r, 'x1':-Lhalf, 'y1':r, 'Q':-.5/Lhalf}] ])

doc.draw_magnets(field_B)
U0 = field_H.V([Lhalf+1./30., 0])
doc.draw_scalar_field(func=field_H.V, cmap=doc.cmap_AqYlFs, vmin=-U0, vmax=U0)
U1 = field_H.V([Lhalf, 0])
doc.draw_contours(func=field_H.V, levels=sc.linspace(-U1, U1, 17)[1:-1],
    linewidth=0.5, linecolor='#555555')

nlines = 13
for iline in range(nlines):
    a = -1 + 2 * (0.5 + iline) / nlines
    line = FieldLine(field_B, [0, r * a], directions='both', maxr=10.0)
    if iline in [0, nlines-1]:
        ars = {'dist':2.5, 'scale':1.4, 'offsets':{'start':1,
            'end':1, 'leave_image':0.3, 'enter_image':0.3} }
    else:
        ars = {'scale':1.4, 'at_potentials':[-U_arrow, U_arrow],
            'potential':field_H.V,
            'condition_func':lambda xy: fabs(xy[0])>Lhalf or fabs(xy[1])>r }
    doc.draw_line(line, linewidth=1, maxdist=1, arrows_style=ars)
doc.write()

Licensing

edit
I, the copyright holder of this work, hereby publish it under the following license:
w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.
You are free:
  • to share – to copy, distribute and transmit the work
  • to remix – to adapt the work
Under the following conditions:
  • attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
  • share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current19:55, 9 October 2019Thumbnail for version as of 19:55, 9 October 2019220 × 165 (45 KB)Geek3 (talk | contribs)User created page with UploadWizard

There are no pages that use this file.

Metadata