<jupyter_start><jupyter_text>Practical Lab Exam 1<jupyter_code>import numpy as np

#Given Matrices
W = np.array ([[1,-3],[2,-2],[3,1]])
X = np.array ([[3,2,1],[-1,2,3],[2,-1,1]])
Y = np.array ([[1,2,0],[0,-1,2]])
Z = np.array ([[0,1],[2,3]])<jupyter_output><empty_output><jupyter_text>PROBLEM 1<jupyter_code>#a. WY
WY = np.dot(W,Y)
print (WY)
#b. Z + Z
print (Z + Z)
#c. 3X
C= np.multiply(3,X)
print(C)<jupyter_output>[[ 9  6  3]
 [-3  6  9]
 [ 6 -3  3]]<jupyter_text>PROBLEM 2<jupyter_code>#a. The product (YW)^2 is not defined
YW = np.dot(Y,W)
print (np.square(YW))

if YW is None:
    print("The statement is TRUE")
else:
    print("The statement is FALSE")

#The matrix is defined, therefore the statement is FALSE
#b. WY - X = 
A = np.dot(W,Y)
b = A - X
print (b)

x = np.array ([[-2,3,-7],[3,4,-7],[1,6,1]])

if (np.array_equiv(x,b)):
  print("The statement is TRUE")
else:
  print("The statement is FALSE")

#The statement is TRUE
#c. YW – Z^2 =
YW = np.dot(Y,W)
c = YW - np.square(Z)
print (c)

z = np.array ([[5,-9],[0,2]])

if (np.array_equiv(z,c)):
  print("The statement is TRUE")
else:
  print("The statement is FALSE")
#The statement is FALSE<jupyter_output>[[ 5 -8]
 [ 0 -5]]
The statement is FALSE
{'fraction_non_alphanumeric': 0.21681780708985984, 'fraction_numerical': 0.04781533388293487, 'mean_word_length': 4.1440677966101696, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '3', 'dir': 'jupyter-structured-clean-dedup', 'id': '205512', 'license': 'Apache-2.0', 'n_tokens_mistral': 586, 'n_tokens_neox': 571, 'n_words': 145, 'path': 'Practical_Lab_Exam_1.ipynb', 'repo_name': 'ryanmaullon/Linear-Algebra-58020', 'size': '1213'}