Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- % Plot a theoretical binary FSK constellation
- t = linspace(0,2*pi,100);
- % change these f's to look at orthoganality
- f1 = 100;
- f2 = 200;
- basis = [cos(2*pi*t*f1); cos(2*pi*t*f2)] ;
- symbols = basis;
- constellation = zeros(1,2);
- constellation(1) = sum(symbols(1,:).*basis(1,:));
- constellation(1) = constellation(1) + j*sum(symbols(1,:).*basis(2,:));
- constellation(2) = sum(symbols(2,:).*basis(1,:));
- constellation(2) = constellation(2) + j*sum(symbols(2,:).*basis(2,:));
- vector_angles = angle(constellation)*180/(pi)
- fprintf('The first symbol has vector angle %2.1f\n',vector_angles(1));
- fprintf('The second symbol has vector angle %2.1f\n',vector_angles(2));
- figure();
- plot(constellation, 'o');
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement