当前位置:网站首页>[OFDM communication] simulation of OFDM multi-user resource allocation based on MATLAB [including Matlab source code 1902]
[OFDM communication] simulation of OFDM multi-user resource allocation based on MATLAB [including Matlab source code 1902]
2022-06-23 05:04:00 【Poseidon light】
One 、OFDM brief introduction
In order to alleviate the increasingly tense situation of wireless spectrum , Cognitive radio technology has received more and more attention . Compared with traditional transmission technology , Cognitive radio technology has higher flexibility and intelligence . Its biggest feature is that it can sense the surrounding spectrum environment ( Mainly spectrum usage ), Find the spectrum hole that can be used [1], Use the idle frequency band in a specific time and in a specific geographical location , Thus, the spectrum efficiency and system capacity are greatly improved .
Cognitive radio technology is the development trend of communication technology after software radio technology , It reflects the development of communication technology from network to intelligence . Radio technology has gone through a fixed pattern , After adaptive mode, it develops to cognitive mode . Cognitive radio has the function of perception , And by perceiving the results , Select transmission scheme , At the same time, the wireless terminal has “ Study ” function , And the ability to generate new alternative transmission schemes .
OFDM Compared with other transmission technologies, this technology has the advantage of flexible allocation of subcarriers , As a promising technology in the next generation communication standard , It also has a broad application prospect in cognitive radio . The frequency band used by cognitive users is not fixed , Is random , And may be discontinuous .OFDM The bandwidth can be adjusted by adaptively allocating zero power to individual subcarriers , Its advantage is that it can flexibly allocate subcarriers and control their power . The author aims at OFDM The system presents a multi-user subcarrier and its power allocation algorithm .
1 Cognitive radio system model
Cognitive radio system embodies higher intelligence , It can actively sense the wireless environment , Sensing the surrounding spectrum usage , Therefore, the cognitive radio system must have a spectrum analysis and channel estimation unit to detect the spectrum , Look for spectrum holes that can be used . The spectrum hole used by cognitive radio refers to the spectrum hole that has been allocated to authorized users , The frequency band not used by the authorized user within a specific time or used at a specific geographical location far away .
chart 1 Schematic diagram of cognitive loop
The classical cognitive radio system includes the perception of wireless environment 、 Spectrum resource estimation 、 Resource allocation algorithm , It forms a closed loop , Pictured 1 Shown .
Simon Haykin Put forward the concept of cognitive ring , In the cognitive loop, it can be seen that cognitive radio systems need to consider a new physical quantity —— Disturbance temperature . The interference temperature limits the power distribution in the spectrum , That is, the upper limit of channel capacity is limited . Cognitive radio system can detect the spectrum usage and the interference temperature on the corresponding spectrum , Dynamically allocate resources among multiple users , To make full use of the spectrum .
How to make multiple cognitive users make full use of the detected spectrum holes , How to allocate these subcarriers among multiple cognitive users , And allocating transmission power on these subcarriers . This is the focus of this paper . The principle block diagram of transmitter with multi-user adaptive resource allocation is shown in the figure below 2 Shown . In traditional multi-user OFDM Resource detection is added to the system 、 Power allocation algorithm and power control unit .
2 Multi user resource allocation algorithm
Resource allocation refers to cognition AP(Access Point) The downlink of the node is for multiple types of cognitive users ( The type can be mobile phone , Car radio ,PDA Or others ) Research on the algorithm of . cognition AP Nodes efficiently use the detected spectrum holes to dynamically allocate the spectrum resources in the downlink in real time . The resource allocation algorithm mainly considers two factors: power constraints and device types .
cognition AP After the node receives the cognitive user request information that requires communication , First, detect the surrounding spectrum usage , Find the spectrum hole that can be used , At the same time, it is necessary to obtain the fading characteristics of all cognitive users on the available spectrum holes , And the information of authorized users within the power coverage of the whole system . These are cognitions AP The basis for node resource allocation algorithm .
cognition AP The node shall complete power allocation and subcarrier assignment in the downlink according to the information obtained above , The power allocation algorithm of cognitive radio should consider the power interference to authorized users . When allocating resources , The allocated power of power limited subcarriers shall not exceed their respective upper power limits , This requires the allocation algorithm to allocate a pre allocated power to each subcarrier , So as not to interfere with the normal communication of authorized users .
Follow the principle of proportional fairness in the process of resource allocation , Prevent users with good channel characteristics from occupying most spectrum holes , Other users, especially those with poor channel characteristics, cannot guarantee normal communication . In this paper, only the interference of cognitive users to authorized users is considered . The interference of cognitive users on authorized users is mainly reflected in the interference on the signal to interference ratio of authorized users .
set up RSI Indicates the signal to interference ratio at the authorized user ,
It can be seen that this is a nonlinear optimization problem , The solution of the optimal value is very complicated , This paper presents a two-step suboptimal value algorithm which first allocates subcarriers and then allocates power .
Two 、 Partial source code
clear all;
worstpower=1.1565;
N0=worstpower*1e-8;
Ptotal=1;
BER = 1e-3;
Gap = -log(5*BER)/1.6;
channelnum=10;
samplenum=10;
numuser = 8;
epsilong=1e-3;
maxNumOfNewton=0;
maxTotalNewtonIteNum=0;
avenonlintime = zeros(1,numuser);
aveshentime = zeros(1,numuser);
aveiantime = zeros(1,numuser);
diffuservector = [];
iancapamat = [];
shencapamat = [];
cc = 1;
clear shencapa iancapa
N=64; % Number of subcarriers
B=1000000; % Bandwidth is 1MHz
noise=B*N0/N;
clear ch
%for different user number
for ii=1:numuser,
diffuser=2*ii;
diffuservector(ii)=diffuser;
K=diffuser;
totaliancapa=0;
totalshencapa=0;
totalnonlincapa = 0;
shencapavec = zeros(1,diffuser);
iancapavec = zeros(1,diffuser);
iannorm = 0;
shennorm = 0;
nonlinnorm = 0;
%for different channel
for chan=1:channelnum,
chan
[env,I,Q]=chtry(K,samplenum,30);
h = rand(1,K);
gamma = .064*(h < .5) + .128*((h >= .5) & (h < .8)) + .256*(h>.8);%%how to generate the coefficient
%for diff samples
for diffsamp=1:samplenum,
diffsamp
for i=1:K
user=I(i,:,diffsamp)+sqrt(-1)*Q(i,:,diffsamp);
ch(i,:)=abs(fft(user,N)).^2/Gap;%%channel in frequency domain
end
% Shen's subcarrier allocation
[rheecapa,rheesuballo]=rheesub(Ptotal,ch, N, K, noise, gamma);
% Shen's power allocation
t=cputime; shenp = shenpowerallo(ch,rheesuballo,N,K,Ptotal,noise,gamma); shentime = cputime-t;
aveshentime(ii) = aveshentime(ii) + shentime;
% Ian's subcarrier allocation
[iancapa,iansuballo]=wongsuballo(Ptotal, ch, N, K, noise, gamma);
% Ian's power allocation
t=cputime; ianp = wongpowerallo(ch,iansuballo,N,K,Ptotal,noise,gamma); iantime = cputime-t;
aveiantime(ii) = aveiantime(ii) + iantime;
for i=1:K,
shencapa(i) = waterfilling(shenp(i),rheesuballo(i,:).*ch(i,:)/noise)/N;
iancapa(i) = waterfilling(ianp(i),iansuballo(i,:).*ch(i,:)/noise)/N;
end;
totalshencapa=totalshencapa+sum(shencapa);
totaliancapa=totaliancapa+sum(iancapa);
if (chan == 1),
shencapavec = shencapavec + shencapa;
iancapavec = iancapavec + iancapa;
if (chan == 1 & diffsamp == 1),
figure(2);
bar([gamma/sum(gamma); iancapavec/sum(iancapavec); shencapavec/sum(shencapavec)]', 'grouped');%; nonlincapavec/sum(nonlincapavec)]', 'grouped');
title(' snapshot ');
end;
end;
iannorm = iannorm + norm(iancapa/sum(iancapa) - gamma/sum(gamma), inf);
shennorm = shennorm + norm(shencapa/sum(shencapa) - gamma/sum(gamma), inf);
end
if (chan == 1),
iancapavec = iancapavec/(channelnum*samplenum);
shencapavec = shencapavec/(channelnum*samplenum);
figure(5);
bar([gamma/sum(gamma); iancapavec/sum(iancapavec); shencapavec/sum(shencapavec)]', 'grouped');
legend(' gamma ', ' linear ', ' Search for roots ');
end;
%end diff channel
end
maxNumOfNewton;
maxTotalNewtonIteNum;
totalshencapavec(ii)=totalshencapa/(channelnum*samplenum);
totaliancapavec(ii)=totaliancapa/(channelnum*samplenum);
iannormvec(ii) = iannorm/(channelnum*samplenum);
shennormvec(ii) = shennorm/(channelnum*samplenum);
end
% total capacities plot
figure(1)
plot(diffuservector,totaliancapavec, 'ko--', diffuservector, totalshencapavec, 'b+-.');%, diffuservector, totalnonlincapavec, 'rx-.');
iansumcapa = sum(totaliancapavec)
shensumcapa = sum(totalshencapavec)
grid on
xlabel(' The number of users ')
ylabel(' Capacity (bit/s/Hz)')
legend(' linear ', ' Search for roots '); %, 'NONLIN');
hold off
aveshentime = aveshentime/(channelnum*samplenum)
aveiantime = aveiantime/(channelnum*samplenum)
figure(3);
semilogy(diffuservector,aveiantime, 'ko--', diffuservector,aveshentime, 'b+-.');%, diffuservector, avenonlintime, 'rx-.');
grid on
xlabel(' The number of users ')
ylabel(' Average CPU Time (s)')
legend(' linear ', ' Search for roots '); %, 'NONLIN');
title(' Average CPU Time comparison ');
3、 ... and 、 Running results




Four 、matlab Edition and references
1 matlab edition
2014a
2 reference
[1] Shen Zaiyang . Master MATLAB signal processing [M]. tsinghua university press ,2015.
[2] Gao Baojian , Peng Jinye , Wang Lin , Pan Jianshou . Signals and systems —— Use MATLAB Analysis and Implementation [M]. tsinghua university press ,2020.
[3] Wang Wenguang , Wei Shaoming , Ren Xin . Signal processing and system analysis MATLAB Realization [M]. Electronic industry press ,2018.
[4] Li Weiying , Chen2 dong , Xingchengwen , Wang Ning . In cognitive radio systems OFDM Multi user resource allocation algorithm [J]. Journal of Xi'an University of Electronic Science and Technology . 2007,(03)
3 remarks
This part of the introduction is taken from the Internet , For reference only , If infringement , Contact deletion
边栏推荐
- AD9使用技巧拾遗
- OGNL Object-Graph Navigation Language
- Pads and flash symbols in cadence
- 2020:VL-BERT: Pre-training of generic visual-linguistic representation
- 2 万字 + 20张图|细说 Redis 九种数据类型和应用场景
- 开发一年不到,来面试居然敢开口要20K,面完连8K都不想给~
- Alkylation process test questions and simulation test in 2022
- 项目总结1(头文件,switch,&&,位变量)
- ICer技能03Design Compile
- Please use the NLTK Downloader to obtain the resource
猜你喜欢

Abnova fluorescent dye 555-c3 maleimide scheme

centos7安装postgresql8.2.15及存储过程创建

Pads and flash symbols in cadence

Reinstallation of cadence16.3, failure and success

Meituan's good article: understand swift, Objective-C and the mixing mechanism from the perspective of precompiling

Dsp7 environment

元数据管理Apache Atlas编译(内嵌式)部署及遇到各种错误记录

PCB----理论与现实的桥梁

聊聊 C# 中的 Composite 模式
Using editor How to handle MD uploading pictures?
随机推荐
Amazing tips for using live chat to drive business sales
传统意义上的互联网式的平台或将不复存在,一个融合的产业特质和互联网特质的全新产业
McKinsey: in 2021, the investment in quantum computing market grew strongly and the talent gap expanded
Laravel中使用 Editor.md 上传图片如何处理?
Current relay jdl-1002a
Function declaration and call of 17 generator
Abnova abcb10 (human) recombinant protein specification
元数据管理Apache Atlas编译(内嵌式)部署及遇到各种错误记录
Apache atlas quick start
ICer技能02makefile脚本自跑vcs仿真
cadence中的焊盘和flash symbol
free( )的一个理解(《C Primer Plus》的一个错误)
With the arrival of intelligent voice era, who is defining AI in the new era?
Alkylation process test questions and simulation test in 2022
Summary of switched reluctance motor suspension drive ir2128
电流继电器JDL-1002A
Parameter passing of 18 generator function
Gson typeadapter adapter
395. redundant path
An understanding of free() (an error in C Primer Plus)