AudibleT 0.0.1
A real-time A/B/X audio testing tool for subjective assessment of various audio parameters, compatible for general purpose computer as well as embedded systems.
Loading...
Searching...
No Matches
Static Public Member Functions | List of all members

Provides methods to help calculate the frequency response of a filter. More...

#include <FrequencyResponseHelper.h>

Static Public Member Functions

static std::vector< double > logspace (double start, double end, int num_points)
 Creates a logarithmically spaced vector.
 
static std::vector< double > calculate_frequency_response (const std::vector< double > &B, const std::vector< double > &A, double sample_rate, const std::vector< double > &frequencies)
 Calculates the frequency response of a filter given its coefficients.
 

Detailed Description

Provides methods to help calculate the frequency response of a filter.

Member Function Documentation

◆ calculate_frequency_response()

std::vector< double > FrequencyResponseHelper::calculate_frequency_response ( const std::vector< double > &  B,
const std::vector< double > &  A,
double  sample_rate,
const std::vector< double > &  frequencies 
)
static

Calculates the frequency response of a filter given its coefficients.

Parameters
BThe B coefficients of the filter.
AThe A coefficients of the filter.
sample_rateThe sample rate used in the filter.
frequenciesThe frequencies at which to calculate the response.
Returns
A vector containing the gain in decibels at each frequency.

◆ logspace()

std::vector< double > FrequencyResponseHelper::logspace ( double  start,
double  end,
int  num_points 
)
static

Creates a logarithmically spaced vector.

Parameters
startThe start value of the vector.
endThe end value of the vector.
num_pointsThe number of points in the vector.
Returns
A logarithmically spaced vector.

The documentation for this class was generated from the following files: