public class PistonModel
extends java.lang.Object
Constructor and Description |
---|
PistonModel() |
Modifier and Type | Method and Description |
---|---|
static double[] |
conv(double[] wave,
double[] ir)
Convolve the impulse response with the wave.
|
static double[] |
getImpulseResponse(double a,
double theta,
double sr,
double c,
double binOffset)
Calculate the impulse response for a sound emitted from a baffled
piston of radius a at angle theta.
|
public static double[] getImpulseResponse(double a, double theta, double sr, double c, double binOffset)
a
- radius of piston in metrestheta
- angle in radians.sr
- sample ratec
- speed of soundbinOFfset
- offset from integer sample of the first bin.public static double[] conv(double[] wave, double[] ir)
wave
- input waveformir
- impulse response