Пример #1
0
def get_results(duration):
    excitation = generation.log_sweep(fstart, fstop, duration, fs)
    excitation_zeropadded = generation.zero_padding(excitation, duration + pad,
                                                    fs)
    system_response = system(excitation_zeropadded)
    ir = calculation.deconv_process(excitation_zeropadded, system_response, fs)
    return ir
Пример #2
0
import windows
from scipy.signal import lfilter, fftconvolve
import numpy as np

# Parameters of the measuring system

fs = 44100

fstart = 1
fstop = 22050
duration = 1
pad = 4

# Generate excitation signal

excitation = generation.log_sweep(fstart, fstop, duration, fs)
N = len(excitation)

# Noise in measurement chain

noise_level_db = -30
noise = measurement_chain.additive_noise(noise_level_db)

# FIR-Filter-System

dirac_system = measurement_chain.convolution([1.0])

# Combinate system elements

system = measurement_chain.chained(dirac_system, noise)