Final Exam: Review Flashcards

1
Q

Define a computer program

A

a set of instructions to perform a task that processes input and output. It is composed of a source code and an executable

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

List the 5 steps involved in computer programming

A
  1. Designing
  2. writing
  3. debugging
  4. validating
  5. maintaining

dootlite wont drink very much

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

List the three basic constructs (structures) used to program an any programing language

A
  1. sequential
  2. conditional
  3. iterative
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

State the fundamental problem of linear algebra

A

Ax=b solve for x

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Is trapz more accurate than riemann sums?

A

yes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

what is more accurate, diff or gradient

A

gradient

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

When solving a linear system of equations, if the rank of the coefficient matrix equals the rank of the augmented matrix, an explicit solution will always exist?

A

False

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

When solving a linear system of equations, if the rank of the coefficient matrix doesnt equal the rank of the augmented matrix, the system is undertimined

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is an efficient way of solving a system of linear equations when the rank of the coefficient matrix is less than the number of unknowns?

A

A\b

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Can the mean function be used only to determine the mean value of a vector?

A

No

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is trapz used for?

A

determine indefinite integral with O(h^2) accuracy

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What two commands can be used to calculate least squares solutions?

A

polyfit and \

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What two commands can be used to enable the calculation of intermediate values in a given data set?

A

ineterp1 and polyfit

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Commands to from a large excel file named data.xls assign the contents of cells A1 through A10 to the array my data

A

MyData=xlsread(‘data.xls’,’A1;A10’)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Commands to test a variable, y, to determine if it is between 0 and 5, inclusive of the end points

A

if y>1 & y<5
then g=1
end

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Commands if given two vectors t and h, determine the maximum value of ha and the corresponding value of t

A

[x,y]=max(h)

maxt=t(x)

17
Q

Commands to determine the number of rows and columns and pages in the matrix, NoisyPic

A

size(NoisyPic)

18
Q

For a flow chart, what are the shapes of the boxes?

A
Start and end = circle
If states = triangles
command statements = rectanges
display = slanted rectangle
else = slanted rectangle
19
Q

What is the curve fit equation for logarithmic?

A

u=logx
v=y
[p,s]=polyfit(u,v,1)