Skip to content

Commit

Permalink
Rename GetFakeCT and move it to +sim subpackage
Browse files Browse the repository at this point in the history
  • Loading branch information
dmalt committed Feb 28, 2020
1 parent 52a7795 commit 4dedf44
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 31 deletions.
27 changes: 27 additions & 0 deletions +ups/+sim/GenerateFakeCT.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
function CT = GenerateFakeCT(nSen, nTimes)
% --------------------------------------------------------------------------- %
% Generate random complex matrix with cross-spectrum-timeseries-like structure
%
% real and imag parts of complex timeseries for CT generation are drawn from
% standard normal distribution.
% --------------------------------------------------------------------------- %
% FORMAT:
% CT = GenerateFakeCT(nSen, nTimes)
% INPUTS:
% nSen - scalar; number of sensors
% nTimes - scalar; number of time steps
% OUTPUTS:
% CT - {nSen ^ 2 x nTimes} matrix;
% timeseries of vectorized PSD hermitian matrices
% ___________________________________________________________________________ %
% Dmitrii Altukhov, [email protected]

CT = zeros(nSen ^ 2, nTimes);
fakeTs = randn(nSen, nTimes) + 1i * randn(nSen,nTimes);

for iTime = 1:nTimes
timeSlice = fakeTs(:, iTime);
Cp = timeSlice * timeSlice';
CT(:,iTime) = Cp(:);
end
end
31 changes: 0 additions & 31 deletions +ups/GetFakeCT.m

This file was deleted.

0 comments on commit 4dedf44

Please sign in to comment.