Field Precision title

Mapper: creating field maps from midplane data

Information on 3D electric and/or magnetic fields can be ported to the OmniTrak program for charged-particle beam physics in two forms:

  • Finite-element field solutions from HiPhi or Magnum.
  • Maps of field values on a regular grid.

With regard to the second option, the Mapper program supplied with OmniTrak is one source of field maps. In Mapper, the user enters the geometry of poles or electrodes to derive a midplane approximation for dipole-type fields. Approximate off-midplane values are then determined from field expansions.

In a recent consulting job to characterize a spectrometer, I was supplied with a measured set of midplane field values for a dipole magnet. I realized that it would take relatively small modifications to include such data in Mapper calculations. Given midplane values, I could take advantage of existing Mapper features to calculation off-midplane fields and to create maps that could be imported directly into OmniTrak.

The measured field values were contained in a spreadsheet of Bz values on a regular grid of the form

 x0 x1 x2 ...
 y0 B00 B10 B20
 y1 B10 B11 B21
 y2 B20 B21 B23
 ...

This ordering was well-matched to that of OmniTrak field maps. I copied the block of Bij values in Open Office Calc and pasted it into the TextPad text editor (in tab-delimited form). Using the capability to operate on regular expressions, I then did a global search and replacement, changing \t (tab) to \n (return). The resulting document had entries in the sequential form

 B00
 B10
 B20
 ...
 B10
 B11
 B21
 ...

The values could be read with the loop

DO J=0, JMax
  DO I=0, IMax
   ...
  END DO
END DO

In the standard midplane map file, the data values are preceeded by a header of the form:

 B (Map type, E or B)
 58 IMax
 15.0 XMin
 305.0 XMax
 40 JMax
 80.0 YMin
 280.0 YMax
 20 KMax
 -10.0 ZMin
 10.0 ZMax
 1000.0 DUnit (Units per meter)
 10000.0 BConv (Units per tesla)

The x-y values in the header define the characteristics of the midplane data. The z values give the desired vertical range of the three-dimensional map. In the example, the value DUnit = 1000.0 implies that coordinates are specified in millimeters and BConv = 10000.0 implies that the listed field values are in gauss.

I added the new command Create table from data to Mapper (Fig. 1). The command initiates a Load file dialog, showing input files with names of the form FileName.DAT. The program handles everything else automatically, creating the output field map FileName.MTX in text format. This file may be ported to OmniTrak, or loaded into Mapper for plotting and editing.


Figure 1. Mapper screenshot showing a three dimensional field map constructed from midplane measurements with the new Create table from data command.

LINKS