Code covered by the BSD License  

Highlights from
Equi-angular tight frame via conference matrix

image thumbnail

Equi-angular tight frame via conference matrix


Kenneth Shum


Construction of equi-angular tight frame by Paley's conference matrix and svd

function E = tight_frame_paley(p,deg)
% construction of equi-angular tight frame by
% Paley's conference matrix
% Input parameters
% p : odd prime number
% deg: positive integer (default value = 1)
% Output is a (p^deg+1) by (p^deg+1)/2 matrix E

% When deg > 1, the communication toolbox is required

% A collection of d-dimensional vectors of norm 1 is equi-angular
% if the absolute values of the inner products between any two
% distinct vectors is equal to a constant c.
% The equi-angular vectors are called tight if the constant c
% attains Welch's lower bound.

% The columns of the output matrix E is an equi-angular tight frame
% The norm of each column of E is 1
% The inner product between each pair of columns is 1/sqrt(p^deg)
% Columns of E represent equi-angular lines 
% in the (p^deg+1)/2 dimensional Euclidean space

% We can check that diagonal entries of E'*E are all 1,
% and the off-diagonal entries of abs(E'*E) are all 1/sqrt(q)

if nargin == 1
   deg = 1;   % Default value of deg is 1

q = p^deg;  % q is the size of finite field
n = q+1;    % number of vectors in the tight frames
d = n/2;    % dimension of vector field
e = (-1)^mod((q-1)/2,2); 
% e is 1 if q equals 1 mod 4, and -1 if q equals 3 mod 4

if ~isprime(p) || mod(p,2) ==0
    disp('Error: Input p must be an odd prime number');
    E = [];
    if deg == 1
        QR = -1*ones(1,q-1);
        QR( mod( (1:((q-1)/2)).^2,q)) = ones(1,(q-1)/2);
        QR = [0 QR];   %  vector representing quadratic residues mod p
        [X Y] = meshgrid(1:q, 1:q);
        C = QR(mod(X-Y,q)+1);
        tuple = gftuple([-1:(q-2)]',gfprimdf(deg,p),p);
        [X Y] = meshgrid(-1:(q-2), -1:(q-2));
        Y = gfmul( gfsub(-1,0,tuple)* ones(q,q), Y, tuple);
        C = 1-2*mod(gfadd(X,Y,tuple),2);
        C(1:(q+1):q^2) = zeros(size(1:(q+1):q^2));
    C = [0 ones(1,q); e*ones(q,1) C ];  % Conference matrix of size n
    [U S V] = svd(sqrt((n-1)*e)*C+eye(n)); 
    E = sqrt(2)*U(:,1:d)';     % extract a tight frame from C via svd

Contact us