Los Alamos National Laboratory Poisson Superfish Codes Maintained by James H. Billen Los Alamos National Laboratory Mailstop H824 Los Alamos, New Mexico 87545, USA (c) Copyright, 1985-2005 by the Regents of the University of California. This software was produced under U.S. Government contract W-7405-ENG-36 by Los Alamos National Laboratory, which is operated by the University of California for the U.S. Department of Energy. Neither the Government nor the University makes any warranty, express or implied, or assumes any liability or responsibility for the use of this software. Unpublished -- rights reserved under Copyright Laws of the United States. -------------------------------------------------------------------------- Poisson Superfish version 7 is a collection of programs for calculating static magnetic and electric fields and radio-frequency electromagnetic fields in either 2-D Cartesian coordinates or axially symmetric cylindrical coordinates. The programs generate a triangular mesh fitted to the boundaries of different materials in the problem geometry. Plotting programs and other postprocessor codes present the results in various forms. Acknowledgments The original Poisson Superfish was written by Ron. F. Holsinger in collaboration with Klaus Halbach, who developed the theory. See the paper by K. Halbach and R. F. Holsinger, "SUPERFISH - A Computer Program for Evaluation of RF Cavities with Cylindrical Symmetry", Particle Accelerators 7 (1976) 213-222. For many years, the Los Alamos Accelerator Code Group (LAACG) has maintained a standard version of Poisson Superfish for Cray, UNIX, and VAX machines. Robert Ryne is currently the leader of LAACG. Several LAACG members who have worked with these codes are now retired from Los Alamos National Laboratory, including Richard K. Cooper (former Code Group leader), Mary T. Menzel, Grenfell Boicourt, Terese Barts, Jean Merson, Gary Rodenz, and John L. Warren. A PC version originated in 1985 when Lloyd M. Young adapted an older Cray version to run on IBM-PC compatible computers. A major revision (Version 5) began in 1992 when James H. Billen and Lloyd M. Young removed the previous 32K limit on the number of mesh points. The codes have been under nearly constant development ever since. Version 5 of Poisson Superfish runs under DOS and Windows. Version 6, developed since late 1998, runs under Windows. Version 7, also for Windows, was released to beta testers in December, 2002, and to all users in April, 2003. Lloyd Young wrote the Los Alamos CFISH code following the method described by M. S. de Jong and F. P. Adams in the AECL internal report "Seafish, A 2-Dimensional Complex Helmholtz Equation Solver." See also the paper by M. de Jong, F. Adams and R. Hutcheon, "Computation of RF Fields for Applicator Design," Journal of Microwave Power and Electromagnetic Energy 27, No. 3, 136 (1992). Recent Changes and Additions For information about changes, additions, and bug fixes in Poisson Superfish version 7, please see file CHANGES.SF7 in the LANL directory. The latest information may also be found on the web site laacg.lanl.gov. Installation Procedure To install Poisson Superfish, download file PoissonSuperfish_7.xx.exe from the web site as described below and launch the program. Letters "xx" stand for the latest revision number. If you are installing the codes over a previous distribution, the Setup program will save customized settings in your SF.INI file. Getting Started The best way to learn about Poisson Superfish is to run the sample problems described in the documentation (LA-UR-96-1834). We do not recommend trying to build an input file "from scratch." Instead, find an example file that is similar to the problem you are trying to solve. Make a copy of the file and then make any necessary modifications to the geometry and options. We recommend that you acquaint yourself with the documentation in directory LANL\Docs. Start with file SFTOC.DOC, which contains the table of contents and a list of the other documentation files. It is helpful to have a list of the problem variables handy in printed form. For quick reference to the variables used by the codes, print section III.E Problem Variables in file SFIntro.DOC. If you are switching from the UNIX (or VAX) version of Poisson Superfish (version 4 or earlier) you should be able to read your Automesh namelist files with little or no modification. Some namelist variables from the UNIX version are no longer used. Automesh will give you warning or error messages as appropriate with suggestions on how to modify your input file. Automesh recognizes either the ampersand (&) or the dollar sign ($) as the namelist delimiter. In Version 7, all problem variables used by solver programs Fish CFish, Poisson, Pandira appear in the Automesh input file. Solvers read and write only the Poisson Superfish solution file, which has extension T35. Installation Directories and Sample Problems The Setup program suggests that you install all Los Alamos software in the same directory. We will assume that the name of this directory is LANL on one of your hard drives. The LANL directory contains all the executable files. Documentation files will be in the LANL\Docs directory. Several subdirectories of the LANL\Examples directory contain sample input files. The sample files are arranged by the type of problem. Removing Files from an Older Version Version 5 of Poisson Superfish contained the same set of Microsoft Word documentation files as the present version, but installed them to the LANL directory, rather than the LANL\Docs directory used by the current version. The older documentation files (SF*.DOC) remaining in the LANL directory may be safely deleted. Example files from previous versions were found in directories under LANL\FISHDEMO. Version 7 examples are arranged in categories under LANL\Examples. We recommend deleting LANL\FISHDEMO and all its contents. Compilers All codes in version 7 were compiled by Lahey/Fujitsu Fortran 95 compiler LF95 version 5.7 plus the Winteracter development tools from Interactive Software Services Ltd. Source Code and Dynamic Link Libraries Except as follows, source code for the Poisson Superfish programs is not available. Users with the Lahey/Fujitsu Fortran 95 compiler LF95 (version 5.7 or higher) may use the library of Fortran-callable subroutines found in directory LANL\DeveloperFiles\PoissonSuperfish\LF95 to read the Poisson Superfish solution file and interpolate fields from the solution. The source code for the routine that reads the solution file is also provided. However, we recommend either calling the compiled version in the Fortran library, or (better yet) using one of the dynamic link libraries described in the next paragraph. Subdirectories of LANL\DeveloperFiles\PoissonSuperfish contain versions of a dynamic link library (DLL) for several language systems that allow users to call the Poisson Superfish field interpolator from their own programs. In general, calling the DLL involves far less effort and programming than calling the Fortran 95 subroutines discussed above. Some directories include source code for an example main program that calls the DLL. An application that switches among 2 to 4 different Poisson Superfish solution files may benefit from using multiple DLLs simultaneously. For more information refer to the Readme_xxx.txt files in each subdirectory, where xxx refers to the subdirectory name. Computer Requirements These codes run under Windows 2000 or Windows XP. Environment settings The Setup program adds the installation directory to your PATH and adds the environment variable SFDir, which is used by the codes to find the installation directory more quickly than searching the path. No other changes or additions to environment settings are needed. Documentation Los Alamos National Laboratory report LA-UR-96-1834 is the documentation for Poisson Superfish and related codes. This document consists of several Microsoft Word files in the LANL\Docs directory. We do not distribute a printed version. The file SFTOC.DOC includes a detailed table of contents and a list of the other filenames. The SF.INI File The Poisson Superfish codes have configurable options that you can control with settings in the initialization file SF.INI. The Setup program put a copy of SF.INI containing suggested settings in the installation directory. If you are installing an update, Setup will add new settings to your SF.INI file while preserving your customized settings. The documentation contains detailed information about the configuration parameters. If you intend to run large problems (e.g., with more than a few hundred thousand mesh points, we recommend that you add a line to the [Global] section of SF.INI to prevent possible problems when the codes try to allocate memory for temporary data storage. If a code such as Fish or Pandira allocates more memory than available RAM, Windows will use a paging file for the memory. This is usually less efficient than if the code creates its own file for temporary data and it may cause the code to stop unexpectedly. The setting should be at least ~200 MB smaller than your computer's RAM to leave enough memory for the other applications. For example, if your computer has 2 GB of RAM, use the following setting (the value is in kB): MaxMemAvailable=1800000 Reporting Bugs The example files provided with this distribution test many features of Poisson Superfish, but your application may exercise a little-used section of the codes. We would appreciate hearing from you if you discover a bug or if you have suggestions for improvements we might make in the codes. We already have added several features suggested by Poisson Superfish users. For suggestions on reporting bugs, open file SFINTRO.DOC in Microsoft Word and click on the TechnicalSupport link near the beginning of the file.