In Pskmod Code: Reshaping the output signal using the transpose operator .' , Introduce a sign change.
1 view (last 30 days)
Show older comments
In the Pskmod implemented matlab code, the last part is:
% --- restore the output signal to the original orientation --- %
if(wid == 1)
y = y.';
end
..
The issue is that: the pskmod function handles the output format for complex numbers (data with real and imaginary parts). The function tries to reshape the output. However, using the single quote transpose (.') on complex numbers can cause the imaginary component's sign to flip.
how to solve this issue?
0 Comments
Answers (1)
John D'Errico
on 7 Jul 2024
Edited: John D'Errico
on 7 Jul 2024
No. You have it wrong. Completely backwards, in fact. The .' operator does NOT cause a sign flip. That is called a conjugation. The ' operator does cause a sign change when it transposes the elements, and it ALWAYS flips the sign of any imaginary part. There is no maybe about it. Thus we would have
X = [1+i, -1-2i, 1, -3, i]
X =
1+1i -1-2i 1+0i -3+0i 0+1i
The conjugate transpose operator, formed using ' but also called ctranspose, as applied to X:
X'
ans =
1 - 1i
-1 + 2i
1 + 0i
-3 + 0i
0 - 1i
help ctranspose
' Complex conjugate transpose.
X' is the complex conjugate transpose of X.
B = ctranspose(A) is called for the syntax A' (complex conjugate transpose)
when A is an object.
See MATLAB Operators and Special Characters for more details.
See also transpose, pagectranspose.
Documentation for ctranspose
Other uses of ctranspose
Next, the standard non-conjugated transpose operator. It does NOT change the sign of any imaginary parts.
X.'
ans =
1 + 1i
-1 - 2i
1 + 0i
-3 + 0i
0 + 1i
help transpose
.' Transpose.
X.' is the non-conjugate transpose.
B = transpose(A) is called for the syntax A.' when A is an object.
See MATLAB Operators and Special Characters for more details.
See also ctranspose, permute, pagetranspose.
Documentation for transpose
Other uses of transpose
So use whichever is appropriate.
0 Comments
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!