全文预览已结束
下载本文档
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
% % Rayleigh Fading Channel Signal Generator % Using the Dent Model (a modification to the Jakes Model)% Last Modified 10/18/05% Author: Avetis Ioannisyan ()% Usage:% omega_mTau, Tk = % ai_RayCh(NumAngles, Length, SymbolRate, NumWaveforms, CarrierFreq, Velocity)% Where the output omega_mTau is a time scaling factor for plotting% normalized correlations. The LAGS value output by C,LAGS = XCORR(.)% should be multiplied by the omega_mTau scaling factor to properly display% axis. Tk is a two dimensional vector M, N = SIZE(Tk) with% M=numWaverorms and N=Length specified in the RayCh(.) function call% And the input variables are:% NumAngles - scalar power of 2, NumAngles 27 is used to specify the% number of equally strong rays arriving at the receiver. It used to% compute the number of oscillators in the Dent model with N0 = numAngles/4% Length - scalar preferably power of 2 for faster computation, Length 217% is used to specify the length of the generated sequence. Lengths near 1E6% are close to realistic signals% % SymbolRate - scalar power of 2 and is in kilo-symbols-per-sec is used to% specify what should be the transmission data rate. Slower rates will% provide slowly fading channels. Normal voice and soem data rates are% 64-256 ksps% NumWaveforms - scalar used to specify how many k waveforms to generate% in the model. NumWaveforms 2 to properly display plots% % CarrierFreq - scalar expressed in MHz is the carrier frequency of the% tranmitter. Normally 800 or 1900 MHz for mobile comms% Velocity - scalar expressed in km/hr is the speed of the receiver. % 100 km/hr = 65 mi/hr. Normal values are 20-130 km/hr% % Usage Examples:% omega_mTau, Tk = ai_RayCh(27, 218, 64, 2, 900, 100)% % where% NumAngles=27, Length=218, symbolRate=64, NumWaveforms=2, carrierFreq=900, Velocity=100% omega_mTau, Tk = RayCh(NumAngles, Length, symbolRate, NumWaveforms,% carrierFreq, Velocity);%function omega_mTau, Tk = ai_RayCh(NumAngles, Length, symbolRate, NumWaveforms, carrierFreq, Velocity)% Number of oscillatorsN0 = NumAngles/4;% Maximum Doppler shift of carrier at some wavelengthomega_m = (2*pi) * fm(Velocity, carrierFreq);% specify variance of the Rayleigh channel% use this for *constant* variange - requires changing other params in progsigma2 = 10;% make sigma2 a gaussian RV around u = sigma2 and var = sigma2/5% use for *non constant* variaance - requires changing other params in progsigma2 = sigma2 + sqrt(sigma2/5) .* randn(1,NumWaveforms);% Initialize phasesalpha_n = ; beta_n = ; theta_nk = ; % make a hadamard matrixAk = hadamard(N0);% determine phase values alpha and betan=1:N0;alpha_n = 2*pi*n/NumAngles - pi/NumAngles;beta_n = pi*n/N0;% convert to time scale using fs sampling frequencyt=1/(symbolRate*1000):1/(symbolRate*1000):1/(symbolRate*1000) * Length;Tk = ;for q = 1 : NumWaveforms rand(state,sum(100*clock) % reset randomizer theta_nk = rand(1,length(n) * 2 *pi; % create uniform random phase in range 0,2pi sumRes = 0;for i = 1 : N0 term1 = Ak(NumWaveforms,i); term2 = cos(beta_n(i) + j*sin(beta_n(i); term3 = cos(omega_m .* t .* cos(alpha_n(i) + theta_nk(i); sumRes = sumRes + (term1 .* term2 .* term3);end Tk(q,:) = sqrt(2/N0) .* sumRes; % use line below to apply *non-constant* variance Tk(q,:) = repmat(10.(sigma2(q)/20),1, Length) .* Tk(q,:); %apply variable in dB end% apply *constant* variance unilaterly in dB % Tk = repmat(10(sigma2/20), k, Length) .* Tk; % plot resultsfigure(20); subplot(3,1,1); semilogy(t,abs(Tk(1,:);xlabel(Time (sec); ylabel(Signal Strength (dB); title(Received Envelope, Symbol Rate = , num2str(symbolRate), ,Carrier = , num2str(carrierFreq), , Velocity = , num2str(Velocity);% compute auto and cross correlations and plot themomega_mTau = (1/(symbolRate*1000) * (omega_m/(2*pi); % compute omega_m * tau scalingC1, Lags = crosscorr(Tk(1,:), Tk(2,:), 20000);C2, Lags2 = autocorr(Tk(1,:), 20000);figure(20); subplot(3,1,3); plot(Lags * omega_mTau, C1);xlabel(Normalized Time Delay); ylabel(Normalized Crosscorrelation); title(Crosscorre
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 淋球菌penA等位基因变异对头孢曲松耐药及生物适应度的影响研究
- 涵洞变形对土压力的影响机制与规律研究
- 液态金属电池内电涡流与磁流体流动不稳定性的多维度探究
- 液体除湿技术的性能优化与系统创新研究
- 涉税鉴证的使用与停止:基于道德风险模型的深度剖析
- 消费者过度自信视角下物联网信息服务定价策略的深度剖析与优化路径
- 商业咨询与分析报告手册
- 妊娠期胆源性胰腺炎的微创治疗策略比较
- 妊娠期结核病合并妊娠期胎儿窘迫的胎儿头皮血气分析
- 2026辽阳市中考语文知识点背诵清单练习含答案
- 传承黄河精神不负青春使命
- 木材的纤维结构和解剖学特征
- 《猪生产》课程标准
- 《镍基高温合金》课件
- 部编版六年级下册期末语文阅读理解测试试题(比较难)及解析
- GB/T 29465-2012浮头式热交换器用外头盖侧法兰
- 上海市卫生和健康发展研究中心(上海市医学科学技术情报研究所)招考聘用【共500题含答案解析】模拟检测试卷
- GB/T 13934-2006硫化橡胶或热塑性橡胶屈挠龟裂和裂口增长的测定(德墨西亚型)
- DB32∕T 4108-2021 混凝土复合保温砌块(砖)墙体自保温系统应用技术规程
- 山东省第四届高校体育教师基本功大赛
- J-STD-020D[1].1中文版
评论
0/150
提交评论