How do I construct a vector of complex numbers whose absolute value is not above 1?

1 Ansicht (letzte 30 Tage)
I want to add complex noise to my signal but the absolute value of my signal + added complex noise has to be equal to or smaller than 1.

Akzeptierte Antwort

Thorsten
Thorsten am 6 Sep. 2016
Bearbeitet: Thorsten am 6 Sep. 2016
You can generate a vector of complex number where the maximum absolute value is always 1:
C = rand(1,10) + 1i*rand(1,10);
C = C/max(abs(X(:)));
If you are not happy that the maximum value is always 1, subtract a random complex number:
C = C - rand - 1i*rand;

Weitere Antworten (0)

Kategorien

Mehr zu Data Import and Network Parameters finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by