Plot the constellation points using one of the symbol sets. For each constellation point, assign a label indicating the Gray-coded and binary-coded values for each symbol.
For Gray-code symbol mapping, adjacent constellation points differ by a single bit and are not numerically sequential.
For binary-coded mapping, adjacent constellation points follow the binary encoding and are sequential.
scatterplot(symgray,1,0,'b*');
for k = 1:M
text(real(symgray(k))-0.6,imag(symgray(k))+0.6,...
dec2base(mapgray(k),2,4));
text(real(symgray(k))-0.2,imag(symgray(k))+1.2,...
num2str(mapgray(k)));
text(real(symbin(k))-0.6,imag(symbin(k))-0.6,...
dec2base(mapbin(k),2,4),'Color',[1 0 0]);
text(real(symbin(k))-0.2,imag(symbin(k))-1.2,...
num2str(mapbin(k)),'Color',[1 0 0]);
end
axis([-M M -2 2])
Input signal, specified as a vector or matrix of integers in the range of [0,
M – 1].
Example: randi([0 3],100,1)
Data Types: double
Modulation order, specified as a positive integer power of two.
Example: 4
Data Types: double
Initial phase of the modulated signal (in radians), specified as a real
scalar.
Example: pi/4
Data Types: double
Mapping order for the modulation symbols, specified as 'bin' or
'gray'. This argument specifies how the function assigns binary
vectors to corresponding integers.
If symorder is 'bin', the function
uses a binary-coded mapping order.
If symorder is 'gray', the function
uses a Gray-coded mapping order.
Complex baseband representation of a PAM-modulated signal, returned as vector or
matrix of complex values. The modulated signal has a minimum Euclidean distance of 2.
The columns of y represent independent channels.
Data Types: double | single Complex Number Support: Yes
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window.
Web browsers do not support MATLAB commands.
Sélectionner un site web
Choisissez un site web pour accéder au contenu traduit dans votre langue (lorsqu'il est disponible) et voir les événements et les offres locales. D’après votre position, nous vous recommandons de sélectionner la région suivante : .
Vous pouvez également sélectionner un site web dans la liste suivante :
Comment optimiser les performances du site
Pour optimiser les performances du site, sélectionnez la région Chine (en chinois ou en anglais). Les sites de MathWorks pour les autres pays ne sont pas optimisés pour les visites provenant de votre région.