Class Notes (838,347)
United States (325,353)
CS 1371 (28)
Smith (1)
Lecture

# 11-28 Notes.txt

2 Pages
96 Views

Department
Computer Science
Course
CS 1371
Professor
Smith
Semester
Fall

Description
fridge=struct('Shelf1',▯{'bananas',▯'yogurt',▯'pizza',▯'macaroni▯and▯cheese'},'Q uantity',▯{2,▯3,▯1,▯1},▯'wantToEat',▯{false,▯false,▯true,▯true}); yum=fridge(strcmp({fridge.Shelf1},▯'pizza')); A=class(fridge(1));▯WRONG [r▯c]=size(fridge); B=r.*c;▯WRONG C=fridge{1,▯2}; D=yum.wantToEat;▯WRONG E=fridge(2).Quantity; NUMERICAL▯METHODS▯NOTES interpolation▯▯▯estimating▯values▯within▯data▯set▯range ex)▯x=[1▯3▯6▯7▯14]▯,▯can▯only▯interpolate▯from▯1▯14 extrapolation▯▯▯estimating▯values▯outside▯the▯data▯set▯range ex)▯could▯extrapolate▯from▯1▯15 interpolation▯types: 1.▯linear will▯literally▯draw▯straight▯lines▯across▯the▯points 2.▯cubic cubic▯function▯(curves▯and▯stuff)▯across▯the▯points interp1()▯function new_y=interp1(x,y,new_x)▯*new_x▯can▯be▯a▯scalar▯or▯an▯array LENGTH▯OF▯X▯AND▯Y▯MUST▯BE▯THE▯SAME spline()▯function new_y=spline(x,y,new_x) extrapolation spline() same▯syntax▯as▯abo ¦aâutomatically▯recognizes▯it▯if▯you▯ask▯for▯an▯x▯outside▯the▯dat a▯range interp1()▯function new_y=interp1(x,y,new_x,'spline')▯<
More Less

Related notes for CS 1371
Me

OR

Join OneClass

Access over 10 million pages of study
documents for 1.3 million courses.

Join to view

OR

By registering, I agree to the Terms and Privacy Policies
Just a few more details

So we can recommend you notes for your school.