Timothy Cook
ASU ID:1211408169
Reflection
I believe some of the biggest challenges facing computing today are ethics, privacy and
security. There is much controversy over these topics, and poor ethical decisions combined with
sensitive data can lead to di

%Timothy Cook
%3/1/16
%MATLAB HW 2
%Activity 2.4
clear all
% 4x4 matrix.
a = [3,7,-4,12;-5,9,10,2;6,13,8,11;15,5,4,1]
%a.)
0inds the max and min for each Column
%max
maxCol1 = max(a(:,1)
maxCol2 = max(a(:,2)
maxCol3 = max(a(:,3)
maxCol4 = max(a(:,4)
%mini

%Timothy Cook
%3/1/16
%MATLAB HW 2
%Activity 2.3
clear all
% 4x4 matrix.
a = [3,7,-4,12;-5,9,10,2;6,13,8,11;15,5,4,1]
%a.)
%column 3 from matrix a represented as a vector.
v = a(:,3)
'.)
%row 2 from matrix a represented as a vector.
w = a(2,:)

%Timothy Cook
%2/23/16
%Homework 1
%Activity 1.9
%Various operations using the help function.
clear all
close all
help plot
help label %returns nothing, however lookfor label will return usefull
information.
help cos
help cosine %this returns nothing, how

%Timothy Cook
%2/23/16
%Homework 1
%Activity 1.8
%Creating a plot.
%T = 6*ln(t) - 7e^(0.2t) over the interval t=[1,3]
%T is temp in celsius
%t is time in minutes
clear all
close all
t = [1,3];
T = 6*log(t) - 7*exp(0.2*t);
plot(t,T), ylabel('Temperature In

%Timothy Cook
%2/23/16
%Homework 1
%Activity 1.7
%Find the roots of the polynomial 70*x^3 + 24*x^2 - 10*x + 20
clear all
close all
a = [70, 24, -10, 20];
roots(a)

%Timothy Cook
%2/23/16
%Homework 1
%Activity 1.6
% Magnitudes = 7.6 and 5.6
% Energy related to magnitude is E = (10^44)*(10^(1.5*M)
%I will input both magnitudes into the equation, then subtract
%to get how much more energy is released by the bigger quak

%Timothy Cook
%2/23/16
%Homework 1
%Activity 1.5
%Creating an array, finding length, and finding element.
clear all
close all
%array
x = [1:.2:5];
y = 7*sin(4*x);
arrayLength = length(x)
thirdElement = x(3)

%Timothy Cook
%2/23/16
%Homework 1
%Activity 1.4
%Volume of gas in July vs. December
clear all
close all
NULLariables
P = 2.2; %pressure
R = .08; %constant found online
n = (P*28500) / (R*(-15 + 273.2); %amount of gas
0ow we do V = nRT / P to find volume

%Timothy Cook
%2/23/16
%Homework 1
%Activity 1.3
%Various functions involving the imaginary number i.
clear all
close all
%a.)
A = (3+6i)*(-7-9i)
'.)
B = (5 + 4i) / (5 - 4i)
%c.)
C = (3/2)*i
0.)
D = 3/2i

%Timothy Cook
%2/23/16
%Homework 1
%Activity 1.2
clear all
close all
x = 2;
y = 5;
%a.)
A = (y*x)^3) / (x - y)
'.)
B = (3*x) / (2*y)
%c.)
C = (3/2)*x*y
0.)
D = x^5 / (x^5 - 1)

%Timothy Cook
%2/23/16
%Homework 1
%Activity 1.1
clear all
close all
X = 10;
Y = 3;
%a.)
U = X + Y
'.)
V = X*Y
%.c)
W = X/Y
0.)
Z = sin(X)
%e.)
R = 5*sin(2*Y)

Timothy Cook
MATLAB Homework 1
Rudy Emrick
2/24/16
Activity 1.1 Script:
clear all
close all
X = 10;
Y = 3;
%a.)
U = X + Y
'.)
V = X*Y
%.c)
W = X/Y
0.)
Z = sin(X)
%e.)
R = 5*sin(2*Y)
Activity 1.1 Answers:
U = 13
V = 30
W = 3.3333
Z = -0.5440
R = -1.3971
Ac