
1. Function of Pre-emphasis Filter
In speech signals, the glottal wave excitation and the radiation effects from the mouth and nose together cause the energy of high-frequency components to be weaker than that of low-frequency components. The purpose of pre-emphasis is:1. To enhance high-frequency components, balancing the speech spectrum, making high-frequency features more prominent, which facilitates subsequent feature extraction (such as MFCC).2. To eliminate the influence of lip radiation during phonation.3. To suppress power line interference to some extent.
2. Use Cases of Pre-emphasis Filter
- Frontend processing for speech recognitionFunction: This is the most classic and important application of pre-emphasis.Spectrum balancing: Speech signals are naturally affected by glottal pulses and lip radiation during production, resulting in approximately -6dB/octave high-frequency attenuation. Pre-emphasis compensates for this attenuation with a +6dB/octave boost, flattening the spectrum.Enhancing high-frequency features: Clear consonants (such as /s/, /f/, /th/) contain important high-frequency information but have weak energy; pre-emphasis can enhance these critical features, improving recognition accuracy.Improving signal-to-noise ratio: Suppressing low-frequency noise interference to some extent.
- Speech codingIn linear predictive coding such as CELP and ACELP, pre-emphasis flattens the signal spectrum, improving the accuracy of linear prediction.It reduces quantization errors and increases coding efficiency.
- Speech enhancement and noise reductionEnhancing high-frequency components of speech, making them more prominent against background noise.In conjunction with subsequent algorithms like spectral subtraction, better noise reduction effects can be achieved.
- Audio recording and playback systemsTape recording systems (historical classic application):During recording, pre-emphasis boosts high-frequency signals to overcome the tape’s inherent noise (mainly high-frequency noise).During playback, de-emphasis attenuates high frequencies, restoring the original frequency response while reducing high-frequency noise.Standard pre-emphasis time constants: 50μs (FM broadcasting), 75μs (audio tape)
- FM broadcastingPre-emphasis (US standard 75μs) is used to improve the noise resistance of broadcast signals.The receiver uses a corresponding de-emphasis network.

3. Principle and Transfer Function of Pre-emphasis Filter
Pre-emphasis is typically modeled as a first-order high-pass filter. Its function is to suppress low frequencies while allowing high frequencies to pass.The transfer function of its digital filter is usually defined as:


4. MATLAB Implementation
function[y, freq_response]= pre_emphasis_analysis(x, fs, alpha, plot_results)
% Complete pre-emphasis analysis and implementation
% Input:
% x - Input speech signal
% fs - Sampling frequency
% alpha - Pre-emphasis coefficient
% plot_results - Whether to plot result graphs
% Output:
% y - Pre-emphasized signal
% freq_response - Filter frequency response
if nargin <3
alpha =0.97;
end
if nargin <4
plot_results =true;
end
% Pre-emphasis filtering
y = filter([1, -alpha], 1, x);
% Calculate frequency response
[h, w]= freqz([1, -alpha], 1, 1024, fs);
freq_response = abs(h);
frequencies = w;
% Plot results
if plot_results
plot_preemphasis_results(x, y, frequencies, freq_response, fs, alpha);
end
end
function plot_preemphasis_results(x, y, f, h, fs, alpha)
% Plot pre-emphasis results
figure('Position', [100, 100, 1200, 800]);
% Time domain signal comparison
subplot(3, 2, 1);
t =(0:length(x)-1) / fs;
plot(t, x, 'b', 'LineWidth', 1);
title('Original Speech Signal (Time Domain)');
xlabel('Time (s)');
ylabel('Amplitude');
grid on;
subplot(3, 2, 2);
plot(t, y, 'r', 'LineWidth', 1);
title('Pre-emphasized Signal (Time Domain)');
xlabel('Time (s)');
ylabel('Amplitude');
grid on;
% Frequency domain comparison
N = length(x);
f_axis =(0:N-1) * fs / N;
X = abs(fft(x));
Y = abs(fft(y));
subplot(3, 2, 3);
plot(f_axis(1:N/2), X(1:N/2), 'b', 'LineWidth', 1.5);
title('Original Signal Spectrum');
xlabel('Frequency (Hz)');
ylabel('Amplitude');
grid on;
subplot(3, 2, 4);
plot(f_axis(1:N/2), Y(1:N/2), 'r', 'LineWidth', 1.5);
title('Pre-emphasized Spectrum');
xlabel('Frequency (Hz)');
ylabel('Amplitude');
grid on;
% Filter frequency response
subplot(3, 2, 5);
plot(f, 20*log10(h), 'g', 'LineWidth', 2);
title('Pre-emphasis Filter Frequency Response');
xlabel('Frequency (Hz)');
ylabel('Gain (dB)');
grid on;
% Spectrum comparison (overlap)
subplot(3, 2, 6);
plot(f_axis(1:N/2), X(1:N/2)/max(X), 'b--', 'LineWidth', 1, 'DisplayName', 'Original');
hold on;
plot(f_axis(1:N/2), Y(1:N/2)/max(Y), 'r-', 'LineWidth', 1.5, 'DisplayName', 'Pre-emphasis');
title('Spectrum Comparison (Normalized)');
xlabel('Frequency (Hz)');
ylabel('Normalized Amplitude');
legend('show');
grid on;
sgtitle(sprintf('Speech Pre-emphasis Analysis (α = %.2f)', alpha));
end

5. FPGA Implementation of Pre-emphasis Filter

module pre_emphasis(
input wire clk,
input wire rst_n,
input wire signed[15:0] data_in,
output reg signed[15:0] data_out
);
// Pre-emphasis coefficient α = 0.97, Q1.15 format
parameter ALPHA =16'd31782;// 0.97 * 2^15
// Register declarations
reg signed[15:0] x_delay;// Delay register
reg signed[31:0] product_reg;// Multiplication result register
reg signed[15:0] input_reg;// Input register
// Pipelined processing
always @(posedge clk or negedge rst_n) begin
if(!rst_n) begin
input_reg <=16'sd0;
x_delay <=16'sd0;
product_reg <=32'sd0;
data_out <=16'sd0;
end else begin
// Stage 1: Input and delay
input_reg <= data_in;
x_delay <= input_reg;// Note: Here input_reg is used instead of data_in
// Stage 2: Multiplication
product_reg <= ALPHA * x_delay;
// Stage 3: Subtraction and output
data_out <= input_reg - product_reg[30:15];// Q format adjustment
end
end
endmodule
The content of this article represents the author’s views and does not reflect the views of the platform.
If there are any objections, please feel free to contact us.
If there is any infringement, please contact us for removal.
