Publications by Fares A
605_M5_post
Exercise 3 chapter 1: In the early 1600s, Galileo was asked to explain the fact that, although the number of triples of integers from 1 to 6 with sum 9 is the same as the number of such triples with sum 10, when three dice are rolled, a 9 seemed to come up less often than a 10|supposedly in the experience of gamblers. Write a program to simula...
774 sym
605_week4hm
The exercise was to “With the attached data file, build and visualize eigenimagery that accounts for 80% of the variability. Provide full R code and discussion.” To start with, I will begin by loading the images, converting them into a suitable numerical format for analysis, performing Principal Component Analysis (PCA) to identify the eige...
1415 sym R (3497 sym/8 pcs) 1 img
C40 problem
To solve Exercise C40 in chapter LT: Problem: If \(T: \mathbb{C}^2 \rightarrow \mathbb{C}^2\) satisfies \(T\left(\begin{bmatrix} 2 \\ 1 \end{bmatrix}\right) = \begin{bmatrix} 3 \\ 4 \end{bmatrix}\) and \(T\left(\begin{bmatrix} 1 \\ 1 \end{bmatrix}\right) = \begin{bmatrix} -1 \\ \frac{1}{2} \end{bmatrix}\), find \(T\left(\begin{bmatrix} 4 \\ 3 \...
1074 sym
607_week3_project1
I used the same chess text data file suggested in the project 1 page on blackboard (so that the data is available to whoever going to run the code again). I’m first going to try to clean the data and turn into into a structured form. # structuring the data library(stringr) # indicating the separator lines separator_indices <- grep("^-+$",...
683 sym R (7224 sym/11 pcs) 1 img
605_wk3discussion
Exercise #T10 in the PEE within chapter E of the book: Suppose that \(A\) is a square matrix. Prove that the constant term of the characteristic polynomial of \(A\) is equal to the determinant of \(A\). Solution The characteristic polynomial of a square matrix \(A\) of size \(n \times n\) is given by \[ p(\lambda) = \det(A - \lambda I) \] whe...
1058 sym
605_wk3_discussionpostMichael
library(pracma) A <- matrix(c(3, 2, 1, 0, 1, 1, 1, 2, 0), nrow = 3, byrow = TRUE) char_poly <- charpoly(A) char_poly ## [1] 1 -4 0 5...
5 sym R (167 sym/2 pcs)
607_week3HW
df <- read.csv("https://raw.githubusercontent.com/fivethirtyeight/data/master/college-majors/majors-list.csv") Q1. Using the 173 majors listed in fivethirtyeight.com’s College Majors dataset, provide code that identifies the majors that contain either “DATA” or “STATISTICS” selected_majors <- df[grep("DATA|STATISTICS", df$Major, ignore...
1481 sym
607_week1
Data 607 Week 1 assignment I chose the article titled “According To Super Bowl Ads, Americans Love America, Animals And Sex” which can be found at the URL https://projects.fivethirtyeight.com/super-bowl-ads/. Introduction The FiveThirtyEight analysis of Super Bowl ads reveals Americans’ affinity for themes of humor, patriotism, celebrities...
2011 sym R (3885 sym/7 pcs) 2 img
C31 post
Solving the problem posted by Jacob Silver: C31 Question C31 asks to solve the following set of linear equations: 3x + 2y = 1 x - y = 2 4x + 2y = 2 To solve this, we can use the matrix form of the equations: Matrix A: \[ A = \begin{pmatrix} 3 & 2 \\ 1 & -1 \\ 4 & 2 \end{pmatrix} \] Matrix B: \[ B = \begin{pmatrix} 1 \\ 2 \\ 2 \end{pmatri...
482 sym R (278 sym/2 pcs)
C22
Exercise C22 in chapter VS: Find the dimension of the subspace \(W\) of \(P_3\), given by: \[ W = \{ a + bx + cx^2 + dx^3 \mid a + b + c + d = 0 \} \] coeff_matrix <- matrix(c(1, 0, 0, -1, # polynomial a - d 0, 1, 0, -1, # polynomial b - d 0, 0, 1, -1), # polynomial c - d ...
157 sym