R

Read how to get R installed in a conda environment.

Before doing anything else, let's take a quick look at the general method...


In [38]:
# Using inverse...
A <- matrix(c(1,2,3,4), ncol=2)
A


Out[38]:
13
24

In [40]:
b <- c(7, 10)
b


Out[40]:
  1. 7
  2. 10

In [42]:
x <- solve(A)%*%b
x


Out[42]:
1
2

In [44]:
# Or...
solve(A, b)


Out[44]:
  1. 1
  2. 2

In [43]:
A %*% x - b


Out[43]:
0
0

In [ ]: