pub struct ZTransform;Expand description
Z-transform: X(z) = sum_{n=0}^{N-1} x[n] * z^{-n}
Implementations§
Source§impl ZTransform
impl ZTransform
Sourcepub fn transform(signal: &[f64], z: Complex64) -> Complex64
pub fn transform(signal: &[f64], z: Complex64) -> Complex64
Compute the Z-transform of a discrete signal at a given complex point z.
Sourcepub fn dtft(signal: &[f64], omega: f64) -> Complex64
pub fn dtft(signal: &[f64], omega: f64) -> Complex64
Evaluate the Z-transform on the unit circle (z = e^{jω}), equivalent to the DTFT.
Sourcepub fn frequency_response(signal: &[f64], frequencies: &[f64]) -> Vec<Complex64> ⓘ
pub fn frequency_response(signal: &[f64], frequencies: &[f64]) -> Vec<Complex64> ⓘ
Compute the frequency response at multiple frequencies.
Sourcepub fn magnitude_response_db(signal: &[f64], frequencies: &[f64]) -> Vec<f64>
pub fn magnitude_response_db(signal: &[f64], frequencies: &[f64]) -> Vec<f64>
Compute the magnitude response in dB.
Sourcepub fn phase_response(signal: &[f64], frequencies: &[f64]) -> Vec<f64>
pub fn phase_response(signal: &[f64], frequencies: &[f64]) -> Vec<f64>
Compute the phase response in radians.
Sourcepub fn zeros(signal: &[f64]) -> Vec<Complex64> ⓘ
pub fn zeros(signal: &[f64]) -> Vec<Complex64> ⓘ
Check stability of an FIR filter (all zeros inside unit circle). For IIR, you’d need pole analysis.
Trait Implementations§
Source§impl Clone for ZTransform
impl Clone for ZTransform
Source§fn clone(&self) -> ZTransform
fn clone(&self) -> ZTransform
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ZTransform
impl Debug for ZTransform
Source§impl<'de> Deserialize<'de> for ZTransform
impl<'de> Deserialize<'de> for ZTransform
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for ZTransform
impl RefUnwindSafe for ZTransform
impl Send for ZTransform
impl Sync for ZTransform
impl Unpin for ZTransform
impl UnsafeUnpin for ZTransform
impl UnwindSafe for ZTransform
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.