To parallelize and optimize code developed by the Jet Propulsion Laboratory's (JPL's) Optical Systems Modeling Group for use in the Next Generation Space Telescope (NGST) and Developmental Cryogenic Active Telescope Testbed (DCATT) design and flight mission phases. The purposes are to dramatically shorten some portions of the design process and to reduce the mass of the flight instrument.
Phase retrieval code was developed by JPL's Optical Systems Modeling Group.
It is used to focus the instrument, before each new mission or after the telescope becomes defocused (from once per day to once every several weeks, depending on stability of telescope).
The starting point was work by Gerschberg-Saxton and Misel. The code was originally developed using Matlab, then converted to Fortran 90, on a workstation (Sun UltraSPARC 200). It was then parallelized for use on distributed memory computers (JPL's CRAY T3D). It is currently being ported to JPL/Caltech's HP SPP-2000.
The parallel code is based on a 1-D data decomposition. The algorithm uses repetitive 2-D Fast Fourier Transforms, 512x512 to 4096x4096. These are done implicitly in parallel using vendor-supplied 2-D FFT routines. Additional operations are performed independently on each processor. The only explicit communication is one global sum per iteration. This helps the parallel code remain similar to the sequential code.

Figure 1. Initial Phase information. (Note that the difference in the rightmost column between the real pupil image and the estimate column is very large, as shown in the bottom row.)

Figure 2. Final Phase information. (Note that the difference in the rightmost column between the real pupil image and the estimate column is now very small, as shown in the bottom row.)
Three similar codes have been developed. Changes can be made to the Matlab code and run for simple cases, then larger cases can be run on larger machines (CRAY T3D, etc.).
A test code using a 512x512 matrix takes 1 hour on the workstation, and less than 1 minute on 64 PE's of the CRAY T3D. A complete analysis uses Monte Carlo simulations of 100 test cases, which would take 100 hours on the workstations, but only 1 hour on 64 PE's of the CRAY T3D.
Simulation of mechanical disturbances and noise factors required 15 Monte Carlo analyses. The results were presented at an NGST quarterly meeting. They took 15 hours to obtain, using 64 PE's of the CRAY T3D, and would have taken 2 months on the Sun workstation.
During the design phase, this parallel code allows many factors to be quickly considered. In flight, other more direct techniques could be used (Shack-Hartman sensor, shearing interferometer), but these would add more optics (hardware) to the instrument and add mass and cost. This code is fast enough that it can be run on the ground using data obtained from the instrument in flight, with the results then sent to the instrument.
This work is currently being used for NGST and DCATT. Efforts are underway to port the code to other platforms, including the HP SPP-2000 and the Beowulf.
Optical Systems Modeling Group:
Scott A. Basinger and David Redding
High Performance Computing Group:
Daniel S. Katz, Tom Cwik, and Andrea Borgioli
Daniel S. Katz
NASA Jet Propulsion Laboratory
Daniel.S.Katz@jpl.nasa.gov
818-354-7359