I am currently programming some large scripts in matlab. I have discovered that when using 'while' loops, or 'for' loops, etc. the processing time increases almost exponentially.
I am looking for why loops greatly slow down the program in matlab and how to fix it without taking out the loops and just copying and pasting the code out. Any help would be greatly appreciated.