|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjfftw.FFTW
public class FFTW
Basic class for Java access to the fftw3
library to take Fourier Transforms or one-dimensional,
two-dimensional or three-dimensional data held
in double[]
arrays.
This class set package defaults, manages the wisdom information and loads the sharable library. Actual numerical use of this package is via the extending classes.
The simplest use of the package is via DataArray
and its extending classes that hides most of the complexity.
Field Summary | |
---|---|
static int |
BACKWARD
Flag for backward (on inverse) FFT |
protected static PrintStream |
errorStream
PrintStream for warning and error messages. |
static int |
ESTIMATE
Flag for quick and dirty plan search (fast, but no optimal) |
static int |
EXHAUSTIVE
Flag for exhaustive plan search (very slow) |
static int |
FORWARD
Flag for forward FFT |
static int |
FOURIER
Flag for Fourier space |
protected static boolean |
loaded
Boolean to determine in the sharable library has been loaded successfully. |
static int |
PATIENT
Flag for patient plan search (medium slow) |
protected int |
planFlag
Integer to set to the current plan in use by the package. |
static int |
REAL
Flag for Real space |
static String |
version
Version flag |
Constructor Summary | |
---|---|
FFTW()
Default constructor, do nothing but load the sharable library. |
|
FFTW(boolean systemWisdom)
Constructor with flag to optionally load the system wisdom file. |
|
FFTW(FFTW fft)
Constructor to for a new FFTW, being a copy of the specified one. |
|
FFTW(File wisdomFile)
Constructor to load specified wisdom file. |
|
FFTW(String wisdomFileName)
Constructor to load specified wisdom file specified by name. |
Method Summary | |
---|---|
void |
addPlanFlag(int addition)
Method to add to the plan flag |
void |
clearWisdom()
Void method to clear the wisdom information |
boolean |
exportWisdom(File file)
Boolean method to export the current wisdom to a file |
int |
getPlanFlag()
Method to get the plan flag |
String |
getVersion()
Method to get the version string |
String |
getWisdom()
Method to get the wisdom information as a String |
boolean |
loadWisdom()
Boolean method to load system wisdom file |
boolean |
loadWisdom(File file)
Boolean method to load wisdom file from specified File |
boolean |
loadWisdom(String wisdom)
Boolean method to load (or add) wisdom from a String. |
static String |
readWisdom(File file)
Static method to read a Wisdom file into a String |
void |
setErrorStream(PrintStream es)
Method to reset the default errorStream for package. |
void |
setPlanFlag(int flag)
Method to set the plan flag, default is ESTIMATE |
void |
setSystemWisdom(String fileName)
Method to reset the system wisdom file location. |
static boolean |
writeWisdom(String wisdom,
File file)
Static method to write wisdom String to a file |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String version
public static final int REAL
public static final int FOURIER
public static final int FORWARD
public static final int BACKWARD
public static final int EXHAUSTIVE
public static final int PATIENT
public static final int ESTIMATE
Default for jttfw but NOT the normal FFTW default
protected static PrintStream errorStream
System.err
.
protected int planFlag
protected static boolean loaded
Constructor Detail |
---|
public FFTW()
public FFTW(FFTW fft)
fft
- the FFTWpublic FFTW(boolean systemWisdom)
systemWisdom
- if true default system wisdom filepublic FFTW(File wisdomFile)
wisdomFile
- the FFTW wisdom filepublic FFTW(String wisdomFileName)
wisdomFileName
- the name of the wisdom fileMethod Detail |
---|
public String getVersion()
String
public void setPlanFlag(int flag)
flag
- the plan flagpublic void addPlanFlag(int addition)
addition
- the addition to addpublic int getPlanFlag()
public void setErrorStream(PrintStream es)
es
- the error PrintStreampublic void setSystemWisdom(String fileName)
fileName
- name of default wisdom filepublic boolean loadWisdom()
public boolean loadWisdom(File file)
file
- the wisdom file
public boolean loadWisdom(String wisdom)
wisdom
- the wisdom String
public void clearWisdom()
public boolean exportWisdom(File file)
file
- the output file
boolean
true if successful, else falsepublic String getWisdom()
String
returns the FFTW wisdom
entry in a formatted String.public static String readWisdom(File file)
file
- the wisdom file
public static boolean writeWisdom(String wisdom, File file)
wisdom
- the wisdom Stringfile
- the output file
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |