Class FFT2DFrame

All Implemented Interfaces:
ClipboardOwner, ImageObserver, MenuContainer, Serializable, Accessible, RootPaneContainer, WindowConstants, AppFrame, Hidable

public class FFT2DFrame extends DrawingFrame
FFT2DFrame computes a 2D FFT and displays the result as a complex grid plot.
Version:
1.0
Author:
W. Christian
See Also:
  • Field Details

  • Constructor Details

    • FFT2DFrame

      public FFT2DFrame(String xlabel, String ylabel, String frameTitle)
      Constructs a Complex2DFrame with the given axes labels and frame title.
      Parameters:
      xlabel - String
      ylabel - String
      frameTitle - String
    • FFT2DFrame

      public FFT2DFrame(String frameTitle)
      Constructs a Complex2DFrame with the given frame title but without axes.
      Parameters:
      frameTitle - String
  • Method Details

    • addMenuItems

      protected void addMenuItems()
      Adds Views menu items on the menu bar.
      Overrides:
      addMenuItems in class DrawingFrame
    • convertToInterpolatedPlot

      public void convertToInterpolatedPlot()
    • convertToGridPlot

      public void convertToGridPlot()
    • convertToSurfacePlot

      public void convertToSurfacePlot()
      Converts to a SurfacePlot plot.
    • setDomainType

      public void setDomainType(int type)
      Sets the units for the FFT output. Domain types are: MODE, FREQ, OMEGA, WAVENUMBER, MOMENTUM
      Parameters:
      type - int
    • doFFT

      public void doFFT(double[][][] data, double xmin, double xmax, double ymin, double ymax)
      Does an FFT of the given data array and repaints the panel. data[0][][] is assumed to contain the real components of the field. data[1][][] is assumed to contain the imaginary components of the field.
      Parameters:
      data - double[][][] complex field values
      xmin - double
      xmax - double
      ymin - double
      ymax - double
    • doFFT

      public void doFFT(double[] data, int nx, double xmin, double xmax, double ymin, double ymax) throws IllegalArgumentException
      Throws:
      IllegalArgumentException
    • clearDrawables

      public void clearDrawables()
      Removes drawable objects added by the user from this frame.
      Overrides:
      clearDrawables in class DrawingFrame
    • getDrawables

      public ArrayList<Drawable> getDrawables()
      Gets Drawable objects added by the user to this frame.
      Overrides:
      getDrawables in class DrawingFrame
      Returns:
      the list
    • getDrawables

      public <T extends Drawable> ArrayList<T> getDrawables(Class<T> c)
      Gets Drawable objects added by the user of an assignable type. The list contains objects that are assignable from the class or interface.
      Overrides:
      getDrawables in class DrawingFrame
      Parameters:
      c - the type of Drawable object
      Returns:
      the cloned list
      See Also: