poisson.m
来自「基于OFDM的无线宽带系统仿真It contains mainly two pa」· M 代码 · 共 13 行
M
13 行
function n = poisson(navg)% DESCRIPTION n = mrequest(navg)% an aproximation of a poisson distribution% TRY poisson(10),poisson(0:10),poisson(ones(2,2,2))% by Magnus Almgren 000803siz = size(navg);navg = shiftdim(navg,-1); % free first dimension by shifting them to the rightveclength = round(max(100, 10*max(navg(:)))); n = sum(mplus(rand([veclength siz]),-navg/veclength) < 0,1); % make a realisationn = shiftdim(n,1); % move back again
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?