蜂窝小区同频干扰的Matlab仿真Word文档格式.docx

上传人:wj 文档编号:647473 上传时间:2023-04-29 格式:DOCX 页数:19 大小:662.04KB
下载 相关 举报
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第1页
第1页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第2页
第2页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第3页
第3页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第4页
第4页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第5页
第5页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第6页
第6页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第7页
第7页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第8页
第8页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第9页
第9页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第10页
第10页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第11页
第11页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第12页
第12页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第13页
第13页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第14页
第14页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第15页
第15页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第16页
第16页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第17页
第17页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第18页
第18页 / 共19页
蜂窝小区同频干扰的Matlab仿真Word文档格式.docx_第19页
第19页 / 共19页
亲,该文档总共19页,全部预览完了,如果喜欢就下载吧!
下载资源
资源描述

蜂窝小区同频干扰的Matlab仿真Word文档格式.docx

《蜂窝小区同频干扰的Matlab仿真Word文档格式.docx》由会员分享,可在线阅读,更多相关《蜂窝小区同频干扰的Matlab仿真Word文档格式.docx(19页珍藏版)》请在冰点文库上搜索。

蜂窝小区同频干扰的Matlab仿真Word文档格式.docx

DESCRIPTIONOFTHEEXPERIMENTS

1.Writeaprogramtocalculatethesignalinterferenceratio(SIR)intheforwardlink,andrepeatsitbyrandomlychangingthepositionoftheMS.Afteranumberofsimulations,usethesimulatedresultstodrawthehistogramoftheSIR(S=I).TrytoobtainhistogramswithdifferentpathlossexponentnandclustersizeN.Concludeyourresults.

Theco-channelinterferenceintheforwardlinkcanbecharacterizedinfigure1.AMSwillbeinterferedbytheco-channelbasestation.Inoursimulation,weconsiderthe18co-channelcell,including6cellsinthefirstloopand12cellsinthesecond,nomatterwhattheclustersizeNis.

Figure1forwardlinkco-channelinterference

(1)Firstly,weshouldrandomlychoosethepositionoftheMSinthecell.Sincethecellishexagonwhichishardtohandlewecutandpasteitintoasquare.Aswecanseeinfigure2,thecenterofthecoordinationisthecenterofthecell.ThesquarewechooseisABCD.WethenrandomlychooseapairofxandyasthecoordinateofMS.IfMSlocatesintriangle1wecutandpasteittotriangle3andifitlocatesintriangle2wemoveittotriangle4.

Weassumetherangeofthebasestationis0.1asradiusofclusteris1.FortheMSwholocatedwithinthisarea,wechangeitsdistancetobe0.1asitistooclosetothebasestaion.

Figure2randomlychoosethepositionofMSinacell

Matlabcode:

RandPOS.m

%*******************************************************************

%ThisfunctionistogettherandomlylactionoftheMSwithmtimes.

%zisam*1matrixwithcoodinatevaluex,y

%*******************************************************************function[z]=RandPOS(m)

%********getrandomvalueofx,ywithinasquare*****%x=1.5*rand(m,1)-1;

y=sqrt(3)*rand(m,1)-0.5*sqrt(3);

%********useforlooptocutthesquareintoahexagon*****%fork=1:

m

ifx(k)>

-1&

&

x(k)<

-0.5&

y(k)>

(1+x(k))*sqrt(3)x(k)=x(k)+1.5;

y(k)=y(k)-sqrt(3)/2;

elseifx(k)>

y(k)<

-(1+x(k))*sqrt(3)x(k)=x(k)+1.5;

y(k)=y(k)+sqrt(3)/2;

end

%********iftheMSistoonearlytothebasestation ******%ifsqrt(x(k)^2+y(k)^2)<

0.1

x(k)=0.1;

y(k)=0;

z=x+j*y;

.

(2)Secondly,weshouldcalculatethecoordinateofco-channelbasestation.AsweknowtheclustersizeNwecancalculatethe(i,j)pairbytheformula𝑁

=𝑖

2+𝑖

*𝑗

+𝑗

2

ClusterN.m

%*********************************************************

%Thisfunctionistofindi&

jcorrespondtoagivenN

%asN=i^2+j^2+ij

%iiandjjistheresultofi,j

%********************************************************function[ii,jj]=ClusterN(N)

%thelargestnumberofiandjissqrt(N)

fora=0:

sqrt(N)

forb=0:

ifa^2+b^2+a*b==Nii=a;

jj=b;

end;

%endifend;

%forjj

(3)TakingN=7asexample,wecancalculatethecoordinatebyreferringtofigure3.AccordingtothevalueofIjpairandanglesinthefigurewecangetthecoordinateofthefirst loop by the formula:

𝑗

×

𝑝

𝑖

+𝑗

𝑝

𝑗

𝑙

𝑜

𝑐

𝑎

𝑡

𝑛

(𝑘

)=3×

(𝑖

𝑒

6

3×

(𝑘

‒1)+𝑗

)),wherek=1,2….6.The

doublethecoordinateofthe

firstlooppoints

diagnoseofaparallelogram

secondloopcanbecalculatedbythefirstloop.Therearetwokindsofsecondloopco-channelbasestation.Onecanbecalculatedbydoublethecoordinateofthefirstlooppoints.Theothercanbedonebyaddingcoordinatesofadjacentfirstlooppointasitisthediagnoseofaparallelogram.Examplesofthosetwokindsofpoints,point1and2,canbefoundinfigure3

Figure3calculatecoordinateofco-channelbasestationbyIJpair

AdjCel.m

%**************************************************************************

%Thisfunctionistofindcellularscoordinatesx+jy

%(BaseStationsinthemiddle)foragivenN(soasi/j)

%CelLocisa18*1matrixwiththecoordinatesoftheco-interference

%cellofthefirsttwocycle.(6forthefirstcycleand12forthesecond)

%**************************************************************************function[CelLoc]=AdjCel(N)

%********CallClusterNfunctontogettheiandjvalue*******%[ii,jj]=ClusterN(N)

%********18locationsconsideringtwocycleofco-interferencecell*******%CelLoc=zeros(18,1)+j*zeros(18,1);

%********calculatethefirstco-interferencecell*******%CelLoc

(1)=sqrt(3)*(ii*exp(j*pi/6)+jj*exp(j*pi/6+j*pi/3));

%********theothercellsare60degreeshiftofthelastcell*******%fork=2:

6

CelLoc(k)=CelLoc(k-1)*(0.5+sqrt(3)/2*j);

end;

%********thesecond12co-interferencecellsarethevectoraddtionofthefirstcycle*******%

fori=1:

CelLoc(2*i+5)=CelLoc(i)+CelLoc(i);

CelLoc(2*i+6)=CelLoc(i)+CelLoc(i+1);

CelLoc(18)=CelLoc(6)+CelLoc

(1);

(4)NowwehavecoordinatesofMSandco-channelbasestation,sowecancalculateSIRby

(𝑑

𝑚

𝑠

)‒𝑛

𝑆

𝐼

𝑅

=18



)‒𝑛

𝑑

theformula

𝑖

=1

𝑏

,where

𝑚

standsforthedistancefromMStothecenter

while

𝑑

𝑏

standsforthedistancefromtheco-channelbasestationtotheMS.We

simulatedit100000times.

%ForwardLink

clearallcloseall

N=input('

theclustersizeN='

);

n=input('

thepathlossexponentn='

)M=100000;

%thetimesofsimulation

%***callfunctiontogettherandomlylacationoftheuser***%MSPos=RandPOS(M);

%***callfunctiontogetthelacationof18co-interferencecells***%CelLoc=AdjCel(N);

%***dsisthe'

-n'

powerofthedistancebetweenMSandBaseStation***%ds=(abs(MSPos)).^-n;

%***calculatethe'

powerofthedistancebetweenMSandBaseStationoftheco-interferencecell***%

ditemp1=abs(MSPos*(ones(18,1))'

-ones(M,1)*CelLoc'

ditemp2=ditemp1.^-n;

%***addthedistanceofinteferencetogather.***%di=ditemp2*ones(18,1);

%***theSIR***%SIR=10*log(ds./di);

%EverageSIR=SIR*ones(1,M)/Mhist(SIR,[-20:

250])

title('

Histogram'

xlabel('

SIR(dB)'

ylabel('

numbersofMS'

(5)Rsults:

WewillsimulatetheSIRoftheco-interferenceoftheforwardinglinkwithdifferentclustersize‘N’andpathloseexponent‘n’andplaintthehistogramofeachcondition.Tomakeacomparison,wechosetwogroupofnandNas:

Whenn=3.6,weletN=1,3,4,7,12.WhenN=7,weletn=2,3,3.5,4.

IftherandomMSistoonearlytothebase

station,d<

𝑑

0ord=0,theSIRwillbetoohigh.

Sowhend<

0,weletd=𝑑

0toremovetheBS.

.0istherangeofthebasestation.

(𝑑

)‒𝑛

Figure5histogramofSIRwhileN=1,n=3.6

Figure6histogramofSIRwhileN=3,n=3.6

Figure7histogramofSIRwhileN=4,n=3.6

Figure8histogramofSIRwhileN=7,n=3.6

Figure9histogramofSIRwhileN=12,n=3.6

Figure10histogramofSIRwhileN=7,n=2

Figure11histogramofSIRwhileN=7,n=3

Figure12histogramofSIRwhileN=7,n=3.5

Figure13histogramofSIRwhileN=7,n=4

WecanseefromthehistogramthattheaverageSIRincreasewithNincrease.Sincethedistancebetweentheclusterandtheco-interferencecellislargerwhenNislarger,sotheco-interferenceissmaller.ForaconstantclustersizeN,theSIRislargerasthepathloseexponentbecomeslarger.Sincewhennischanging,theco-interferencepowerisreducedmuchmorethanthesignalpower.Eventhoughthesystemwilllosemorepower,theSIRisbecomeslarger.

2.WriteaprogramtocalculatetheSIRinthereverselink,andrepeatsitbyrandomlychangingthepositionsoftheMSs.(Notethattheinterferencesinthereverselinkaregeneratedbyco-channelMSsandisdifferentfromtheinterferenceintheforwardlink.)Afteranumberofsimulations,usethesimulatedresultstodrawthehistogramoftheSIR.TrytoobtainhistogramswithdifferentpathlossexponentnandclustersizeN.Concludeyourresults.

Theco-channelinterferenceinthereverselinkcanbecharacterizedin

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > PPT模板 > 动态背景

copyright@ 2008-2023 冰点文库 网站版权所有

经营许可证编号:鄂ICP备19020893号-2