xi = 0:.01:10; g0=1; wc = 1; r = g0*sin(wc*xi)/xi; plot(xi,r) whs {??? Undefined function or variable 'whs'. } whos Name Size Bytes Class Attributes g0 1x1 8 double r 1x1 8 double wc 1x1 8 double xi 1x1001 8008 double r = g0*sin(wc*xi)./xi; plot(xi,r) plot(xi,r) wc = 2; r = g0*sin(wc*xi)./xi; hold Current plot held plot(xi,r,'r') wc = .5; r = g0*sin(wc*xi)./xi; plot(xi,r,'g') wc =2; g0=0.5; r = g0*sin(wc*xi)./xi; plot(xi,r,'k') plot(xi,r,'g') s = 1; l = 1; r = s^2*exp(-l*xi); plot(xi,r); omg = 0:.01:10; g = 2*s^2*l^3/(pi*(omg.^2+l^2).^2); {??? Error using ==> mrdivide Matrix dimensions must agree. } g = 2*s^2*l./(pi*(omg.^2+l^2)); figure plot(omg,g); l = .25; r = s^2*exp(-l*xi); figure(1) hold Current plot held plot(xi,r,'r'); g = 2*s^2*l./(pi*(omg.^2+l^2)); figure(2) plot(omg,g,'r'); l = 1; g = 2*s^2*l./(pi*(omg.^2+l^2)); hold Current plot held plot(omg,g); edit specth t = 0:.1:100; t = 0:.1:10; x1 = 1*sin(1*t) + 2*sin(2*t); plot(t,x1) t = 0:.1:40; x1 = 1*sin(1*t) + 2*sin(2*t); plot(t,x1) x2 = 2*sin(1*t) + 1*sin(2*t); hold Current plot held plot(t,x2,'r') edit sd [t,x]=specth('sd',0,5,10,10,1000,1,1,123); plot(t,x) omg = 0:.1:10; g = sd(omg); figure plot(omg,g) [t,x]=specth('sd',0,10,100,10,1000,1,1,123); figure(1) hold Current plot held plot(t,x,'r') [t,x]=specth('sd',0,10,100,100,10000,1,1,123); plot(t,x,'r') [t,x]=specth('sd',0,10,100,50,10000,1,1,123); plot(t,x,'r') [t,x]=specth('sd',0,10,20,50,10000,1,1,123); plot(t,x,'r') [t,x]=specth('sd',0,10,10,50,10000,1,1,123); hold Current plot held plot(t,x,'b') diary off