Memory polynomial for a power amplifier

조회 수: 17 (최근 30일)
Ali
Ali 2023년 10월 31일
편집: Walter Roberson 2024년 8월 13일
How to implement the momory polynomial (MP) for a power amlifier (PA) complex data? The MP equation is:
Where:
• y[n] => Instantaneous complex output signal
• x[n-j] => Instantaneous complex input signal
• M => Model memory depth
• N => Model nonlinear order
• a_ji => Model complex coefficients
The problem is that I'm not sure how to go back to the old input "x[n-j]".
Below is a simple example. The expected x_new is a 9x3 matrix. Could someone help me, please?
%% Clean up
% Clear all variables
clear;
% Close all figures
close all;
% Clear command window
clc;
%% Test
x = [20; 40; 60; 80; 100];
y = x.^2;
M = 5;
N = 3;
for j = 3:M
for i = 1:N
x_new(:,i) = x(j:-1:end) .* (abs(x(j:-1:end)).^(i-1));
end
end
a_ji = x_new\y; % Solve systems for linear equation Ax = B (mldivide, \)
y_new = x_new * a_ji; % Memory polynomial output matrix y[n]

답변 (1개)

Rajanya
Rajanya 2024년 8월 13일
Hi @Ali,
The code provided will always throw an error while calculating “a_ji” because the equation in the loops will end up producing a 0x3 vector and hence the ‘\‘ operator would not work. Assuming you will be having ‘a_ji’ coefficient matrix as input, you can calculate the given equation in the following way:
y = zeros(size(x));
%Run n from 1 to length of input signal maybe,
for j = 1:M+1
if (n-j) > 0
for i = 2:N+1
y(n) = y(n) + a(j, i)*x(n-j)*abs(x(n-j))^(i-2);
end
end
end
%End the outermost loop to get y values for all n.
To avoid any out of bound array accesses, the condition and the indexing have been put accordingly.
Please note that if you don’t have “a_ji” as input and you need to get it using “mldivide” operator (as you have intended to do in the example code), make sure you are producing the correct dimensions of the matrices before performing the operation.
Thanks.
  댓글 수: 1
Ali
Ali 2024년 8월 13일
편집: Walter Roberson 2024년 8월 13일
Thanks a lot for your answer and your time! I solved long ago, my answer is quiet similar. I computed the memory polynomial this way:
%% Test
x = [20; 40; 60; 80; 100];
y = x.^2;
M = 5;
N = 3;
% Initilize empty matrices
x_MP1 = [];
x_MP2 = [];
% Compute x[n-j].|x[n-j]|^(i-1)
for n = M+1:numel(x)
for i = 1:N
for j = 0:M
x_MP = x(n-j) .* abs(x(n-j)).^(i-1);
x_MP1 = [x_MP1 x_MP];
end
end
x_MP2 = [x_MP2; x_MP1];
x_MP1 = [];
x_MP = [];
end
% Solve for "a" coefficients, Xa = Y (Least square using backslash "\")
a_ij = x_MP2\y(M+1:1:end); % Forward model extraction
% Evaluation of the forward model
y_new = x_MP2 * a_ij;

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Polynomials에 대해 자세히 알아보기

제품


릴리스

R2023b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by