I had a look at your code and have some comments:
* If you want to make a column vector, just use y(:), this is basically the same as reshape (y, numel (y), 1);
* Be careful if using x' this is complex conjugate transpose . If you just want to transpose use x.'
* there is no need to bring c and y to the same size, see https://docs.octave.org/latest/Broadcasting.html and it is automatically done since Octave 3.6.x
* There is no need to call min in a loop, see my modified code attached
* The second output of min is the index of the found minimum, no need to first calculate the minimum and then find its index.
Hi Andy, thank you for the review and so good tips.
when I measure the EVM with the variable evm, I did the absolute value of the difference to find the minimum error but with all symbols of c, y will be a vector with input samples and c is all the possible symbols, so the function must find the minimum of each one of y between all of c. In any case, the code has many aspects to improve and I will push another commit with changes, not only to avoid the for loop, but also to change the complex conj transpose to a literal transpose.
Many thanks :)
Yassin.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi Yassin, thank you for your contribution.
I had a look at your code and have some comments:
* If you want to make a column vector, just use y(:), this is basically the same as reshape (y, numel (y), 1);
* Be careful if using
x'
this is complex conjugate transpose . If you just want to transpose usex.'
* there is no need to bring c and y to the same size, see https://docs.octave.org/latest/Broadcasting.html and it is automatically done since Octave 3.6.x
* There is no need to call min in a loop, see my modified code attached
* The second output of
min
is the index of the found minimum, no need to first calculate the minimum and then find its index.-- Andy
Last edit: Andreas Weber 2025-04-26
Hi Andy, thank you for the review and so good tips.
when I measure the EVM with the variable
evm
, I did the absolute value of the difference to find the minimum error but with all symbols ofc
, y will be a vector with input samples and c is all the possible symbols, so the function must find the minimum of each one ofy
between all ofc
. In any case, the code has many aspects to improve and I will push another commit with changes, not only to avoid the for loop, but also to change the complex conj transpose to a literal transpose.Many thanks :)
Yassin.
I already pushed a commit with your changes. I see now that doing the remainder of column vector and row vector gives a matrix.
Thanks for the help!