Skip to content

enceladus2000/prony

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Prony Decomposition Routines

prony is a python package that provides numerical routines for Prony decomposition of discrete signals.

What is Prony decomposition?

The Prony method is a way to obtain the damped-sinusoidal components constituiting a signal. In other words, it expresses the signal as a linear combination of damped sinusoids.

This damped-sinusoid representation is in fact equivalent to all-pole models encountered in signal processing (filter design and system identification). It may also be considered a special case of Padé approximant technique.

The damped-sinusoid a.k.a all-pole representation is particularly useful to describe infinite-impulse-response (IIR) filters in a parsimonious manner. As a consequence, many physical systems with resonant modes - speakers, rooms, waveguides etc. - are modelled this way.

The Prony algorithms implemented in this package can, given a recorded discrete impulse response, estimate the coefficients, frequencies, and damping factors of its constituents.

For a mathematical description, scroll down

Installation and Developing

Please use uv for the love of God.

  1. Clone the repo
git clone https://github.com/enceladus2000/prony --branch main
  1. Initialize a virtual environment.
cd prony
uv venv
source .venv/bin/activate
  1. Run uv sync
uv sync

See this notebook for an example.

Algorithm Details

The signal model is as follows:

$$ s[n] = \sum_{k=1}^K a_i 2^{-n/d_i} \cos(2\pi n / T_i + \phi_i) $$

where $a_i$, $T_i$ is the time period and $\phi_i$ is the phase offset of the component. $d_i$ is the decay factor - in this formulation, it is the number of samples it takes for the component to decay (in amplitude) to half the original.

About

Methods for prony decomposition of discrete signals

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published