├── DeepMIMO-matlab ├── Example_2 │ ├── README.md │ ├── DeepMIMOv2_example_2.m │ ├── Visualize_ant_array_orientation.m │ └── DeepMIMOv2_example_2_params.m ├── Example_3 │ ├── DeepMIMOv2_example_3_DT.m │ └── DeepMIMOv2_example_3_DT_params.m └── Example_1 │ ├── DeepMIMOv2_example_1.m │ └── DeepMIMOv2_example_1_params.m ├── README.md ├── DeepMIMO-python └── DeepMIMO_example_1.py └── DeepMIMO-5GNR └── Example_1 ├── Example_1.m └── Example_1_params.m /DeepMIMO-matlab/Example_2/README.md: -------------------------------------------------------------------------------- 1 | This example requires the [plotcube](https://www.mathworks.com/matlabcentral/fileexchange/15161-plotcube) from MATLAB file exchange. 2 | -------------------------------------------------------------------------------- /DeepMIMO-matlab/Example_2/DeepMIMOv2_example_2.m: -------------------------------------------------------------------------------- 1 | %% Generate Dataset after changing array rotation parameters 2 | addpath('DeepMIMO_functions') 3 | dataset_params = read_params('DeepMIMOv2_example_2_params.m'); 4 | 5 | % Generate the dataset with the loaded parameters 6 | [DeepMIMO_dataset, dataset_params] = DeepMIMO_generator(dataset_params); 7 | 8 | 9 | %% Visualization of an antenna array orientation 10 | % 11 | % Select an active basestation to visualize its antenna array orientation 12 | % 13 | BS_id = 1; 14 | 15 | Num_ant_BS = dataset_params.num_ant_BS(BS_id,:); 16 | Array_rotation_BS = DeepMIMO_dataset{BS_id}.rotation; 17 | Ant_spacing_BS = dataset_params.ant_spacing_BS(BS_id); 18 | Carrier_freq = dataset_params.carrier_freq; 19 | 20 | Visualize_ant_array_orientation(Num_ant_BS,Array_rotation_BS,Ant_spacing_BS,Carrier_freq) 21 | -------------------------------------------------------------------------------- /DeepMIMO-matlab/Example_3/DeepMIMOv2_example_3_DT.m: -------------------------------------------------------------------------------- 1 | %% Generate a time-domain dataset 2 | addpath('DeepMIMO_functions') 3 | 4 | dataset_params = read_params('DeepMIMOv2_example_3_DT_params.m'); 5 | [DeepMIMO_dataset, dataset_params] = DeepMIMO_generator(dataset_params); 6 | 7 | %% Generate pulses shifted to path ToAs 8 | % 9 | % Select a transmit basestation and a receive user pair. 10 | % Determine time values for the channel to be sampled. 11 | % Generate sinc pulses at path ToA values. 12 | % Plot the result. 13 | % 14 | 15 | ue_idx = 1; % First UE 16 | bs_idx = 1; % First BS 17 | 18 | path_ToA = DeepMIMO_dataset{bs_idx}.user{ue_idx}.path_params.ToA; % Time of Arrival 19 | 20 | BW = dataset_params.bandwidth*1e9; 21 | upsampling_factor = 100; 22 | sampling_duration = (BW*upsampling_factor); % Sampling rate 1/(BW*upsampling_factor) 23 | total_duration = max(path_ToA)*1.5; % A total duration including all paths 24 | t = 0:(1/sampling_duration):total_duration; % the ADC time samples 25 | 26 | path_pulses = pulse_sinc((t-path_ToA')*BW); % Generate sinc centered at ToA values - sampled at time samples 27 | 28 | figure; 29 | plot(t, path_pulses) 30 | xlabel('Time (s)') 31 | ylabel('Amplitude') 32 | title('Pulses Shifted to the ToAs') 33 | grid on; 34 | 35 | %% Calculate and visualize power delay profile 36 | % 37 | % Multiply time samples of each shifted pulse with the corresponding array response function 38 | % of the path. 39 | % 40 | 41 | TD_channel = DeepMIMO_dataset{bs_idx}.user{ue_idx}.channel; % num_RX x num_TX x num_paths 42 | path_pulses = reshape(path_pulses, 1, 1, size(path_pulses, 1), size(path_pulses, 2)); % Make the pulses 1 x 1 x num_paths x time_samples 43 | 44 | time_response = squeeze(sum(TD_channel .* path_pulses , 3)); % Elementwise multiplication of the TD channel with pulses result in num_RX x num_TX x num_paths x time_samples 45 | % Sum over paths to obtain time samples. The resulting matrix size is num_RX x num_TX x time_samples (corresponding to variable t) 46 | 47 | figure; 48 | channel_power = abs(squeeze(time_response(1, 1, :))).^2; % Channel power response from the first BS antenna to the first UE antenna 49 | plot(t, channel_power) 50 | xlabel('Time (s)') 51 | ylabel('Power') 52 | title('Power Delay Profile') 53 | grid on; -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ## ⚠️ Archived Repository Notice 2 | 3 | **This repository has been archived** and is no longer maintained. It contains code for DeepMIMOv2. 4 | 5 | All future versions are now maintained in a new unified repository, with DeepMIMOv4 in pre-release: 6 | 7 | 👉 [DeepMIMO Unified Repository](https://github.com/DeepMIMO/DeepMIMO) 8 | 9 | --- 10 | 11 | ## Examples Repository 12 | In this repository, you can find simple examples for DeepMIMOv2 MATLAB, python and 5G NR versions. 13 | 14 | ## Available Paper Implementations with DeepMIMO dataset 15 | Below, we provide the list of papers that use DeepMIMO dataset and have an available implementation. 16 | | Paper | Details | Scenario | 17 | | :-: | :-: | :-: | 18 | | [Deep Learning Coordinated Beamforming for Highly-Mobile Millimeter Wave Systems](https://ieeexplore.ieee.org/document/8395149) | [link](https://deepmimo.net/applications/coordinated-beamforming/) | O1_60 | 19 | | [Enabling Large Intelligent Surfaces With Compressive Sensing and Deep Learning](https://ieeexplore.ieee.org/document/9370097) | [link](https://deepmimo.net/applications/large-intelligent-surface/) | O1_3p5
O1_28 | 20 | | [Deep Learning for TDD and FDD Massive MIMO: Mapping Channels in Space and Frequency](https://ieeexplore.ieee.org/document/9048929) | [link](https://deepmimo.net/applications/channel-mapping/) | I1_2p4
I1_2p5 | 21 | | [Deep Learning for Direct Hybrid Precoding in Millimeter Wave Massive MIMO Systems](https://ieeexplore.ieee.org/document/9048966) | [link](https://deepmimo.net/applications/direct-hybrid-precoding/) | O1_60 | 22 | | [Channel Estimation for Massive MIMO with One-Bit ADCs](https://ieeexplore.ieee.org/document/9067011) | [link](https://deepmimo.net/applications/one-bit-adcs/) | I1_2p4 | 23 | | [Deep Learning for mmWave Beam and Blockage Prediction Using Sub-6 GHz Channels](https://ieeexplore.ieee.org/document/9121328) | [link](https://deepmimo.net/applications/sub-6-ghz-to-mmwave/) | O1_3p5
O1_28 | 24 | | [Deep Reinforcement Learning for Intelligent Reflecting Surfaces: Towards Standalone Operation](https://ieeexplore.ieee.org/document/9154301) | [link](https://deepmimo.net/applications/intelligent-reflecting-surfaces-rl/) | O1_3p5 | 25 | | [Neural networks based beam codebooks: learning mmWave massive MIMO beams that adapt to deployment and hardware](https://arxiv.org/abs/2006.14501) | [link](https://deepmimo.net/applications/codebook-learning-self-supervised/) | O1_28
I2_28B | 26 | | [Reinforcement Learning of Beam Codebooks in Millimeter Wave and Terahertz MIMO Systems](https://ieeexplore.ieee.org/document/9610084) | [link](https://deepmimo.net/applications/codebook-learning-rl/) | O1_60
I2_28B | 27 | -------------------------------------------------------------------------------- /DeepMIMO-matlab/Example_1/DeepMIMOv2_example_1.m: -------------------------------------------------------------------------------- 1 | %% Generate Dataset 2 | addpath('DeepMIMO_functions') 3 | dataset_params = read_params('DeepMIMOv2_example_1_params.m'); 4 | 5 | % Generate the dataset with the loaded parameters 6 | [DeepMIMO_dataset, dataset_params] = DeepMIMO_generator(dataset_params); 7 | 8 | %% Variable Inspection (BS-UE channel) 9 | % 10 | % Select a transmit basestation and a receive user pair. 11 | % *Note: These variables will be used later to select a single user.* 12 | % 13 | TX_BS = 1; RX_User = 1; 14 | 15 | % Let's check the size of the dataset 16 | size_of_BSuser_channel = size(DeepMIMO_dataset{TX_BS}.user{RX_User}.channel) 17 | 18 | % BS-user link information 19 | BS_user_link = DeepMIMO_dataset{TX_BS}.user{RX_User} 20 | 21 | % Channel path information 22 | BS_user_path_params = DeepMIMO_dataset{TX_BS}.user{RX_User}.path_params 23 | 24 | %% Variable Inspection (BS-BS channel) 25 | % 26 | % Select a transmit basestation and a receive basesation pair 27 | % 28 | TX_BS = 1; RX_BS = 2; 29 | 30 | % Let's check the size of the dataset 31 | size_of_BSBS_channel = size(DeepMIMO_dataset{TX_BS}.basestation{RX_BS}.channel) 32 | 33 | % BS-BS link information 34 | BS_BS_link = DeepMIMO_dataset{TX_BS}.basestation{RX_BS} 35 | 36 | % Channel path information 37 | BS_BS_path_params = DeepMIMO_dataset{TX_BS}.basestation{RX_BS}.path_params 38 | 39 | %% Visualization of a channel matrix 40 | 41 | H = squeeze(DeepMIMO_dataset{TX_BS}.user{RX_User}.channel); 42 | subcarriers = 1:dataset_params.OFDM_sampling_factor:dataset_params.OFDM_limit; 43 | ant_ind = 1:prod(dataset_params.num_ant_BS); 44 | 45 | figure; 46 | imagesc(ant_ind, subcarriers, abs(H).'); 47 | xlabel('TX Antennas'); 48 | ylabel('Subcarriers'); 49 | title('Channel Magnitude Response'); 50 | colorbar; 51 | 52 | %% Visualization of the UE positions and path-losses 53 | bs_loc = DeepMIMO_dataset{TX_BS}.loc; 54 | num_ue = 100*181; % 100 rows of 181 UEs 55 | 56 | ue_locs = zeros(num_ue, 3); 57 | ue_pl = zeros(num_ue, 1); 58 | for ue_idx = 1:num_ue 59 | ue_locs(ue_idx, :) = DeepMIMO_dataset{TX_BS}.user{ue_idx}.loc; 60 | ue_pl(ue_idx) = DeepMIMO_dataset{TX_BS}.user{ue_idx}.pathloss; 61 | end 62 | 63 | % 3D Grid visualization with basestation 64 | figure; 65 | scatter3(ue_locs(:, 1), ue_locs(:, 2), ue_locs(:, 3), [], ue_pl); 66 | hold on 67 | scatter3(bs_loc(1), bs_loc(2), bs_loc(3), 'rx'); 68 | colorbar() 69 | xlabel('x (m)'); 70 | ylabel('y (m)'); 71 | zlabel('z (m)'); 72 | title('Path Loss (dB)') 73 | legend('UE', 'BS', 'Location', 'best') 74 | 75 | % 2D Grid Visualization 76 | figure; 77 | scatter(ue_locs(:, 1), ue_locs(:, 2), [], ue_pl); 78 | colorbar() 79 | xlabel('x (m)'); 80 | ylabel('y (m)'); 81 | title('UE Grid Path Loss (dB)') 82 | xlim([min(ue_locs(:, 1)), max(ue_locs(:, 1))]) 83 | ylim([min(ue_locs(:, 2)), max(ue_locs(:, 2))]) 84 | -------------------------------------------------------------------------------- /DeepMIMO-matlab/Example_2/Visualize_ant_array_orientation.m: -------------------------------------------------------------------------------- 1 | function Visualize_ant_array_orientation(num_ant, array_rotation, ant_spacing, carrier_freq) 2 | %Visualize_ant_array_orientation: Visualize the BS antenna array orientation 3 | 4 | % num_ant --> Number of the UPA antenna array on the x,y,z-axes 5 | % array_rotation ---> Rotation angles [gamma, beta, alpha] in degrees 6 | % carrier_freq ---> Carrier frequency in Hz 7 | % ant_spacing ---> Antenna array element spacing as a ratio of the wavelength 8 | 9 | %% Calculations 10 | Ds = ant_spacing*(physconst('LightSpeed')/carrier_freq); 11 | Mx = num_ant(1); 12 | My = num_ant(2); 13 | Mz = num_ant(3); 14 | Alpha = array_rotation(3); 15 | Beta = array_rotation(2); 16 | Gamma = array_rotation(1); 17 | 18 | Ax = linspace(0,(Mx-1)*Ds,Mx); 19 | Ay = linspace(0,(My-1)*Ds,My); 20 | Az = linspace(0,(Mz-1)*Ds,Mz); 21 | [AY, AX, AZ] = meshgrid(Ay,Ax,Az); 22 | AY = AY(:); 23 | AX = AX(:); 24 | AZ = AZ(:); 25 | 26 | % Apply rotations 27 | A = [AX AY AZ].'; 28 | Rz = rotz(Alpha)*A; 29 | Rzy = roty(Beta)*Rz; 30 | Rzyx = rotx(Gamma)*Rzy; 31 | Rzyx = Rzyx.'; 32 | 33 | %% 3D plot 34 | %set(0,'DefaultFigureWindowStyle','docked') 35 | 36 | Sc = 1e3; %Axes scaling factor to represent millimeter scales 37 | Marker_size = 30; Curve_width = 2.5; 38 | Font_size = 12; 39 | labels_fontsize = 12; 40 | Legend_fontsize = 12; 41 | Marker_style = 's^v*x+dph'; 42 | Line_style = cell(4,1); 43 | Line_style{1}='-';Line_style{2}='-.';Line_style{3}=':';Line_style{4}='--'; 44 | Color = [ 45 | '#0072BD'; %blue 46 | '#A2142F'; %red 47 | '#007F00'; %green 48 | '#7E2F8E'; %purple 49 | '#D95319'; %orange 50 | '#4DBEEE'; %cyan 51 | '#EDB120'; %yellow 52 | '#888888'; %grey 53 | '#000000'; %black 54 | '#0072BD'; %blue 55 | '#A2142F'; %red 56 | ]; 57 | 58 | Fig2 = figure('Name', 'Array1', 'units','pixels'); 59 | hold on; 60 | grid on; 61 | box on; 62 | Title_string = strcat('\textbf{BS Antenna Array Orientation, $\alpha=',num2str(Alpha),'^{\circ}$, ',' $\beta=',num2str(Beta),'^{\circ}$, ',' $\gamma=',num2str(Gamma),'^{\circ}$','}'); 63 | title(Title_string,'fontsize',labels_fontsize,'interpreter','latex') 64 | xlabel('\textbf{X axis (mm)}','fontsize',labels_fontsize,'interpreter','latex') 65 | ylabel('\textbf{Y axis (mm)}','fontsize',labels_fontsize,'interpreter','latex') 66 | zlabel('\textbf{Z axis (mm)}','fontsize',labels_fontsize,'interpreter','latex') 67 | set(gca,'FontSize',Font_size) 68 | if ishandle(Fig2) 69 | set(0, 'CurrentFigure', Fig2) 70 | hold on; 71 | grid on; 72 | scatter3(AX*Sc,AY*Sc,AZ*Sc,Marker_size,[0 0.4470 0.7410],'o','filled') 73 | scatter3(Rzyx(:,1)*Sc,Rzyx(:,2)*Sc,Rzyx(:,3)*Sc,Marker_size,[0.6350 0.0780 0.1840],'o','filled') 74 | plotcube((max(A*Sc,[],2).'),[0 0 0],0.1,[0 0.4470 0.7410]) 75 | view([150 45]) 76 | 77 | lgd = legend({'Before the rotations','After the rotations'},'Location','northwest','Interpreter','latex','FontSize',Legend_fontsize); 78 | title(lgd,'BS Antenna Array Orientation') 79 | legend show 80 | set(gca,'XMinorTick','on','YMinorTick','on') 81 | end 82 | drawnow 83 | hold off 84 | rotate3d on 85 | 86 | end 87 | 88 | -------------------------------------------------------------------------------- /DeepMIMO-python/DeepMIMO_example_1.py: -------------------------------------------------------------------------------- 1 | # Import DeepMIMO and other needed libraries for this example 2 | import DeepMIMO 3 | import numpy as np 4 | from pprint import pprint 5 | import matplotlib.pyplot as plt 6 | 7 | plt.rcParams['figure.figsize'] = [12, 8] # Set default plot size 8 | 9 | 10 | ## Load and print the default parameters 11 | parameters = DeepMIMO.default_params() 12 | pprint(parameters, sort_dicts=False) 13 | 14 | 15 | ## Change parameters for the setup 16 | # Scenario O1_60 extracted at the dataset_folder 17 | parameters['scenario'] = 'O1_60' 18 | parameters['dataset_folder'] = r'C:\Users\xxx\Desktop\scenarios' 19 | 20 | parameters['num_paths'] = 10 21 | 22 | # User rows 1-100 23 | parameters['user_row_first'] = 1 24 | parameters['user_row_last'] = 100 25 | 26 | # Activate only the first basestation 27 | parameters['active_BS'] = np.array([1]) 28 | 29 | parameters['OFDM']['bandwidth'] = 0.05 # 50 MHz 30 | parameters['OFDM']['subcarriers'] = 512 # OFDM with 512 subcarriers 31 | parameters['OFDM']['subcarriers_limit'] = 64 # Keep only first 64 subcarriers 32 | 33 | parameters['ue_antenna']['shape'] = np.array([1, 1, 1]) # Single antenna 34 | parameters['bs_antenna']['shape'] = np.array([1, 32, 1]) # ULA of 32 elements 35 | #parameters['bs_antenna']['rotation'] = np.array([0, 30, 90]) # ULA of 32 elements 36 | #parameters['ue_antenna']['rotation'] = np.array([[0, 30], [30, 60], [60, 90]]) # ULA of 32 elements 37 | #parameters['ue_antenna']['radiation_pattern'] = 'isotropic' 38 | #parameters['bs_antenna']['radiation_pattern'] = 'halfwave-dipole' 39 | 40 | 41 | ## Generate and inspect the dataset 42 | dataset = DeepMIMO.generate_data(parameters) 43 | 44 | # Number of basestations 45 | len(dataset) 46 | 47 | # Keys of a basestation dictionary 48 | dataset[0].keys() 49 | 50 | # Keys of a channel 51 | dataset[0]['user'].keys() 52 | 53 | # Number of UEs 54 | len(dataset[0]['user']['channel']) 55 | 56 | # Shape of the channel matrix 57 | dataset[0]['user']['channel'].shape 58 | 59 | # Shape of BS 0 - UE 0 channel 60 | dataset[0]['user']['channel'][0].shape 61 | 62 | # Path properties of BS 0 - UE 0 63 | pprint(dataset[0]['user']['paths'][0]) 64 | 65 | 66 | ## Visualization of a channel matrix 67 | 68 | plt.figure() 69 | # Visualize channel magnitude response 70 | # First, select indices of a user and bs 71 | ue_idx = 0 72 | bs_idx = 0 73 | # Import channel 74 | channel = dataset[bs_idx]['user']['channel'][ue_idx] 75 | # Take only the first antenna pair 76 | plt.imshow(np.abs(np.squeeze(channel).T)) 77 | plt.title('Channel Magnitude Response') 78 | plt.xlabel('TX Antennas') 79 | plt.ylabel('Subcarriers') 80 | 81 | 82 | ## Visualization of the UE positions and path-losses 83 | loc_x = dataset[bs_idx]['user']['location'][:, 0] 84 | loc_y = dataset[bs_idx]['user']['location'][:, 1] 85 | loc_z = dataset[bs_idx]['user']['location'][:, 2] 86 | pathloss = dataset[bs_idx]['user']['pathloss'] 87 | fig = plt.figure() 88 | ax = fig.add_subplot(projection='3d') 89 | im = ax.scatter(loc_x, loc_y, loc_z, c=pathloss) 90 | ax.set_xlabel('x (m)') 91 | ax.set_ylabel('y (m)') 92 | ax.set_zlabel('z (m)') 93 | 94 | bs_loc_x = dataset[bs_idx]['basestation']['location'][:, 0] 95 | bs_loc_y = dataset[bs_idx]['basestation']['location'][:, 1] 96 | bs_loc_z = dataset[bs_idx]['basestation']['location'][:, 2] 97 | ax.scatter(bs_loc_x, bs_loc_y, bs_loc_z, c='r') 98 | ttl = plt.title('UE and BS Positions') 99 | 100 | fig = plt.figure() 101 | ax = fig.add_subplot() 102 | im = ax.scatter(loc_x, loc_y, c=pathloss) 103 | ax.set_xlabel('x (m)') 104 | ax.set_ylabel('y (m)') 105 | fig.colorbar(im, ax=ax) 106 | ttl = plt.title('UE Grid Path-loss (dB)') 107 | 108 | -------------------------------------------------------------------------------- /DeepMIMO-5GNR/Example_1/Example_1.m: -------------------------------------------------------------------------------- 1 | %% Generate dataset 2 | addpath(genpath('DeepMIMO-5GNR')) 3 | % 4 | % Load the provided dataset parameters 5 | % 6 | dataset_params = read_params('Example_1_params.m'); 7 | 8 | % 9 | % Generate the dataset with the loaded parameters 10 | % 11 | [DeepMIMO_dataset, dataset_params] = DeepMIMO_generator(dataset_params); 12 | 13 | %% Variable inspection 14 | % 15 | % Select a user and basestation pair 16 | % 17 | % *Note: These variables will be used later to select a single user.* 18 | % 19 | bs = 1; ue = 1; 20 | 21 | % Let's check the size of the dataset 22 | size_of_channel = size(DeepMIMO_dataset{bs}.user{ue}.channel) 23 | 24 | % Path parameters 25 | DeepMIMO_dataset{bs}.user{ue}.path_params 26 | 27 | % Check velocity and travel direction of the UE 28 | velocity = DeepMIMO_dataset{bs}.user{ue}.path_params.velocity; 29 | travel_dir_sph = DeepMIMO_dataset{bs}.user{ue}.path_params.travel_dir; 30 | [tr_x, tr_y, tr_z] = sph2cart(deg2rad(travel_dir_sph(1)), deg2rad(90-travel_dir_sph(2)), velocity); 31 | travel_dir = [tr_x, tr_y, tr_z]; 32 | 33 | 34 | %% Plot an example channel 35 | % 36 | % An example channel magnitude response is plotted for OFDM symbols through time. 37 | % 38 | channel = DeepMIMO_dataset{bs}.user{ue}.channel; 39 | 40 | channel_plot = abs(squeeze(channel(:, 1, 1, :))); 41 | subcarriers = 1:dataset_params.OFDM_sampling_factor:dataset_params.OFDM_limit; 42 | OFDM_symbols = 1:1:(14*dataset_params.CDL_5G.num_slots); 43 | 44 | figure; 45 | 46 | subplot(2 ,1, 1); 47 | surf(OFDM_symbols, subcarriers, channel_plot'); 48 | shading('flat'); 49 | xlabel('OFDM Symbols'); 50 | ylabel('Subcarriers'); 51 | zlabel('|H|'); 52 | title('Channel Magnitude Response'); 53 | view(-75, 35) 54 | 55 | 56 | subplot(2,1,2); 57 | imagesc(OFDM_symbols, subcarriers, channel_plot'); 58 | set(gca,'YDir','normal') % Invert Y axis (subcarriers) 59 | shading('flat'); 60 | xlabel('OFDM Symbols'); 61 | ylabel('Subcarriers'); 62 | zlabel('|H|'); 63 | title('Channel Magnitude Response'); 64 | view(0, 90) 65 | 66 | %% Plot the position and velocity of a user 67 | % 68 | % Plot the basestation position, user position and velocity of a single user. 69 | % 70 | bs_loc = DeepMIMO_dataset{bs}.loc; 71 | 72 | ue_loc = DeepMIMO_dataset{bs}.user{ue}.loc; 73 | travel_vector = travel_dir / 3.6; % m/s 74 | figure; 75 | scatter3(bs_loc(1), bs_loc(2), bs_loc(3), 'bo'); 76 | hold on 77 | scatter3(ue_loc(1), ue_loc(2), ue_loc(3), 'rx'); 78 | quiver3(ue_loc(1), ue_loc(2), ue_loc(3), travel_vector(1), travel_vector(2), travel_vector(3), 1, 'k') 79 | xlabel('x (m)'); 80 | ylabel('y (m)'); 81 | zlabel('z (m)'); 82 | 83 | %% Path loss of the users 84 | % 85 | % We combine the positions of the users along with the combined path-loss 86 | % variables to plot it with the basestation location. 87 | % 88 | bs_loc = DeepMIMO_dataset{bs}.loc; 89 | num_ue = 362; 90 | 91 | ue_locs = zeros(num_ue, 3); 92 | ue_pl = zeros(num_ue, 1); 93 | for ue = 1:362 94 | ue_locs(ue, :) = DeepMIMO_dataset{bs}.user{ue}.loc; 95 | ue_pl(ue) = DeepMIMO_dataset{bs}.user{ue}.pathloss; 96 | end 97 | 98 | figure; 99 | scatter3(ue_locs(:, 1), ue_locs(:, 2), ue_locs(:, 3), [], ue_pl); 100 | hold on 101 | scatter3(bs_loc(1), bs_loc(2), bs_loc(3), 'bo'); 102 | xlabel('x (m)'); 103 | ylabel('y (m)'); 104 | zlabel('z (m)'); 105 | title('Path Loss (dB)') 106 | colorbar() 107 | 108 | %% Reconstruct the CDL channel object 109 | % 110 | % Can be used with the MATLAB CDL channel visualization tools to check 111 | % the transmit and receive antennas (shape and orientation), along with the channel paths. 112 | % 113 | ue = 1; 114 | channel_path_parameters = DeepMIMO_dataset{bs}.user{ue}.path_params; 115 | txSize = dataset_params.CDL_5G.bsAntSize(bs, :); 116 | txOrientation = dataset_params.CDL_5G.bsArrayOrientation(bs, :); % BS Orientation from dataset params 117 | txPolarization = dataset_params.CDL_5G.bsPolarization+1; % BS Polarization for BS-UE channel 118 | rxSize = dataset_params.CDL_5G.ueAntSize; 119 | rxOrientation = channel_path_parameters.rxArrayOrientation; % UE Orientation from path params 120 | rxPolarization = dataset_params.CDL_5G.uePolarization+1; % UE Polarization for BS-UE channel 121 | 122 | CDL_channel = construct_DeepMIMO_CDL_channel(txSize, txOrientation, rxSize, rxOrientation, channel_path_parameters, dataset_params); 123 | 124 | % Visualize the RX and TX antennas with MATLAB 5G Toolbox functions: 125 | CDL_channel.displayChannel('LinkEnd','Tx'); 126 | CDL_channel.displayChannel('LinkEnd','Rx'); 127 | 128 | -------------------------------------------------------------------------------- /DeepMIMO-matlab/Example_3/DeepMIMOv2_example_3_DT_params.m: -------------------------------------------------------------------------------- 1 | %%%% DeepMIMO parameters set %%%% 2 | % A detailed description of the parameters is available on DeepMIMO.net 3 | 4 | %Ray-tracing scenario 5 | params.scenario = 'O1_60'; % The adopted ray tracing scenario [check the available scenarios at https://deepmimo.net/scenarios/] 6 | 7 | %Dynamic Scenario Scenes [only for dynamic (multiple-scene) scenarios] 8 | params.scene_first = 1; 9 | params.scene_last = 1; 10 | 11 | % Active base stations 12 | params.active_BS = [1]; % Includes the numbers of the active BSs (values from 1-18 for 'O1')(check the scenario description at https://deepmimo.net/scenarios/ for the BS numbers) 13 | 14 | % Active users 15 | params.active_user_first = 1; % The first row of the considered user section (check the scenario description for the user row map) 16 | params.active_user_last = 1; % The last row of the considered user section (check the scenario description for the user row map) 17 | 18 | % Subsampling of active users 19 | %--> Setting both subsampling parameters to 1 activate all the users indicated previously 20 | params.row_subsampling = 1; % Randomly select round(row_subsampling*(active_user_last-params.active_user_first)) rows 21 | params.user_subsampling = 1; % Randomly select round(user_subsampling*number_of_users_in_row) users in each row 22 | 23 | % Antenna array dimensions 24 | params.num_ant_BS = [1, 8, 4]; % Number of antenna elements for the BS arrays in the x,y,z-axes 25 | % By defauly, all BSs will have the same array sizes 26 | % To define different array sizes for the selected active BSs, you can add multiple rows. 27 | % Example: For two active BSs with a 8x4 y-z UPA in the first BS and 4x4 28 | % x-z UPA for the second BS, you write 29 | % params.num_ant_BS = [[1, 8, 4]; [1, 4, 4]]; 30 | 31 | params.num_ant_UE = [1, 4, 2]; % Number of antenna elements for the user arrays in the x,y,z-axes 32 | 33 | % Antenna array orientations 34 | params.activate_array_rotation = 0; % 0 -> no array rotation - 1 -> apply the array rotation defined in params.array_rotation_BS and params.array_rotation_UE 35 | params.array_rotation_BS = [5, 10, 20]; 36 | % 3D rotation angles in degrees around the x,y,z axes respectively 37 | % The rotations around x,y,z are also called as slant, downtilt, and bearing angles (of an antenna towards +x) 38 | % The origin of these rotations is the position of the first BS antenna element 39 | % The rotation sequence applied: (a) rotate around z-axis, then (b) rotate around y-axis, then (c) rotate around x-axis. 40 | % To define different orientations for the active BSs, add multiple rows.. 41 | % Example: For two active BSs with different array orientations, you can define 42 | % params.array_rotation_BS = [[10, 30, 45]; [0, 30, 0]]; 43 | 44 | params.array_rotation_UE = [0, 30, 0]; 45 | % User antenna orientation settings 46 | % For uniform random selection in 47 | % [x_min, x_max], [y_min, y_max], [z_min, z_max] 48 | % set [[x_min, x_max]; [y_min, y_max]; [z_min, z_max]] 49 | % params.array_rotation_UE = [[0, 30]; [30, 60]; [60, 90]]; 50 | 51 | params.enable_BS2BSchannels = 1; % Enable generating BS to BS channel (could be useful for IAB, RIS, repeaters, etc.) 52 | 53 | % Antenna array spacing 54 | params.ant_spacing_BS = .5; % ratio of the wavelength; for half wavelength enter .5 55 | params.ant_spacing_UE = .5; % ratio of the wavelength; for half wavelength enter .5 56 | 57 | % Antenna element radiation pattern 58 | params.radiation_pattern = 0; % 0: Isotropic and 59 | % 1: Half-wave dipole 60 | 61 | % System parameters 62 | params.bandwidth = 0.05; % The bandwidth in GHz 63 | params.activate_RX_filter = 0; % 0 No RX filter 64 | % 1 Apply RX low-pass filter (ideal: Sinc in the time domain) 65 | 66 | % Channel parameters # Activate OFDM 67 | params.generate_OFDM_channels = 0; % 1: activate frequency domain (FD) channel generation for OFDM systems 68 | % 0: activate instead time domain (TD) channel impulse response generation for non-OFDM systems 69 | params.num_paths = 15; % Maximum number of paths to be considered (a value between 1 and 25), e.g., choose 1 if you are only interested in the strongest path 70 | 71 | % OFDM parameters 72 | params.num_OFDM = 512; % Number of OFDM subcarriers 73 | params.OFDM_sampling_factor = 1; % The constructed channels will be calculated only at the sampled subcarriers (to reduce the size of the dataset) 74 | params.OFDM_limit = 64; % Only the first params.OFDM_limit subcarriers will be considered 75 | 76 | params.saveDataset = 0; % 0: Will return the dataset without saving it (highly recommended!) -------------------------------------------------------------------------------- /DeepMIMO-matlab/Example_1/DeepMIMOv2_example_1_params.m: -------------------------------------------------------------------------------- 1 | %%%% DeepMIMO parameters set %%%% 2 | % A detailed description of the parameters is available on DeepMIMO.net 3 | 4 | %Ray-tracing scenario 5 | params.scenario = 'O1_60'; % The adopted ray tracing scenario [check the available scenarios at https://deepmimo.net/scenarios/] 6 | 7 | %Dynamic Scenario Scenes [only for dynamic (multiple-scene) scenarios] 8 | params.scene_first = 1; 9 | params.scene_last = 1; 10 | 11 | % Active base stations 12 | params.active_BS = [1, 2]; % Includes the numbers of the active BSs (values from 1-18 for 'O1')(check the scenario description at https://deepmimo.net/scenarios/ for the BS numbers) 13 | 14 | % Active users 15 | params.active_user_first = 1; % The first row of the considered user section (check the scenario description for the user row map) 16 | params.active_user_last = 100; % The last row of the considered user section (check the scenario description for the user row map) 17 | 18 | % Subsampling of active users 19 | %--> Setting both subsampling parameters to 1 activate all the users indicated previously 20 | params.row_subsampling = 1; % Randomly select round(row_subsampling*(active_user_last-params.active_user_first)) rows 21 | params.user_subsampling = 1; % Randomly select round(user_subsampling*number_of_users_in_row) users in each row 22 | 23 | % Antenna array dimensions 24 | params.num_ant_BS = [1, 32, 1]; % Number of antenna elements for the BS arrays in the x,y,z-axes 25 | % By defauly, all BSs will have the same array sizes 26 | % To define different array sizes for the selected active BSs, you can add multiple rows. 27 | % Example: For two active BSs with a 8x4 y-z UPA in the first BS and 4x4 28 | % x-z UPA for the second BS, you write 29 | % params.num_ant_BS = [[1, 8, 4]; [1, 4, 4]]; 30 | 31 | params.num_ant_UE = [1, 1, 1]; % Number of antenna elements for the user arrays in the x,y,z-axes 32 | 33 | % Antenna array orientations 34 | params.activate_array_rotation = 0; % 0 -> no array rotation - 1 -> apply the array rotation defined in params.array_rotation_BS and params.array_rotation_UE 35 | params.array_rotation_BS = [5, 10, 20]; 36 | % 3D rotation angles in degrees around the x,y,z axes respectively 37 | % The rotations around x,y,z are also called as slant, downtilt, and bearing angles (of an antenna towards +x) 38 | % The origin of these rotations is the position of the first BS antenna element 39 | % The rotation sequence applied: (a) rotate around z-axis, then (b) rotate around y-axis, then (c) rotate around x-axis. 40 | % To define different orientations for the active BSs, add multiple rows.. 41 | % Example: For two active BSs with different array orientations, you can define 42 | % params.array_rotation_BS = [[10, 30, 45]; [0, 30, 0]]; 43 | 44 | params.array_rotation_UE = [0, 30, 0]; 45 | % User antenna orientation settings 46 | % For uniform random selection in 47 | % [x_min, x_max], [y_min, y_max], [z_min, z_max] 48 | % set [[x_min, x_max]; [y_min, y_max]; [z_min, z_max]] 49 | % params.array_rotation_UE = [[0, 30]; [30, 60]; [60, 90]]; 50 | 51 | params.enable_BS2BSchannels = 1; % Enable generating BS to BS channel (could be useful for IAB, RIS, repeaters, etc.) 52 | 53 | % Antenna array spacing 54 | params.ant_spacing_BS = .5; % ratio of the wavelength; for half wavelength enter .5 55 | params.ant_spacing_UE = .5; % ratio of the wavelength; for half wavelength enter .5 56 | 57 | % Antenna element radiation pattern 58 | params.radiation_pattern = 0; % 0: Isotropic and 59 | % 1: Half-wave dipole 60 | 61 | % System parameters 62 | params.bandwidth = 0.05; % The bandwidth in GHz 63 | params.activate_RX_filter = 0; % 0 No RX filter 64 | % 1 Apply RX low-pass filter (ideal: Sinc in the time domain) 65 | 66 | % Channel parameters # Activate OFDM 67 | params.generate_OFDM_channels = 1; % 1: activate frequency domain (FD) channel generation for OFDM systems 68 | % 0: activate instead time domain (TD) channel impulse response generation for non-OFDM systems 69 | params.num_paths = 10; % Maximum number of paths to be considered (a value between 1 and 25), e.g., choose 1 if you are only interested in the strongest path 70 | 71 | % OFDM parameters 72 | params.num_OFDM = 512; % Number of OFDM subcarriers 73 | params.OFDM_sampling_factor = 1; % The constructed channels will be calculated only at the sampled subcarriers (to reduce the size of the dataset) 74 | params.OFDM_limit = 64; % Only the first params.OFDM_limit subcarriers will be considered 75 | 76 | params.saveDataset = 0; % 0: Will return the dataset without saving it (highly recommended!) -------------------------------------------------------------------------------- /DeepMIMO-matlab/Example_2/DeepMIMOv2_example_2_params.m: -------------------------------------------------------------------------------- 1 | %%%% DeepMIMO parameters set %%%% 2 | % A detailed description of the parameters is available on DeepMIMO.net 3 | 4 | %Ray-tracing scenario 5 | params.scenario = 'O1_60'; % The adopted ray tracing scenario [check the available scenarios at https://deepmimo.net/scenarios/] 6 | 7 | %Dynamic Scenario Scenes [only for dynamic (multiple-scene) scenarios] 8 | params.scene_first = 1; 9 | params.scene_last = 1; 10 | 11 | % Active base stations 12 | params.active_BS = [1,2]; % Includes the numbers of the active BSs (values from 1-18 for 'O1')(check the scenario description at https://deepmimo.net/scenarios/ for the BS numbers) 13 | 14 | % Active users 15 | params.active_user_first = 1; % The first row of the considered user section (check the scenario description for the user row map) 16 | params.active_user_last = 2; % The last row of the considered user section (check the scenario description for the user row map) 17 | 18 | % Subsampling of active users 19 | %--> Setting both subsampling parameters to 1 activate all the users indicated previously 20 | params.row_subsampling = 1; % Randomly select round(row_subsampling*(active_user_last-params.active_user_first)) rows 21 | params.user_subsampling = 1; % Randomly select round(user_subsampling*number_of_users_in_row) users in each row 22 | 23 | % Antenna array dimensions 24 | params.num_ant_BS = [[1, 8, 4] % Number of the UPA antenna array on the x,y,z-axes for the active BSs 25 | [1, 4, 4]]; 26 | % By defauly, all BSs will have the same array sizes 27 | % To define different array sizes for the selected active BSs, you can add multiple rows. 28 | % Example: For two active BSs with a 8x4 y-z UPA in the first BS and 4x4 29 | % x-z UPA for the second BS, you write 30 | % params.num_ant_BS = [[1, 8, 4]; [1, 4, 4]]; 31 | 32 | params.num_ant_UE = [1, 4, 2]; % Number of antenna elements for the user arrays in the x,y,z-axes 33 | 34 | % Antenna array orientations 35 | params.activate_array_rotation = 1; % 0 -> no array rotation - 1 -> apply the array rotation defined in params.array_rotation_BS and params.array_rotation_UE 36 | params.array_rotation_BS = [0, 0, -20]; 37 | % 3D rotation angles in degrees around the x,y,z axes respectively 38 | % The rotations around x,y,z are also called as slant, downtilt, and bearing angles (of an antenna towards +x) 39 | % The origin of these rotations is the position of the first BS antenna element 40 | % The rotation sequence applied: (a) rotate around z-axis, then (b) rotate around y-axis, then (c) rotate around x-axis. 41 | % To define different orientations for the active BSs, add multiple rows.. 42 | % Example: For two active BSs with different array orientations, you can define 43 | % params.array_rotation_BS = [[10, 30, 45]; [0, 30, 0]]; 44 | 45 | params.array_rotation_UE = [0, 20, 0]; 46 | % User antenna orientation settings 47 | % For uniform random selection in 48 | % [x_min, x_max], [y_min, y_max], [z_min, z_max] 49 | % set [[x_min, x_max]; [y_min, y_max]; [z_min, z_max]] 50 | % params.array_rotation_UE = [[0, 30]; [30, 60]; [60, 90]]; 51 | 52 | params.enable_BS2BSchannels = 1; % Enable generating BS to BS channel (could be useful for IAB, RIS, repeaters, etc.) 53 | 54 | % Antenna array spacing 55 | params.ant_spacing_BS = [0.5 0.7]; % ratio of the wavelength; for half wavelength enter .5 56 | params.ant_spacing_UE = .5; % ratio of the wavelength; for half wavelength enter .5 57 | 58 | % Antenna element radiation pattern 59 | params.radiation_pattern = 0; % 0: Isotropic and 60 | % 1: Half-wave dipole 61 | 62 | % System parameters 63 | params.bandwidth = 0.05; % The bandwidth in GHz 64 | params.activate_RX_filter = 0; % 0 No RX filter 65 | % 1 Apply RX low-pass filter (ideal: Sinc in the time domain) 66 | 67 | % Channel parameters # Activate OFDM 68 | params.generate_OFDM_channels = 1; % 1: activate frequency domain (FD) channel generation for OFDM systems 69 | % 0: activate instead time domain (TD) channel impulse response generation for non-OFDM systems 70 | params.num_paths = 10; % Maximum number of paths to be considered (a value between 1 and 25), e.g., choose 1 if you are only interested in the strongest path 71 | 72 | % OFDM parameters 73 | params.num_OFDM = 512; % Number of OFDM subcarriers 74 | params.OFDM_sampling_factor = 1; % The constructed channels will be calculated only at the sampled subcarriers (to reduce the size of the dataset) 75 | params.OFDM_limit = 64; % Only the first params.OFDM_limit subcarriers will be considered 76 | 77 | params.saveDataset = 0; % 0: Will return the dataset without saving it (highly recommended!) -------------------------------------------------------------------------------- /DeepMIMO-5GNR/Example_1/Example_1_params.m: -------------------------------------------------------------------------------- 1 | %Ray-tracing scenario 2 | params.scenario= 'O1_60'; % The adopted ray tracing scenarios [check the available scenarios at www.aalkhateeb.net/DeepMIMO.html] 3 | 4 | %Dynamic Scenario Scenes 5 | params.scene_first = 1; 6 | params.scene_last = 1; 7 | 8 | %%%% DeepMIMO parameters set %%%% 9 | % Active base stations 10 | params.active_BS=1; % Includes the numbers of the active BSs (values from 1-18 for 'O1') 11 | 12 | % Active users 13 | params.active_user_first = 1; % The first row of the considered receivers section (check the scenario description for the receiver row map) 14 | params.active_user_last = 2; % The last row of the considered receivers section (check the scenario description for the receiver row map) 15 | 16 | % Subsampling of active users 17 | % Setting both subsampling parameters to 1 activate all the users indicated previously 18 | params.row_subsampling = 1; % Randomly select round(row_subsampling*(active_user_last-params.active_user_first)) rows 19 | params.user_subsampling = 1; % Randomly select round(user_subsampling*number_of_users_in_row) users in each row 20 | 21 | % System parameters 22 | params.enable_BS2BSchannels=1; % Enable (1) or disable (0) generation of the channels between basestations 23 | params.num_paths=15; % Maximum number of paths to be considered (a value between 1 and 25), e.g., choose 1 if you are only interested in the strongest path 24 | 25 | % If 5G toolbox is activated, the relevant previous parameters will be overridden 26 | params.CDL_5G.NRB = 66; % Number of NR blocks 27 | params.CDL_5G.SCS = 120; % kHz - Subcarrier Spacing 28 | 29 | params.OFDM_sampling_factor=1; % The constructed channels will be calculated only at the sampled subcarriers (to reduce the size of the dataset) 30 | params.OFDM_limit=256; % Only the first params.OFDM_limit subcarriers will be considered when constructing the channels 31 | 32 | % UE Movement Model 33 | % The maximum Doppler shift will be determined from the velocity 34 | % For a fixed velocity, select a scalar value. 35 | % For random speed selection of each user sample, 36 | % set it to [min_vel, max_vel] and it will take a uniform random 37 | % value in (min_vel, max_vel); 38 | params.CDL_5G.Velocity = [1, 30]; % UE velocity in km/h - 39 | 40 | % UT Direction of travel - If a 1x2 vector is given, the direction is 41 | % fixed. E.g., 42 | % [0; 90] % UT Travel direction in degrees - 43 | % [azimuth; zenith] - [0; 90] corresponds to +x 44 | % 45 | % If a 2x2 matrix of [min_az, max_az; min_zen, max_zen] is given 46 | % it will be uniformly randomly sampled for each user. 47 | params.CDL_5G.UTDirectionOfTravel = [0, 360; 90, 90]; 48 | 49 | % # of consecutive OFDM slots to be sampled. 50 | % (14*num_slots channel samples will be returned) 51 | params.CDL_5G.num_slots = 2; 52 | 53 | % The LOS path (if there is any in the ray-tracing) is split into Rician paths with the K-factor. 54 | % 13.3dB is the CDL-D channel K factor given in 3GPP 38.901 7.7.1-4. 55 | % 22dB is the CDL-E channel K factor given in 3GPP 38.901 7.7.1-5. 56 | params.CDL_5G.KFactorFirstCluster = 13.3; 57 | 58 | % Cross-polarization power ratio in dB 59 | % The values defined in 3GPP 38.901 are 60 | % CDL-A: 10, CDL-B: 8, CDL-C: 7, CDL-D: 11, CDL-E: 8. 61 | params.CDL_5G.XPR = 10; 62 | 63 | %%%%%%%%%%%%%%%%%%%%%%%%%% Antenna Definiton %%%%%%%%%%%%%%%%%%%%%%%%%% 64 | % Antenna Arrays of Isotropic Elements 65 | % Orientation: 66 | params.CDL_5G.bsArrayOrientation = [0, 0]; % azimuth (0 deg is array look direction +x, 90 deg is +y) and elevation (positive points upwards) in deg 67 | % If there are multiple active antennas are available, and different 68 | % orientations are targeted, a row of orientations can be given. E.g., with 69 | % 2 active antennas, we can set: 70 | % params.CDL_5G.bsArrayOrientation = [[0, 0]; [90, 0]]; 71 | 72 | params.CDL_5G.ueArrayOrientation = [-180, 0; 0, 60]; % azimuth (0 deg is array look direction +x, 90 deg is +y) and elevation (positive points upwards) in deg 73 | % For a random UE orientation, set [az_min, az_max; el_min, el_max]. 74 | % The Azimuth and Elevation directions are uniformly sampled from 75 | % [az_min, az_max] and [el_min, el_max]. E.g., 76 | % params.CDL_5G.ueArrayOrientation = [0, 360; 0, 60]; 77 | % The resulting array orientation of a UE can be viewed at 78 | % path_params.ueArrayOrientation 79 | 80 | % Size: 81 | params.CDL_5G.bsAntSize = [4, 8]; % number of rows and columns in rectangular BS array 82 | % If there are multiple active antennas are available, and different 83 | % antennta sizes are targeted, a row of different panel sizes can be given. 84 | % E.g., with 2 active antennas, we can set: 85 | % params.CDL_5G.bsAntSize = [[4, 8]; [2, 2]]; 86 | 87 | params.CDL_5G.ueAntSize = [1, 1]; % number of rows and columns in the rectangular UE array 88 | 89 | % Polarized antennas, setting it to 1 places 2 cross polarized antennas 90 | % for each antenna element in the array. In this case, there will be 91 | % twice the number of antennas selected in ueAntSize and bsAntSize 92 | % parameters, based on the corresponding parameters. 93 | % For instance, if bsAntSize = [4,8] and bsPolarization is 1, 94 | % the transmitter will have 64 antennas. Similary, the ueAntSize is 95 | % doubled with the uePolarization. 96 | params.CDL_5G.uePolarization = 0; 97 | params.CDL_5G.bsPolarization = 0; 98 | 99 | % Custom Antenna Array Definition with Phased Array Toolbox 100 | % 101 | % If the indicator is activated, the following custom antenna objects 102 | % will be adopted by the CDL model. This way, directive 103 | % and different shapes of antenna arrays can be defined. 104 | % 105 | % The details of the Phased Array System Toolbox 106 | % can be found at https://www.mathworks.com/help/phased/index.html. 107 | params.CDL_5G.customAntenna = 0; 108 | if params.CDL_5G.customAntenna 109 | % Calculate wavelength for defining custom antenna object 110 | carrier_frequency = 60; %GHz 111 | lambda = carrier_frequency*1e9/physconst('LightSpeed'); 112 | 113 | % Example UPA with (0.5*lambda) spacing in both directions 114 | params.CDL_5G.bsCustomAntenna = phased.URA('Size', params.CDL_5G.bsAntSize(1:2), 'ElementSpacing', 0.5*lambda*[1 1]); 115 | 116 | % If there are multiple BS antennas activated, it can be 117 | % defined as a cell of the antennas corresponding to each active 118 | % BS, e.g., 119 | % antenna1 = phased.URA('Size', [2 2], 'ElementSpacing', 0.5*lambda*[1 1]); 120 | % antenna2 = phased.URA('Size', [4 4], 'ElementSpacing', 0.5*lambda*[1 1]); 121 | % params.CDL_5G.bsCustomAntenna = {antenna1, antenna2}; 122 | 123 | params.CDL_5G.ueCustomAntenna = phased.URA('Size', params.CDL_5G.ueAntSize(1:2), 'ElementSpacing', 0.5*lambda*[1 1]); 124 | end 125 | %%%%%%%%%%% 5G NR Toolbox based CDL channel Generation %%%%%%%%%%%%%%%%% 126 | 127 | params.saveDataset=0; --------------------------------------------------------------------------------