This preview shows page 1. Sign up to view the full content.
Unformatted text preview: b) for time=1:1:Time; r=rand; x=x+(2*r-1); end % 'for' loop c) for time=1:1:Time; r=rand; if r<0.4 r=rand; x=x+r; elseif r<0.8 r=rand; x=x-r; else x=x; end end...
View Full Document
This note was uploaded on 07/12/2011 for the course BIM 107 taught by Professor Raychaudhari during the Spring '11 term at UC Davis.
- Spring '11