Borrar filtros
Borrar filtros

Somethings wrong in function mskmod

28 visualizaciones (últimos 30 días)
Zhuo
Zhuo el 26 de Jun. de 2024 a las 11:53
Comentada: Zhuo el 3 de Jul. de 2024 a las 9:12
in annotation,''Pulse shape by cos((pi*t/2T)+pi/2)''
but in code,y = complex(xI.*cos(arg+pi), xQ.*sin(arg)) .* exp(1i*ini_phase); is cos(arg+pi),why not cos(arg+pi/2),and why need plus pi or pi/2

Respuesta aceptada

Karanjot
Karanjot el 28 de Jun. de 2024 a las 10:10
Hi Zhuo,
It looks like you have a question regarding the manipulation of cosine and sine functions, specifically about the phase shifts applied to these functions. The pulse shaping is done using cosine and sine functions, where the argument of these functions includes a phase shift.
The annotation mentions cos((pi*t/2T) + pi/2), which indicates a phase shift of pi/2. In the code, the cosine function is shifted by pi/2: cos(arg + pi/2). The sine function does not have an additional phase shift: sin(arg).
Cosine Shift by pi/2:
  • The phase shift of pi/2 in the cosine function (cos(arg + pi/2)) converts the cosine function into a sine function because cos(x + pi/2) = -sin(x). This is a common technique in signal processing to align the phase of the signal components.
Cosine Shift by pi:
  • The comment suggests a shift by pi to account for circular shift, which would mean cos(arg + pi) = -cos(arg). However, this is not applied in the code snippet you provided.
Note that you must use cos(arg + pi/2) and not cos(arg + pi):
  • The shift by pi/2 is used to align the phase of the cosine function with the sine function. This is necessary for creating a complex signal where the real and imaginary parts are orthogonal.
  • Shifting by pi would invert the cosine function, which is not the intended operation here.
I hope this helps!
  1 comentario
Zhuo
Zhuo el 3 de Jul. de 2024 a las 9:12
Thank you for your reply.I still need to understand it better for this question.
I'd like to ask you another question about MSK.
For example :bits = [1,1,0,1,0,0,1,1,0,1]
and his differential encoding:dBits = [1,1,0,0,1,0,0,0,1,1]
use mskmod:msk1 = mskmod(dBits,sps,'diff'); msk2 = mskmod(bits,sps,'nondiff');
Should msk1 and msk2 be the same?,there are not same,why?。
OR:msk3 = mskmod(bits,sps,'diff'); msk4 = mskmod(dBits,sps,'nondiff');
msk3 and msk4 are not same too
So, how do I set the parameters for mskmod?

Iniciar sesión para comentar.

Más respuestas (0)

Productos


Versión

R2019b

Community Treasure Hunt

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

Start Hunting!

Translated by