Help with recursion limit!
显示 更早的评论
Help! When I run my code on my laptop it runs without error, but when I run it from an old computer it throws me the error:
Maximum recursion limit of 500 reached. Use set(0,'RecursionLimit',N) to change the limit. Be aware that exceeding your available stack space can crash MATLAB and/or your computer. Error in coder.allowpcode
and I need to run my code from the old computer. I set also the recursion limit to a bigger value, but my matlab program crash, and I just try until de maximum value in order that matlab do not crash ans also gives me that error. Can somebody help me, I don't understand why is this.
My code is:
function hLMChan= nume(Ts,Fd,pathDelays,avgPathGains)
hLMChan = rayleighchan(Ts,Fd,pathDelays,avgPathGains); hLMChan.StoreHistory=1;
M = 2; % Modulation order
hMod = comm.BPSKModulator(0);
Rsym = 1200; % Input symbol rate
Rbit = Rsym * log2(M); % Input bit rate
Nos = 2; % Oversampling factor
Ts = (1/Rbit) / Nos; % Input sample period
Fd = 1; % Chosen maximum Doppler shift for simulation
pathDelays = [0 0.002];
avgPathGains = [0 0]; N = 10000;
Nsamples = 100; %number of samples per frame
dop = doppler.gaussian;
hLMChan.DopplerSpectrum = dop;
plot(hLMChan);
for frames = 1:N
inputSig = step(hMod, randi([0 M-1], Nsamples, 1)); % Apply the channel effects % Channel filter %run signal through channel
end
end
6 个评论
Jan
2015-5-18
Please post the complete error message. Which function causes the recursion? Currently we see only the function "nume", but the code does not contain a recursive call.
Muresan Aronia
2015-6-3
We would be happy to help you, but you need to give us the exact information that we ask for: instead you just gave us another copy of the code that you already gave in your question.
Please give the complete and whole error message, and explain/show where this recursive call is happening.
Walter Roberson
2015-6-4
Stephen the original problem was solved somehow and the new question is wildly different
Muresan Aronia
2015-6-5
回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Surrogate Optimization 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!