recursal/Fanatic-Fandom huggingface dataset:
清平樂·禁庭春晝（鄭氏中古漢語拼音）

**Transliterated by Tao Steven Zheng (鄭濤)**

## **清平樂·禁庭春晝 【tsyeng1 byeng1 ngak4·gim1 deng1 tsuun1 dhyuu3】**

**李白 【Li2 Bek4】**

禁【gim1】庭【deng1】春【tsuun1】晝【dhyuu3】，

鶯【'eng1】羽【hyo2】披【pie1】新【sin1】繡【syuu3】。

百【bek】草【tso】巧【kao】求【giuu】花【hua】下【ha】鬥【do】，

只【tie】賭【do】珠【dzio】璣【gi】滿【muan】鬥【do】。

日【nyit】晚【muan】卻【kyak】理【li】殘【dzan】妝【tsyang】，

禦【ngyo】前【dzen】閒【ghien】舞【muu】霓【nge】裳【dzyang】。

誰【suui】道【do】腰【yao】肢【gi】窈【yo】窕【dio】，

折【tiet】旋【suen】笑【tsio】得【dvk】君【guun】王【uang】。

## **拟音系统注释**

**元音 Vowels**

a = 汉语拼音 a， 如 “江” 字的 ji**a**ng。

e = 汉语拼音其中一个 e， 如 “雷” 字的 l**e**i。

i = 汉语拼音 i， 如 “依” 字的 y**i**。

o = 汉语拼音其中一个 o， 如 “哦” 字的 **o**。

u = 汉语拼音其中一个 o， 如 “宫” 字的 g**o**ng。

uu = 汉语拼音 u，如 “乌” 字的 w**u**。

v = 汉语拼音其中一个 e， 如 “厄” 字的 **e**。

**i + 元音 与 y + 元音 的区别**

**i + 元音** 的发音比较慢，**y + 元音** 的发音比较快。

**辅音 Consonants**

gh = 用喉咙低一点部位发出 h 音。

dz = 汉语拼音 j。

ts = 汉语拼音 c 或 q。

## **清平樂·禁庭春晝 【t͡sʰiᴇŋ bˠiæŋ ŋˠʌk̚·kˠiɪm deŋ t͡ɕʰiuɪn ʈɨuH】**

**李白 【lɨX bˠæk̚4】**

禁【kˠiɪm】庭【deŋ】春【 t͡ɕʰiuɪn】晝【ʈɨuH】，

鶯【ʔˠɛŋ】羽【ɦɨoX】披【pʰˠiᴇ】新【siɪn】繡【sɨuH】。

百【byek】草【tso】巧【kao】求【giuu】花【hua】下【ha】鬥【do】，

只【tie】賭【do】珠【dzio】璣【gi】滿【muan】鬥【do】。

日【nyit】晚【muan】卻【kyak】理【li】殘【dzan】妝【tsyang】，

禦【ngyo】前【dzen】閒【ghien】舞【muu】霓【nge】裳【dzyang】。

誰【suui】道【do】腰【yao】肢【gi】窈【yo】窕【dio】，

折【tiet】旋【suen】笑【tsio】得【dvk】君【guun】王【uang】。
The Armoury

**Problem created by Tao Steven Zheng (郑涛)**

## **Problem**

There are 1000 soldiers in a conscript army. A crossbowman carries only one crossbow. A spearman carries only one spear. A swordsman carries only one sword. A foot soldier carries one spear and one sword. There are 350 swords and 500 spears. If there are 200 foot soldiers, then how many crossbowmen were conscripted?

## **Solution**

Let there be two categories of soldiers: melee and ranged. Spearmen, swordsmen, and foot soldiers are melee; crossbowmen are ranged.
We know there are 200 foot soldiers, each requiring one sword and one spear.

500 – 200 = 300 spearmen

350 – 200 = 150 swordsmen

300 + 150 + 200 = 650 melee soldiers

1000 – 650 = 350 crossbowmen

There were 350 crossbowmen conscripted.
Planetary Orbits with Python

**By: Tao Steven Zheng (郑涛)**

```
import numpy as np
import matplotlib.pyplot as plt
import scipy.integrate as spi

# Define the right side of system of ODEs
def odefun(u,t):
    dudt = [0,0,0,0] #dudt = [x, x', y, y']
    D3 = (u[0]\*\*2 + u[2]\*\*2)\*\*(3/2)
    dudt[0] = u[1]
    dudt[1] = -G\*m\_star\*u[0]/D3
    dudt[2] = u[3]
    dudt[3] = -G\*m\_star\*u[2]/D3
    return dudt

# Compute the solution
t = np.linspace(0,tf,1000)
u = spi.odeint(odefun,u0,t)

# The columns of the output are (in order): x, x', y, y'
plt.plot(u[:,0],u[:,2],0,0,'ro')
plt.axis('equal')
plt.grid(True)
plt.show()

```
Rotation Matrix

## **Problem**

Consider the rotation matrix in two dimensions

A

=

[

cos
⁡
θ

−
sin
⁡
θ

sin
⁡
θ

cos
⁡
θ

]

.

{\displaystyle \mathbf{A} =
 \begin{bmatrix}
 \cos\theta & -\sin\theta \\
 \sin\theta & \cos\theta \\
 \end{bmatrix}.}

Determine the eigenvalues and eigenvectors of the rotation matrix.

## **Solution**

First obtain the characteristic equation.

det
(
A
−
λ
I
# )
0

{\displaystyle \det(A - \lambda I) = 0 }

cos
⁡
θ
−
λ

−
sin
⁡
θ

sin
⁡
θ

cos
⁡
θ
−
λ

=
0

{\displaystyle
 \begin{vmatrix}
 \cos\theta - \lambda & -\sin\theta \\
 \sin\theta & \cos\theta - \lambda \\
 \end{vmatrix} = 0 }

(
cos
⁡
θ
−
λ
)
(
cos
⁡
θ
−
λ
)
−
(
−
sin
⁡
θ
)
(
sin
⁡
θ
# )
0

{\displaystyle (\cos \theta - \lambda)(\cos \theta - \lambda)-(-\sin \theta)(\sin \theta) = 0 }

λ

2

−
2
λ
cos
⁡
θ
# 1

{\displaystyle {\lambda}^{2} - 2\lambda \cos \theta + 1 = 0. }

Using the quadratic formula to find the eigenvalues, we get

# λ
cos
⁡
θ
±
i
sin
⁡
# θ

e

±
i
θ

.

{\displaystyle \lambda = \cos \theta \pm i \sin \theta = {e}^{\pm i\theta}. }

To solve for the eigenvectors

[

cos
⁡
θ
−
λ

−
sin
⁡
θ

sin
⁡
θ

cos
⁡
θ
−
λ

]

[

x
1

x
2

]

=

[

0

0

]

.

{\displaystyle
 \begin{bmatrix}
 \cos\theta - \lambda & -\sin\theta \\
 \sin\theta & \cos\theta - \lambda \\
 \end{bmatrix}
 \begin{bmatrix} x\_1 \\ x\_2
 \end{bmatrix} = \begin{bmatrix} 0 \\ 0
 \end{bmatrix}. }

For

# λ
cos
⁡
θ
i
sin
⁡
# θ

e

i
θ

{\displaystyle \lambda = \cos \theta + i \sin \theta = {e}^{i\theta} }

, we find

x
2

=
−
i

x
1

{\displaystyle x\_2 = -ix\_1 }

, so

[

x
1

x
2

]

=

[

1

−
i

]

.

{\displaystyle
 \begin{bmatrix} x\_1 \\ x\_2
 \end{bmatrix} = \begin{bmatrix} 1 \\ -i
 \end{bmatrix}. }

For

# λ
cos
⁡
θ
−
i
sin
⁡
# θ

e

−
i
θ

{\displaystyle \lambda = \cos \theta - i \sin \theta = {e}^{-i\theta} }

, we find

x
2

=
i

x
1

{\displaystyle x\_2 = ix\_1 }

, so

[

x
1

x
2

]

=

[

1

i

]

.

{\displaystyle
 \begin{bmatrix} x\_1 \\ x\_2
 \end{bmatrix} = \begin{bmatrix} 1 \\ i
 \end{bmatrix}. }
清平調（鄭氏中古漢語拼音）

**Transliterated by Tao Steven Zheng (鄭濤)**

## **清平調 【tsyeng pyeng dio】**

**李白 【Li bak】**

**其一 【gi it】**

雲【huun】想【siang】衣【yi】裳【dzyang】花【hua】想【siang】容【yiung】，

春【tsuun】風【byung】拂【pyot】檻【kiam】露【lo】華【hua】濃【nung】。

若【nyak】非【buui】群【guun】玉【ngiok】山【san】頭【du】見【gen】，

會【kuai】向【hyang】瑤【yao】臺【dai】月【nguat】下【ha】逢【byung】。

**其二 【gi ni】**

一【it】枝【gi】紅【hung】豔【yem】露【lo】凝【nging】香【hyang】，

雲【huun】雨【uu】巫【muu】山【san】枉【uang】斷【duan】腸【dyang】。

借【dzia】問【muun】漢【han】宮【gyung】誰【dzuui】得【dvk】似【suu】？

可【ka】憐【len】飛【buui】燕【yen】倚【yi】新【sin】妝【tsyang】。

**其三 【gi sam】**

名【myeng】花【hua】傾【kyeng】國【gok】兩【liang】相【siang】歡【huan】，

長【dyang】得【dvk】君【guun】王【uang】帶【dai】笑【sio】看【kan】。

解【gai】釋【siek】春【tsuun】風【byung】無【muu】限【han】恨【huun】，

沉【dim】香【hyang】亭【deng】北【bak】倚【yi】闌【lan】幹【gan】。
Platonic Solids and the Euler Characteristic

**Activity created by Tao Steven Zheng (鄭濤)**

## Learning Objectives

This activity is an empirical investigation of Platonic solids and their relation to the Euler characteristic.

**Keywords:** Counting, arithmetic, solid geometry, nets, topology

## Materials

- Nets of Platonic solids printed on paper or card

- **(Optional)** Googolplex space building toy

## Procedure

### **Part 1**

Build the following polyhedra:

1) Tetrahedron (triangular pyramid)

2) Hexahedron (cube)

3) Octahedron

4) Dodecahedron

5) Icosahedron

### **Part 2**

Construct the following table. Count the number of vertices, edges, and faces for each polyhedron and record them in the table.

### **Part 3**

Let the **Euler characteristic

(
χ
)

{\displaystyle (\chi)}** be the constant that depends on

V
,
E
,

a
n
d

F

{\displaystyle V, E, \mathrm{and} \; F}

, where

V
,
E
,
F

{\displaystyle V, E, F}

 denotes the number of vertices, edges, and faces respectively. Verify that the formula

# χ
V
−
E
# F
2

{\displaystyle \chi = V - E + F = 2}

 holds true for the Platonic solids.

## Historical Background

**Platonic solids** are convex, regular polyhedra consisting of the tetrahedron (triangular pyramid), hexadron (cube), octahedron, dodecahedron, and icosahedron. These solids have identical faces made up of congruent convex regular polygons, and the same number of faces meet at each vertex. Although these five polyhedra are named after the Greek philosopher Plato (c. 428 - 348 BC), it was probably Pythagoras who first studied the tetrahedron, cube, and dodecahedron, and Theaetetus who discovered the octahedron and icosahedron.

**Euler's polyhedron formula**, or **Descartes-Euler polyhedral formula**, states that for any convex polyhedron, the number of vertices and faces together is exactly two more than the number of edges. This formula was discovered independently by Leonhard Euler (1752) and Rene Descartes (c. 1630). The explicit formula

V
−
E
# F
2

{\displaystyle V - E + F = 2}

 was given by Euler, while Euler's formula can be derived from Descartes' theorem on total angular defect

(
Δ
)

{\displaystyle (\Delta)}

, which states that

# Δ
4
π

{\displaystyle \Delta = 4\pi}

 and

# Δ
2
π
(
V
−
E
F
)

{\displaystyle \Delta = 2\pi(V - E + F)}

 for polyhedra.

### **Historical Timeline**

c. 360 BC – Plato writes about the five Platonic solids in the dialogue *Timaeus*

c. 300 BC – Euclid shows there are five regular polyhedra

c. 250 BC – Archimedes investigates truncated polyhedra

c. 1630 – Rene Descartes states his theorem on total angular defect

1752 AD – Leonhard Euler gives his formula for the numbers of vertices, edges, and faces in a polyhedron
Sun Zi's Algorithm

## **Problem**

The Chinese remainder problem is a number theory problem from ancient China. It originates from the study of calendrics during the Han dynasty (206 BC - 220 AD).

The Chinese remainder problem is a system of linear modular congruences

{

N

≡

r
1

(
mod

m
1

)

N

≡

r
2

(
mod

m
2

)

⋮

N

≡

r
n

(
mod

m
n

)

{\displaystyle \begin{cases}
 N &\equiv r\_1 \pmod{m\_1} \\
 N &\equiv r\_2 \pmod{m\_2} \\
 &\; \vdots \\
 N &\equiv r\_n \pmod{m\_n}
\end{cases}}

where

m
1

,

m
2

,
.
.
.
,

m
n

{\displaystyle m\_1, m\_2,...,m\_n}

 are mutually coprime. Determine the general solution to the Chinese remainder problem.

# M

m
1

m
2

.
.
.

m
n

{\displaystyle M = m\_1 m\_2 ... m\_n }

 and

M
i

=

M

m
i

{\displaystyle M\_i= \frac{M}{m\_i} }

.

From this construction,

M
i

{\displaystyle M\_i}

 shares no factors with

m
i

{\displaystyle m\_i}

; therefore,

{

gcd
(

m
1

,

M
1

# )
1

gcd
(

m
2

,

M
2

# )
1

⋮

gcd
(

m
n

,

M
n

# )
1

{\displaystyle \begin{cases}
\gcd(m\_1,M\_1) = 1 \\
\gcd(m\_2,M\_2) = 1 \\
\quad \quad \quad \; \vdots \\
\gcd(m\_n,M\_n) = 1
\end{cases}}

and

M
i

≡
0

(
mod

m
j

)

{\displaystyle M\_i \equiv 0 \pmod{m\_j} }

 when

j
≠
i

{\displaystyle j\neq i}

.

Let

s
1

,

s
2

,
.
.
.
,

s
n

{\displaystyle s\_1, s\_2, ..., s\_n}

 be the modular inverses of

M
1

,

M
2

,
.
.
.
,

M
n

{\displaystyle M\_1,M\_2,..., M\_n }

 respectively. By the property of modular inverses, we get

{

M
1

s
1

≡
1

(
mod

m
1

)

M
2

s
2

≡
1

(
mod

m
2

)

⋮

M
n

s
n

≡
1

(
mod

m
n

)

{\displaystyle \begin{cases}
 M\_1 s\_1 &\equiv 1 \pmod{m\_1} \\
 M\_2 s\_2 &\equiv 1 \pmod{m\_2} \\
&\; \vdots \\
 M\_n s\_n &\equiv 1 \pmod{m\_n}
\end{cases}}

Since

M
i

≡
0

(
mod

m
j

)

{\displaystyle M\_i \equiv 0 \pmod{m\_j} }

 whenever

j
≠
i

{\displaystyle j\neq i}

, it follows that

r
i

M
i

s
i

≡
0

(
mod

m
j

)

{\displaystyle r\_i M\_i s\_i \equiv 0 \pmod{m\_j} }

; thus,

{

r
1

M
1

s
1

≡

r
1

(
mod

m
1

)

r
2

M
2

s
2

≡

r
2

(
mod

m
2

)

⋮

r
n

M
n

s
n

≡

r
n

(
mod

m
n

)

{\displaystyle \begin{cases}
 r\_1 M\_1 s\_1 &\equiv r\_1 \pmod{m\_1} \\
 r\_2 M\_2 s\_2 &\equiv r\_2 \pmod{m\_2} \\
 &\; \vdots \\
 r\_n M\_n s\_n &\equiv r\_n \pmod{m\_n}
\end{cases}}

Therefore, the sum

∑

# i
1

n

r
i

M
i

s
i

{\displaystyle \sum\_{i=1}^{n} r\_i M\_i s\_i }

 satisfies all linear congruences in the original system, and the complete solution is

# i
1

n

r
i

M
i

s
i

(
mod

M
)
.

{\displaystyle N = \sum\_{i=1}^{n} r\_i M\_i s\_i \pmod{M}.}

## **Historical Note**

Sun Zi was an obscure Chinese mathematician who flourished sometime during the 3rd - 5th century AD. He authored the *Sunzi Suanjing (Master Sun's Computational Canon)*.
See-Through Mirrors 透光镜

**《梦溪笔谈·卷19器用12》**
世有透光鉴，鉴背有铭文，凡二十字，字极古，莫能读。 以鉴承日光，则背文及二十字，皆透在屋壁上，了了分明。人有原其理，以为铸时薄处先冷，唯背文上差厚，后冷而铜缩多。文虽在背，而鉴面隐然有迹，所以于光中现。予观之，理诚如 是。然予家有三鉴，又见他家所藏，皆是一样，文画铭字无纤异者，形制甚古。唯此一样光透，其他鉴虽至薄者皆莫能透。 意古人别自有术。

***Mengxi Bitan* Chapter 19 Qiyong 12**
I once saw a see-through mirror. Altogether twenty ancient Chinese characters were carved on its back, and they were undecipherable. If the mirror was put under the sunlight, the patterns and the characters would be clearly reflected on the wall. There were people who wanted to find out the reason for such a phenomenon. In their eyes, when the mirror was being cast its thinner parts cooled down first. As the parts carved with patterns and characters were thicker, they cooled down a bit more slowly, which caused the bronze to undergo deeper contraction. Though the patterns and characters were on the back of the mirror, their traces were still visible on the surface. That was why these patterns and characters were transparent in the sunlight. I once examined this mirror and thought that their explanation was reasonable. I have three mirrors in my own house, which, together with ancient mirrors that I find in other peoples’ houses, are of the same style, the same patterns and characters. However the sunlight can only make one of such mirrors transparent. Other mirrors are also thin, but the light cannot pass through them. I guess that the ancient artisans must have used a special method to make see-through mirrors.

**【今译】**

世上有能透光的镜，镜背面有铭文，共 20 字，字体非常古奥，没有人能读懂。用这面镜子承受 日光，那么背面的花纹和 20 个字都透射到墙上，清清楚楚。有人探求它的道理，认为是因为铸造时薄 的地方先冷，唯独有花纹和字的地方较厚，冷得慢，以致铜收缩要多一些。铭文和花纹虽然在背面， 但镜面也会隐约可见。所以镜子放在日光中就会现出来。我观察这面镜子，道理确实如此。但是我家 有三面镜子，另外看见别人家收藏的镜子，都是一样的，图案铭文没有一点差异，样式都非常古老。 只有那一面镜子能透光，其它的镜子也有非常薄的，却都不能透光。由此想来，古人在造这面镜子时自有别的方法。
Temperature Conversion with Python

**By: Tao Steven Zheng (郑涛)**

## **Task**

   Write a function that uses IF statements to convert temperatures in Fahrenheit to Celsius and Kelvin. Make sure the minimum temperature in Fahrenheit that still returns a numerical value is -459.67 (absolute zero).

Lastly, use your function to run three tests:

(1) Above absolute zero

The result should print the statements: **The temperature in Celsius is, C** and **The temperature in Kelvin is, K**
(2) Below absolute zero

The result should print the error statement: **Error, the temperature cannot be below absolute 0**
(3) At absolute zero

The result should print the statements: **The temperature in Celsius is -273.15** and **The temperature in Kelvin is 0.0**

## **Code**

```
def temp\_converter(F):
    C = 0   #set initial temperature in degrees Celsius as 0
    K = 0   #set initial temperature in Kelvins as 0
    if F < -459.67:
        print("Error, the temperature cannot be below absolute 0")
    if F >= -459.67:
        C = (F - 32) / 1.8
        K = C + 273.15
        print("The temperature in Celsius is", C)
        print("The temperature in Kelvin is", K)

'''Experiments'''
temp\_converter(100)     #Test 1
temp\_converter(-500)    #Test 2
temp\_converter(-459.67) #Test 3

```

## **Results**

**Test 1**

The temperature in Celsius is 37.77777777777778

The temperature in Kelvin is 310.92777777777775

**Test 2**

Error, the temperature is below absolute 0

**Test 3**

The temperature in Celsius is -273.15

The temperature in Kelvin is 0.0
Square Root of i

## **Problem**

**Part 1:** Express

i

{\displaystyle \sqrt{i} }

 in rectangular form

a
b
i

{\displaystyle a+bi}

.

**Part 2:** Express

i

{\displaystyle \sqrt{i} }

 in polar form

exp
⁡
(
i
θ
)

{\displaystyle \exp(i \theta) }

. Solve for the principle values of

θ

{\displaystyle \theta}

.

## **Solution**

**Part 1**

Let

i

=
a
b
i

{\displaystyle \sqrt{i} = a+bi }

then

# i

a
2

−

b
2

2
a
b
i

{\displaystyle i=a^2-b^2+2abi }

This implies

a
2

−

b
2

=
0

{\displaystyle a^2-b^2=0 }

and

2
a
# b

{\displaystyle 2ab=1. }

The first expression leads to the conclusion

# b
a

{\displaystyle b = a }

. Substitute this relation into the second expression

2

a
2

=
1

{\displaystyle 2a^2=1 }

. This shows that

# b
±

1

2

{\displaystyle a=b= \pm \frac{1}{\sqrt{2}} }

. Hence, the principle values are

i

=

1

2

i

2

{\displaystyle \sqrt{i}=\frac{1}{\sqrt{2}}+\frac{i}{\sqrt{2}} }

and

i

=
−

1

2

−

i

2

.

{\displaystyle \sqrt{i}=-\frac{1}{\sqrt{2}}-\frac{i}{\sqrt{2}}. }

**Part 2**

On the Argand diagram

1

2

i

2

{\displaystyle \frac{1}{\sqrt{2}}+\frac{i}{\sqrt{2}} }

 forms a 45° above the horizontal in quadrant 1 and

−

1

2

−

i

2

{\displaystyle -\frac{1}{\sqrt{2}}-\frac{i}{\sqrt{2}} }

 forms a 45° below the horizontal in quadrant 3.

This means for the solution in quadrant 1

1

2

i

2

=
cos
⁡

(

π
4

)

i
sin
⁡

(

π
4

)

.

{\displaystyle \frac{1}{\sqrt{2}}+\frac{i}{\sqrt{2}} = \cos\left(\frac{\pi}{4}\right) + i \sin\left(\frac{\pi}{4}\right).}

Since

cos
⁡

(

π
4

)

i
sin
⁡

(

π
4

)

=
exp
⁡

(

i
π

4

)

{\displaystyle \cos\left(\frac{\pi}{4}\right) + i \sin\left(\frac{\pi}{4}\right) = \exp\left(\frac{i\pi}{4}\right) }

we deduce

i

=
exp
⁡

(

i
π

4

)

.

{\displaystyle \sqrt{i} = \exp\left(\frac{i\pi}{4}\right).}

Similarly, the solution in quadrant 3 is

−

1

2

−

i

2

=
cos
⁡

(

5
π

4

)

i
sin
⁡

(

5
π

4

)

.

{\displaystyle -\frac{1}{\sqrt{2}}-\frac{i}{\sqrt{2}} = \cos\left(\frac{5\pi}{4}\right) + i \sin\left(\frac{5\pi}{4}\right).}

Since

cos
⁡

(

5
π

4

)

i
sin
⁡

(

5

π
4

)

=
exp
⁡

(

i
5
π

4

)

{\displaystyle \cos\left(\frac{5\pi}{4}\right) + i \sin\left(5\frac{\pi}{4}\right) = \exp\left(\frac{i5\pi}{4}\right) }

we deduce

i

=
exp
⁡

(

i
5
π

4

)

.

{\displaystyle \sqrt{i} = \exp\left(\frac{i5\pi }{4}\right).}
Su Song's Cosmic Engine

**By: Tao Steven Zheng (郑涛)**

The Cosmic Engine is an astronomical observatory and clock tower designed and built by Su Song and Han Gonglian between between 1088-1092 during the Song Dynasty (960-1279). When the capital of the Song Empire was captured by the Jurchens (later called the Manchus) in 1127 the invaders dismantled the Cosmic engine and carted it away to be reassembled in the Kingdom of Jin (which they were unable to put together).
Disney jungle boy 1 n 2

[ made by me ] [ for walt disney in 1920s ] [ based on jungle boy film n running wild book ]

## animals appers

asian elephants

giant pandas

bactrain camels

bengal tigers

black rhinos

panthers

komodos

tapirs

musk oxen

african elephants

quing pandas

dromdary camels

sumatra tigers

javen rhinos

lions

giraffes

hippos

zebras

wild beest

warthogs

hyenas

gazelles

cars

buses

bikes

planes

diggers

vans

boats

safari parks

jungles

towns

farms

woodlands

beaches

## cast [ 1 n 2 ]

takena wild boy [ in his 11 age ] [ who rise by asian elephants bengal tigers orangutans n bears ]

asian elephants

orangutans

bengal tigers

bears

wild boys

humans [ n one of the human girls in her 16 age ]

[ all wear uk cloths n 2 feet ]

mermaids

fariys

giant pandas

black rhinos

kangaroos

koalas

flamigos

komodos

panthers

eagles

duck bills

sloths

red pandas

toucans

[ asian austarilan congo south american n north american jungle ]
Rank and Nullity

## **Problem**

The rank-nullity theorem states:

Let

V

{\displaystyle V}

 and

W

{\displaystyle W}

 be vector spaces, where

V

{\displaystyle V}

 is finite in dimension. Let

T
:
V
→
W

{\displaystyle T \colon V \to W }

 be a linear transformation. Then,

Rank
⁡
(
T
)
Nullity
⁡
(
T
# )
dim
⁡
V

{\displaystyle \operatorname{Rank}(T) + \operatorname{Nullity}(T) = \dim V }

.
Determine the the rank and nullity of the linear transformation

[

1

2

3

4

5

6

]

{\displaystyle
 \begin{bmatrix}
 1 & 2 & 3 \\
 4 & 5 & 6
 \end{bmatrix}
}

## **Solution**

Row reduce the matrix until the pivots are one.

[

1

2

3

4

5

6

]

{\displaystyle
 \begin{bmatrix}
 1 & 2 & 3 \\
 4 & 5 & 6
 \end{bmatrix}
}

**Step 1: Subtract row 2 by four times row 1**

[

1

2

3

0

−
3

−
6

]

{\displaystyle
 \begin{bmatrix}
 1 & 2 & 3 \\
 0 & -3 & -6
 \end{bmatrix}
}

**Step 2: Divide row 2 by minus 3**

[

1

2

3

0

1

2

]

{\displaystyle
 \begin{bmatrix}
 1 & 2 & 3 \\
 0 & 1 & 2
 \end{bmatrix}
}

The row-reduced matrix illustrates the system

x
2
y
3
z

=
0

y
2
z

=
0

{\displaystyle \begin{align}
x + 2y + 3z &= 0 \\
y + 2z &= 0
\end{align}}

Let

# z
t

{\displaystyle z = t }

, where

t
∈

R

{\displaystyle t \in \mathbb{R} }

.

Then

# y
−
2
z

{\displaystyle y = -2z }

 and

# x
−
3
z
−
2
y

{\displaystyle x = -3z - 2y }

.

Subsequently, we find what mathematicians call the *kernel* (or nullspace).

[

x

y

z

]

=
t

[

1

−
2

1

]

{\displaystyle
 \begin{bmatrix}
 x \\
 y \\
 z
 \end{bmatrix} =
t \begin{bmatrix}
 1 \\
 -2 \\
 1
 \end{bmatrix}
}

Since the kernel has one vector, the nullity is 1.

Since

Rank
⁡
(
T
# )
dim
⁡
V
−
Nullity
⁡
(
T
)

{\displaystyle \operatorname{Rank}(T) = \dim V - \operatorname{Nullity}(T) }

, the rank of this linear transformation is

Rank
⁡
(
T
# )
3
−
# 1
2

{\displaystyle \operatorname{Rank}(T) = 3 - 1 = 2 }

.
Permutations of the Pocket Cube

## **Problem**

The 2x2x2 Rubik's cube is also called the Pocket Cube. Calculate the number of arrangements of the Pocket Cube if the cube is solved only by twisting the faces (a.k.a. making legal moves).

## **Solution**

Keep one corner piece of the Pocket Cube stationary and twist the other 7 corner pieces around the stationary corner. The non-stationary corner pieces can be permuted in

7
!

{\displaystyle 7! }

 ways. These non-stationary corner pieces can be in multiple orientations, so if we fix other 6 corners can be oriented in 3 directions. Therefore, the number of possible arrangements is

7
!
×

3
6

{\displaystyle 7! \times 3^6 }

.

7
!
×

3
6

=
5040
×
729

=
3674160

{\displaystyle \begin{align}
7! \times 3^6 &= 5040 \times 729 \\[ 5 pt]
&= 3674160
\end{align} }

Thus, the number of arrangements on a Pocket Cube is 3,674,160.
Sunzi Suanjing Lower Scroll 31

## **Problem**

This classic problem from the *Sunzi Suanjing* (孫子算經) is given the name "pheasants and rabbits in a cage" (雉兔同籠 zhì tù tóng lóng).

答曰：雉二十三。兔一十二。

術曰：上置三十五頭，下置九十四足。半其足，得四十七。以少減多，再命之，上三除下三，上五除下五。下有一除上一，下有二除上二，即得。

又術曰：上置頭，下置足。半其足，以頭除足，以足除頭，即得。

Answer: 23 pheasants, 12 rabbits.

Method: Set 35 heads in the upper position and 94 legs in the lower position. Halve the number of legs to obtain 47. Perform repeated [subtractions] by taking away the smaller from the larger [as follows]: the upper 3 is subtracted from the lower 4 and the upper 5 is subtracted from the lower 7; the lower 1 is subtracted from the upper 3 and the lower 2 from the upper 5 to obtain the answers.

Another method: Set the number of heads in the upper position and the number of legs in the lower position. Halve the number of legs and subtract the number of heads, subtract the result from the number of heads to obtain the answers.

## **Solution**

   The *Sunzi Suanjing* gives the following sequence.

(

35
94

)

→

94
÷
2

(

35
47

)

→

47
−
35

(

35
12

)

→

35
−
12

(

23
12

)

{\displaystyle {\binom {35}{94}}{\xrightarrow[{94\div 2\;}]{}}{\binom {35}{47}}{\xrightarrow[{47-35}]{}}{\binom {35}{12}}{\xrightarrow[{}]{35-12}}{\binom {23}{12}}}

Why does this method work? The sequence can be elaborated using linear algebra. Each pheasant has 1 head and 2 feet and each rabbit has 1 head and 4 feet; thus, we get a system of two linear equations in two unknowns

{

x
y

=
35

2
x
4
y

=
94

{\displaystyle {\begin{cases}x+y&=35\\2x+4y&=94\end{cases}}}

where

x

{\displaystyle x}

 represents the number of pheasants and

y

{\displaystyle y}

 represents the number of rabbits. By halving the number of feet, we are dividing the bottom equation by 2.

{

x
y

=
35

x
2
y

=
47

{\displaystyle {\begin{cases}x+y&=35\\x+2y&=47\end{cases}}}

Subtracting the bottom equation by the top equation eliminates the number of pheasants and solves for the number of rabbits.

{

x
y

=
35

y

=
12

{\displaystyle {\begin{cases}x+y&=35\\\quad \;\;\,y&=12\end{cases}}}

Subtracting the top equation by the bottom equation eliminates the number of rabbits and solves for the number of pheasants.

{

# y
12

{\displaystyle {\begin{cases}x=23\\y=12\end{cases}}}
Runge-Kutta Method with MATLAB

## **Task**

Write a program that plots the exact solution and approximation by the Runge-Kutta method of the equation differential equation

y
′

=
y
cos
⁡
t
,

y
(
0
# )
1

{\displaystyle y' = y\cos t, \quad y(0) = 1 }

over the interval

0
≤
t
≤
6

{\displaystyle 0 \le t \le 6}

 with step size

# h

2

−
3

.

{\displaystyle h = 2^{-3}.}

 The program simultaneously plots the exact solution and computes the error of the approximation at the final time.

## **Hint**

(1) The Runge-Kutta method is

k
1

=
f
(

t
n

,

y
n

)

k
2

=
f
(

t
n

h

/

2
,

y
n

h

k
1

/

2
)

k
3

=
f
(

t
n

h

/

2
,

y
n

h

k
2

/

2
)

k
4

=
f
(

t
n

h
,

y
n

h

k
3

)

y

n
1

=

y
n

h
(

k
1

2

k
2

2

k
3

k
4

)

/

{\displaystyle \begin{align}
k\_1 &= f(t\_n,y\_n) \\[5 pt]
k\_2 &= f(t\_n + h/2,y\_n + hk\_1/2) \\[5 pt]
k\_3 &= f(t\_n + h/2,y\_n + hk\_2/2) \\[5 pt]
k\_4 &= f(t\_n + h,y\_n + hk\_3) \\[5 pt]
y\_{n+1} &= y\_n + h(k\_1 + 2k\_2 + 2k\_3 + k\_4)/6.
\end{align}}

## **Code**

```
% Define the differential equation: y' = f(t,y)
f = @(t,y) y\*cos(t);

% Choose the step size h and create the vector
% of t values from t0 to tf incremented by h
t0 = 0;
tf = 6;
h = 2^-3;
t = t0:h:tf;

% Initialize a vector of y values as a zero vector
% and set the initial value: y(t0) = y0
y = zeros(size(t));
y0 = 1;
y(1) = y0;

% Implement Euler's method to create the vector of t values
for n = 1:(length(t)-1)
 k1 = f(t(n),y(n));
 k2 = f(t(n)+h/2,y(n)+h\*k1/2);
 k3 = f(t(n)+h/2,y(n)+h\*k2/2);
 k4 = f(t(n)+h,y(n)+h\*k3);
 y(n+1) = y(n) + h\*(k1 + 2\*k2 + 2\*k3 + k4)/6;
end

% Plot the approximation with the exact solution
t\_exact = t0:0.02:tf;
y\_exact = exp(sin(t\_exact));
plot(t,y,'b.-',t\_exact,y\_exact)
grid on
ylim([0,3])
savefig('runge\_kutta.fig')

% Compare to exact answer and compute error at tf
error = abs(y\_exact(end) - y(end))

```
Revival of Sangaku 1

**Problem created by Tao Steven Zheng (郑涛)**

## **Problem**

Suppose there is a blue equilateral triangle inside a vermillion square that is circumscribed by a yellow circle. Let the

A

T

,

A

S

,

A

C

{\displaystyle A\_{T},A\_{S},A\_{C}}

 denote the areas of the equilateral triangle, square, and circle respectively. Determine the ratio of the areas

A

T

:

A

S

:

A

C

{\displaystyle A\_{T}:A\_{S}:A\_{C}}

.

## **Solution**

Let

r

{\displaystyle r}

 be the radius of the circle. The diameter of the circle,

2
r

{\displaystyle 2r}

, is also the diagonal of the square. Subsequently, the side of the square measures

2

r

{\displaystyle \sqrt{2} r }

. The side of the equilateral triangle is equal to the side length of the square; thus, its height is

6

2

r

{\displaystyle {\frac {\sqrt {6}}{2}}r}

.

**Area of the circle**

A
C

=
π

r
2

{\displaystyle A\_C = \pi r^2}

**Area of the square**

A

S

=

(

2

r
)

2

=
2

r

2

{\displaystyle A\_{S}={({\sqrt {2}}r)}^{2}=2r^{2}}

**Area of the equilateral triangle**

A

T

=

1
2

⋅

2

r
⋅

6

r

2

=

3

2

r

2

{\displaystyle A\_{T}={\frac {1}{2}}\cdot {\sqrt {2}}r\cdot {\frac {{\sqrt {6}}r}{2}}={\frac {\sqrt {3}}{2}}r^{2}}

Therefore, the desired area ratio is

A

T

:

A

S

:

A

C

=

3

:
4
:
2
π
.

{\displaystyle A\_{T}:A\_{S}:A\_{C}={\sqrt {3}}:4:2\pi .}
PH Scale with Python

**By: Tao Steven Zheng**

## Code

```
value = input("Enter the pH level:")
pH = float(value)
if pH >= 0 and pH < 7:
    print(pH, "is an acid")
if pH > 7 and pH <= 14:
    print(pH, "is a base")
if pH == 7:
    print(pH, "is neutral")
if pH < 0 or pH > 14:
    print("pH scale ranges from 0 to 14")

```

## Results

```
Enter the pH level:2
2.0 is an acid

Enter the pH level:6.9999
6.9999 is an acid

Enter the pH level:7
7.0 is neutral

Enter the pH level:14
14.0 is a base

Enter the pH level:14.00001
pH scale ranges from 0 to 14

Enter the pH level:-2.3
pH scale ranges from 0 to 14
```
Parabolic Mean Value

## **Calculus Concept**

The **mean value theorem** states that for a given planar curve defined by a function

f
(
x
)

{\displaystyle f(x)}

 that is continuous between two endpoints on the interval

[
a
,
b
]

{\displaystyle [a, b]}

, there is at least one point

c

{\displaystyle c}

 (within the interval) at which the tangent line to the curve is parallel to the secant line through its endpoints

(

a
,
f
(
a
)

)

{\displaystyle \left(a, f(a)\right) }

 and

(

b
,
f
(
b
)

)

{\displaystyle \left(b, f(b)\right) }

, that is,

f
′

(
c
# )

f
(
b
)
−
f
(
a
)

b
−
a

{\displaystyle f'(c)=\frac{f(b)-f(a)}{b-a}}

.
## **Problem**

   Consider the parabola

f
(
x
# )
A

x
2

B
x
C

{\displaystyle f(x) = Ax^2 + Bx + C }

.

**Part 1:** Determine the slope of the secant line between two points

# x
a

{\displaystyle x=a}

 and

# x
b

{\displaystyle x = b}

. Express the answer in terms of

A
,
B
,
a
,
b

{\displaystyle A, B, a, b }

.

**Part 2:** Determine the value

x

{\displaystyle x}

 such that the slope of the tangent line of this point on the parabola is equal to the slope of the secant line in **Part 1**.

## **Solution**

**Part 1**

Evaluate the function at

# x
a

{\displaystyle x=a}

and

# x
b

{\displaystyle x = b}

:

f
(
a
# )
A

a
2

B
a
C

{\displaystyle f(a) = Aa^2 + Ba + C }

f
(
b
# )
A

b
2

B
b
C

{\displaystyle f(b) = Ab^2 + Bb + C }

.
Next, calculate the slope of the secant line:

f
(
b
)
−
f
(
a
)

b
−
a

=

A

b
2

B
b
C
−
(
A

a
2

B
a
C
)

b
−
a

=

A
(

b
2

−

a
2

)
B
(
b
−
a
)

b
−
a

=
A
(
b
a
)
B

=
A
(
a
b
)
B

{\displaystyle \begin{align}
\frac{f(b) - f(a)}{b-a} &= \frac{Ab^2 + Bb + C - (Aa^2 + Ba + C)}{b-a} \\
&= \frac{A(b^2 - a^2) + B(b - a)}{b-a} \\
&= A(b + a) + B \\
&= A(a + b) + B
\end{align} }

**Part 2**

The slope of the tangent line of the function

# y
A

x
2

B
x
C

{\displaystyle y = Ax^2 + Bx + C }

 is

# y
2
A
x
B

{\displaystyle y = 2Ax + B }

.
Equating the slope of the tangent to the slope of the secant in **Part 1** gives

2
A
x
# B
A
(
a
b
)
B

{\displaystyle 2Ax + B = A(a+b) + B }

.
Solving for

x

{\displaystyle x}

 yields the average of

a

{\displaystyle a}

 and

b

{\displaystyle b}

:

# x

a
b

2

{\displaystyle x = \frac{a+b}{2} }

.

# x
a

{\displaystyle x=a}

,

# x
b

{\displaystyle x = b}

, and

# x

a
b

2

{\displaystyle x = \frac{a+b}{2} }

 on the parabola forms the inscribed triangle with the largest area. This result was first discovered by Archimedes of Syracuse (c.287 - c.212 BC) using purely geometric reasoning.
Radioactive Decay

## **Problem**

Identify the type or types of radioactive decay for each nuclear equation. Give reason to support your identification.

(1)

28

60

N
i

→

28

60

N
i
γ

{\displaystyle ^{60}\_{28} Ni \rightarrow ^{60}\_{28} Ni + \gamma }

(2)

94

241

P
u

→

95

241

A
m

−
1

0

e

{\displaystyle ^{241}\_{94} Pu \rightarrow ^{241}\_{95} Am + ^{0}\_{-1} e }

(3)

90

230

T
h

→

88

226

R
a

2

4

H
e
γ

{\displaystyle ^{230}\_{90} Th \rightarrow ^{226}\_{88} Ra + ^{4}\_{2} He + \gamma }

(4)

92

238

U

→

90

234

T
h

2

4

H
e

{\displaystyle ^{238}\_{92} U \rightarrow ^{234}\_{90} Th + ^{4}\_{2} He }

(5)

82

210

P
b

→

83

210

B
i

−
1

0

e
γ

{\displaystyle ^{210}\_{82} Pb \rightarrow ^{210}\_{83} Bi + ^{0}\_{-1} e + \gamma }

## **Solution**

(1) Gamma decay. Emission of gamma ray.

(2) Beta decay. Emission of beta particle.

(3) Alpha and gamma decay. Emission of alpha particle and gamma ray.

(4) Alpha decay. Emission of alpha particle.

(5) Beta and gamma decay. Emission of alpha particle and gamma ray.
Variation of Parameters

## **Problem**

Use the **variation of parameters** method to solve the ordinary differential equation

y
″

−

y
′

−
2
# y
4

e

−
t

.

{\displaystyle y'' - y' - 2y = 4{e}^{-t}. }

## **Solution**

To solve for the complementary solution, determine the roots of the characteristic equation

D
2

−
D
−
# 2

{\displaystyle D^2 - D - 2 = 0. }

This characteristic equation can be factored

(
D
−
2
)
(
D
1
# )
0

{\displaystyle (D-2)(D+1) = 0 }

; thus, the roots are

# D
2

{\displaystyle D=2}

 and

# D
−
1

{\displaystyle D=-1}

.

Hence the complementary solution is

y
c

(
t
# )
A

e

2
t

B

e

−
t

{\displaystyle y\_c (t) = A {e}^{2t} + B {e}^{-t} }

. Here,

A
,
B

{\displaystyle A, B}

 are arbitrary constants.

The next step is to calculate the Wronskian determinant.

Let

y
1

=

e

2
t

{\displaystyle y\_1 = {e}^{2t} }

 and

y
2

=

e

−
t

{\displaystyle y\_2 = {e}^{-t} }

. Taking the derivatives of each function yields

y
1

=
2

e

2
t

{\displaystyle y\_1 = 2{e}^{2t} }

 and

y
2

=
−

e

−
t

{\displaystyle y\_2 = -{e}^{-t} }

.

# W

y
1

y
2

y
1
′

y
2
′

{\displaystyle
W =
\begin{vmatrix}
y\_1 & y\_2 \\
y'\_1 & y'\_2
\end{vmatrix}
}

# W

e

2
t

e

−
t

2

e

2
t

−

e

−
t

{\displaystyle
W =
\begin{vmatrix}
{e}^{2t} & {e}^{-t} \\
2{e}^{2t} & -{e}^{-t}
\end{vmatrix}
}

# W
(

e

2
t

)
(
−

e

−
t

)
−
(

e

−
t

)
(
2

e

2
t

# )
−
3

e
t

{\displaystyle W = ({e}^{2t})(-{e}^{-t}) - ({e}^{-t})(2{e}^{2t}) = -3 e^t }

The formula for calculating the particular solution is

y
p

(
t
# )
−

y
1

(

∫

y
2

g
(
t
)

W

d
t

)

y
2

(

∫

y
1

g
(
t
)

W

d
t

)

{\displaystyle y\_p (t) = -y\_1 \left(\int \frac{y\_2 g(t)}{W} dt \right) + y\_2 \left(\int \frac{y\_1 g(t)}{W} dt \right) }

y
p

(
t
)

=
−

e

2
t

(

∫

e

−
t

4

e

−
t

−
3

e
t

d
t

)

e

−
t

(

∫

e

2
t

4

e

−
t

−
3

e
t

d
t

)

=

4
3

e

2
t

(

∫

e

−
3
t

d
t

)

−

4
3

e

−
t

(

∫
1

d
t

)

=

−
4

9

e

−
t

−

4
3

t

e

−
t

{\displaystyle \begin{align}
y\_p (t) &= -{e}^{2t} \left(\int \frac{{e}^{-t} 4{e}^{-t}}{-3 e^t} \,dt \right) + {e}^{-t} \left(\int \frac{{e}^{2t} 4{e}^{-t}}{-3 e^t} \,dt \right) \\[5 pt]
&= \frac{4}{3}{e}^{2t} \left(\int {e}^{-3t} \,dt \right) - \frac{4}{3}{e}^{-t} \left(\int 1\,dt \right) \\[5 pt]
&= \frac{-4}{9} {e}^{-t} - \frac{4}{3} t{e}^{-t}
\end{align} }

There is a new term

−

4
3

t

e

−
t

{\displaystyle - \frac{4}{3} t{e}^{-t} }

appearing! Add this to the complementary solution to get

y
c

(
t
# )
A

e

2
t

B

e

−
t

−

4
3

t

e

−
t

.

{\displaystyle y\_c (t) = A {e}^{2t} + B {e}^{-t} - \frac{4}{3} t{e}^{-t}. }
Reading List for Chinese Mathematics

## **Chinese Books**

[1] 钱宝琮主编.《中国数学史》，北京：科学出版社，1964年。

[2] 纪志刚《孙子算经、张邱建算经、夏侯阳算经导读》， 武汉：湖北教育出版社，1999年。

[3] 郭书春《九章算术译注》，上海：上海古籍出版社，2009年。

[4] 李兆华《中国数学史基础》，天津：天津教育出版社，2010年。

## **English Books**

[1] Martzloff, Jean-Claude. A History of Chinese Mathematics (English Translation). Spinger-Verlag. 1997, 2006.

[2] Yong, Lam Lay, & Ang, Tian Se. *Fleeting Footsteps: Tracing the Conception of Arithmetic and Algebra in Ancient China, Revised Edition*. World Scientific Publishing Company. 2004

[3] Wilkinson, Endymion. *Chinese History: A New Manual, 4th Edition*. Harvard University Press. 2015.

**Chinese books (Simplified Chinese)**

[1] 钱宝琮. 中国数学史. 科学出版社. 1964

[2] 杨世明, 王雪琴. 数学发现的艺术.青岛海洋出版社.1998

[3] 方孝博. 《墨经中的数学和物理学》. 中国社会科学出版社. 1983

[4] 李志军, 胡中华. 两大世界科学高峰. 广西科学技术出版社. 1998

**Chinese books (Traditional Chinese)**

[1] 李繼斌.《九章算術》及其劉徽注研究. 九章出版社.1992

[2] 郭正昭, 陳勝崑, 蔡仁堅. 中國科技文明論集. 牧童出版.1978

**English Books**

[1] Jean-Claude Martzloff. *A History of Chinese Mathematics*. Springer-Verlag. 1997, 2006

[2] Roger Hart. *Imagined Civilizations*. John Hopkins University Press. 2013

[3] Victor J. Katz. *The Mathematics of Egypt, Mesopotamia, China, India, and Islam: A* Sourcebook*. Princeton University Press. 2007*

[4] Victor J. Katz. *A History of Mathematics, 3rd Edition*. Pearson Education, Inc. 2009

[5] Roger Hart. *The Chinese Roots of Linear Algebra*. John Hopkins University Press. 2011

[6] Fukagawa Hidetoshi, Tony Rothman. *Sacred Mathematics*. Princeton University Press. 2008

[7] Caroline Blunden, Mark Elvin. *Cultural Atlas of China*. Equinox (Oxford) Ltd. 1983

[8] Howard Eves. *An* Introduction to the History of Mathematics, 6th Edition*.* Saunders College Publishing. 1992

[9] Dominic Olivastro. *Ancient Puzzles: Classic Brainteasers and Other Timeless Mathematical* Games of The Last 10 Centuries*. Bantam Books. 1993*

**Papers**

[1] Shen Kangshen. *Historical Development of the Chinese remainder Theorem*. 1988

[2] Phillip D. Straffin. *Liu Hui and the First Golden Age of Chinese Mathematics*. 1988

[3] Yuan Ya-xiang. *Jiu Zhang Suan Shu and the Gauss Algorithm for Linear Equations*. 2012

**Websites**

[1] The Story of Mathematics. *Chinese Mathematics*.

http://www.storyofmathematics.com/chinese.html

[2] David E. Joyce. *History of Mathematics:* *Mathematics in China*.

http://aleph0.clarku.edu/~djoyce/mathhist/china.html

[3] MacTutor History of Mathematics Archives. *Index of Chinese Mathematics*.

http://www-history.mcs.st-and.ac.uk/Indexes/Chinese.html

[4] J.J. O’Conner, E.F. Robertson. *Chinese problems*.

http://aleph0.clarku.edu/~djoyce/mathhist/china.html
Uniform Distribution

## **Problem**

Calculate the following attributes for the probability distribution function (PDF)

p
(
x
# )

1

b
−
a

{\displaystyle p(x) = \frac{1}{b-a} }

defined on the interval

x
∈
[
a
,
b
]

{\displaystyle x \in [a, b]}

 and is zero elsewhere.

**Part 1:** Mean

**Part 2:** Median

**Part 3:** Variance

## **Solution**

**Part 1**

The mean is the first moment of the PDF.

# μ

∫

−
∞

∞

x
⋅
p
(
x
)
d
x

{\displaystyle \mu = \int\_{-\infty}^{\infty} x \cdot p(x) dx }

# μ

∫

0

∞

x

b
−
a

d
x

{\displaystyle \mu = \int\_{0}^{\infty} \frac{x}{b-a} dx }

# μ

x
2

2
(
b
−
a
)

a
b

{\displaystyle \mu = \frac{x^2}{2(b-a)}\Biggr|\_a^b }

# μ

b
2

−

a
2

2
(
b
−
a
)

{\displaystyle \mu = \frac{b^2 - a^2}{2(b-a)}}

# μ

a
b

2

{\displaystyle \mu = \frac{a+b}{2} }

**Part 2**

To calculate the median, one must obtain the cumulative distribution function (CDF).

P
(
x
# )

∫

a

x

1

b
−
a

d
t

{\displaystyle P(x) = \int\_{a}^{x} \frac{1}{b-a}dt }

P
(
x
# )

x

b
−
a

a
x

{\displaystyle P(x) = \frac{x}{b-a} \Biggr|\_a^x }

P
(
x
# )

x
−
a

b
−
a

{\displaystyle P(x) = \frac{x-a}{b-a} }

.
The median is located where the probability is 50%, so

P
(
x
# )
0.5

{\displaystyle P(x) = 0.5 }

x
−
a

b
−
a

=
0.5

{\displaystyle \frac{x-a}{b-a} = 0.5 }

# x

a
b

2

{\displaystyle x = \frac{a+b}{2} }

.

**Part 3**

The variance is calculated by subtracting the square of the mean from the second moment.

V
a
r
(
X
# )

∫

−
∞

∞

x
2

⋅
p
(
x
)
d
x
−

μ

2

{\displaystyle Var(X) = \int\_{-\infty}^{\infty} x^2 \cdot p(x) dx - {\mu}^2 }

V
a
r
(
X
# )

∫

a

b

x
2

b
−
a

d
x
−

μ

2

{\displaystyle Var(X) = \int\_{a}^{b} \frac{x^2}{b-a} dx - {\mu}^2 }

V
a
r
(
X
# )

x
3

3
(
b
−
a
)

a
b

−

(

a
b

2

)

2

{\displaystyle Var(X) = \frac{x^3}{3(b-a)} \Biggr|\_a^b - {\left(\frac{a+b}{2}\right)}^2 }

V
a
r
(
X
# )

b
3

−

a
3

3
(
b
−
a
)

−

a
2

2
a
b

b
2

4

{\displaystyle Var(X) = \frac{b^3 - a^3}{3(b-a)} - \frac{a^2+2ab+b^2}{4}}

Since

b
3

−

a
3

=
(
b
−
a
)
(

b
2

a
b

a
2

)

{\displaystyle b^3 - a^3 = (b-a)(b^2 + ab + a^2) }

,

V
a
r
(
X
# )

b
2

a
b

a
2

3

−

a
2

2
a
b

b
2

4

{\displaystyle Var(X) = \frac{b^2 + ab + a^2}{3} - \frac{a^2 + 2ab + b^2}{4}}

V
a
r
(
X
# )

(
b
−
a
)

2

12

{\displaystyle Var(X) = \frac{{(b-a)}^2}{12}}

.
Path Deviation of Light Ray

## **Problem**

A ray of light passing through air is incident on a piece of quartz (n = 1.46) at an angle of 25°, as shown below. The quartz is 1.5 cm thick. Calculate the deviation d of the ray as it emerges back into the air.

## **Solution**

The following diagram illustrates the light ray passing through the piece of quartz and all the relevant angles and lengths. Let

r

{\displaystyle r}

 represent the angle of refraction,

θ

{\displaystyle \theta}

 the difference of the angle of incidence andthe angle of refraction. Let

l

{\displaystyle l}

 represent the length of the path of the refracted light ray in the piece of quartz, and

d

{\displaystyle d}

 be width of the path deviation.

Use Snell's Law to determine the angle of refraction. The index of refraction of air is

n

a
i
r

=
1.0003

{\displaystyle n\_{air} = 1.0003}

 and the index of refraction of quartz is

n

q
u
a
r
t
z

=
1.46

{\displaystyle n\_{quartz} = 1.46}

. The angle of incidence measures 25°, thus

1.0003
sin
⁡

(

25
∘

)

=
1.46
sin
⁡

(
r
)

[
5
p
t
]
r

=

sin

−
1

⁡

(

1.0003
sin
⁡

(

25
∘

)

1.46

)

[
5
p
t
]
r

=

16.8779
∘

{\displaystyle \begin{align}
1.0003 \sin{(25^\circ)} &= 1.46 \sin{(r)} \\ [5 pt]
r &= \sin^{-1} \left(\frac{1.0003 \sin{(25^\circ)}}{1.46}\right) \\ [5 pt]
r &= 16.8779^\circ
\end{align}}

Use the thickness of the quartz to determine the length of the path of the refracted light ray.

l

=

1.5

cos
⁡

(

16.8669
∘

)

[
5
p
t
]
l

=
1.5675

c
m

{\displaystyle \begin{align}
l &= \frac{1.5}{\cos{(16.8669^\circ)}} \\ [5 pt]
l &= 1.5675 \; cm
\end{align}}

To determine the path deviation

d

{\displaystyle d}

, we need the angle

θ

{\displaystyle \theta}

.

# θ

25
∘

−

16.8779
∘

=

8.1221
∘

{\displaystyle \theta = 25^\circ - 16.8779^\circ = 8.1221^\circ}

d

=
l
sin
⁡

θ

[
5
p
t
]

=
1.5675
sin
⁡

(

8.1221
∘

)

=
0.2215

c
m

{\displaystyle \begin{align}
d &= l \sin{\theta} \\ [5 pt]
&= 1.5675 \sin{(8.1221^\circ)} \\[5 pt]
&= 0.2215 \; cm
\end{align}}
How to make refried beans

* 2 tbsp oil
* 2 garlic cloves peeled
* 2 cans pinto beans
* 1 tsp cumin
* 1 tsp chili powder
* Salt
* Lime juice

1. Heat oil in a heavy skillet over medium heat. Don't heat it up too much or it will smoke.
2. First cook the garlic cloves for 4-5 minutes until they're brown on both sides, then smash them. If you cook them too long they'll be black and charred which will make your beans sad.
3. Add the rest of the ingredients except the lime juice and cook until the beans are thoroughly heated.
4. Smash the bean mixture with a potato masher until you get the desired texture, but don't smash them too much that they turn into mush
5. Squeeze lime juice over smashed beans then mix it in.
432 Carnival

A permanent carnival in the 324 Entertainment world, located in Desertville. This place gets its name from the area and perimeter of the equilateral triangle whose area and perimeter are both equal. Unlike most other carnivals, this one has a feature where you can enter your name and age, height, etc. to see if you're eligible to ride or not; if it shows a green up arrow, you are eligible, if it shows a red down arrow, you are not eligible. Some of the rides and attractions are based off Windows screensavers.

The 432 Carnival worker uniform consists of a black shirt with yellow, green, and teal polka dots, blue pants (male) or skirt (female) with a black vertical stripe design, and black shoes with green laces and teal soles. Hat TBD

## Trivia

* An equilateral triangle whose area and perimeter are equal has an area and perimeter both equal to √432. The logo of this carnival contains that equilateral triangle.
* This is a parody of Coral Carnival.
Wave Travelling Through Two Wires

## **Problem**

A steel wire of length 33.0 m and a copper wire of length 24.0 m, both with 1.00-mm diameters, are connected end to end and stretched to a tension of 170 N. The density of steel is 7860 kg/m3, and the density of copper is 8920 kg/m3. How much time would a transverse wave travel the entire length of the two wires?

## **Solution**

The first step is to calculate the linear mass density for the steel and copper wires. Since

# μ
M

/

L

{\displaystyle \mu = M /L }

 (mass over length), we must calculate the mass using the density multiplied by the volume.

# μ

ρ
A
L

L

=
ρ
A

{\displaystyle \mu = \frac{\rho AL}{L} = \rho A}

Here

A

{\displaystyle A}

 is the cross-sectional area, which we assume are circles from the problem.

Thus,

# μ
ρ

(

π
4

d
2

)

{\displaystyle \mu = \rho \left(\frac{\pi}{4}d^2\right) }

while

μ

s
t
e
e
l

=
7860

(

π
4

(
0.001

)
2

)

=
6.173
×

10

−
3

k
g

/

m

{\displaystyle {\mu}\_{steel} = 7860 \left(\frac{\pi}{4}(0.001)^2\right) = 6.173\times{10}^{-3} kg/m }

and

μ

c
o
p
p
e
r

=
8920

(

π
4

(
0.001

)
2

)

=
7.006
×

10

−
3

k
g

/

m

{\displaystyle {\mu}\_{copper} = 8920 \left(\frac{\pi}{4}(0.001)^2\right) = 7.006\times{10}^{-3} kg/m }

.
To calculate the time it would take for the transverse wave to travel the entire length of the two wires, we need to find the travel time of the waves through each wire and add them up.

t

s
t
e
e
l

=

L

s
t
e
e
l

v

s
t
e
e
l

{\displaystyle {t}\_{steel} = \frac{{L}\_{steel}}{{v}\_{steel}} }

t

c
o
p
p
e
r

=

L

c
o
p
p
e
r

v

c
o
p
p
e
r

{\displaystyle {t}\_{copper} = \frac{{L}\_{copper}}{{v}\_{copper}} }

# t

t

s
t
e
e
l

t

c
o
p
p
e
r

{\displaystyle t = {t}\_{steel} + {t}\_{copper} }

Since

# v

T
μ

{\displaystyle v = \sqrt{\frac{T}{\mu}} }

 for waves travelling across a wire, the speed of the wave through the steel wire is

v

s
t
e
e
l

=

170

6.173
×

10

−
3

=
165.95
m

/

s

{\displaystyle {v}\_{steel} = \sqrt{\frac{170}{6.173\times{10}^{-3}}} = 165.95 m/s}

 .
Similarly, the speed of the wave through the copper wire is

v

c
o
p
p
e
r

=

170

7.006
×

10

−
3

=
155.77
m

/

s

{\displaystyle {v}\_{copper} = \sqrt{\frac{170}{7.006\times{10}^{-3}}} = 155.77 m/s}

.
Subsequently,

t

s
t
e
e
l

=

33.0
165.95

=
0.199

{\displaystyle {t}\_{steel} = \frac{33.0}{165.95} = 0.199 }

and

t

c
o
p
p
e
r

=

24.0
155.77

=
0.154

{\displaystyle {t}\_{copper} = \frac{24.0}{155.77} = 0.154 }

.
Therefore the time it would take for the transverse wave to travel across both wires is

# t
0.199
# 0.154
0.353
s

{\displaystyle t = 0.199 + 0.154 = 0.353 s }

.
Solving Linear ODE Systems Using Eigenvectors with MATLAB

## **Task**

Compute eigenvalues and eigenvectors of a matrix using the MATLAB function **eig**. Then use the **eig** fucntion to solve the linear system of ordinary differential equations

d

x
→

d
t

=
A

x
→

{\displaystyle {\frac {d{\vec {x}}}{dt}}=A{\vec {x}}}

where the matrix is

# A

(

1

0

−
1

0

1

−
1

−
1

−
1

0

)

{\displaystyle A={\begin{pmatrix}1&0&-1\\0&1&-1\\-1&-1&0\end{pmatrix}}}

and the initial conditions are

x
→

(
0
# )

(

0

1

−
1

)

{\displaystyle {\vec {x}}(0)={\begin{pmatrix}0\\1\\-1\end{pmatrix}}}

over the interval

0
≤
t
≤
1

{\displaystyle 0\leq t\leq 1}

. Make the time-step equal to 0.1.

## **Code**

```
A = [1 0 -1; 0 1 -1; -1 -1 0];

[V,lambda] = eig(A);
x0 = [0; 1; -1];
c = linsolve(V,x0);
t = 0:0.01:1;

x1 = c(1)\*V(1,1)\*exp(lambda(1,1)\*t) + c(2)\*V(1,2)\*exp(lambda(2,2)\*t) + c(3)\*V(1,3)\*exp(lambda(3,3)\*t);
x2 = c(1)\*V(2,1)\*exp(lambda(1,1)\*t) + c(2)\*V(2,2)\*exp(lambda(2,2)\*t) + c(3)\*V(2,3)\*exp(lambda(3,3)\*t);
x3 = c(1)\*V(3,1)\*exp(lambda(1,1)\*t) + c(2)\*V(3,2)\*exp(lambda(2,2)\*t) + c(3)\*V(3,3)\*exp(lambda(3,3)\*t);

plot(t,x1,t,x2,t,x3)
legend('x\_1(t)','x\_2(t)','x\_3(t)')

```
324 Pizzas

**324 Pizzas** is a pizza chain in the 324 Entertainment world. There are currently 4 locations, and more are expected to open soon.

## Sizes

* 8" (Individual)
* 10" (Small)
* 12" (Medium)
* 14" (Large)
* 16" (Extra Large)

## Crusts (more to be added soon)

* Traditional
* Crispy Thin (10-14" only)
* Pan (12" only)
* Garlic Twist
* Red Pepper Seasoned
* Pretzel
* Stuffed Crust

## Sauces

* Marinara
* Roasted Tomato
* Creamy Garlic
* Buffalo
* BBQ
* Alfredo
* Yellow Cheese Sauce
* Green Pesto
* Purple Pesto

## Base Cheeses

* Mozzarella Cheese
* Pizza Blend (mozzarella and provolone mix, default base cheese)
* Provolone Cheese
* Smoked Cheddar Cheese

## Toppings (can be ordered on 1/4, 1/2, 3/4 or the whole pizza)

### Meat

* Pepperoni
* Mild Sausage
* Spicy Sausage
* Bacon
* Chicken
* Beef
* Ham
* Prosciutto
* Anchovies
* Capicola
* Philly Steak
* Pulled Pork
* Meatballs
* Cajun Shrimp
* Salami
* Smoked Salmon
* Turkey
* Soppressata
* Chorizo
* Burnt Ends
* Bratwurst

### Veggies

* Onions
* Mushrooms
* Green Peppers
* Banana Peppers
* Black Olives
* Tomatoes
* Spinach
* Red Peppers
* Basil
* Green Jalapeños
* Red Jalapeños
* Pineapple
* Garlic
* Green Olives
* Artichokes
* Portobello Mushrooms
* Broccoli
* Carrot Sticks
* Avocado
* Fried Onion Rings
* Yellow Peppers
* Orange Peppers

### Extra Cheeses

* 0.5x, 1.5x or 2x base cheese
* Provolone
* Smoked Cheddar
* Grated Parmesan
* Feta
* Colby Jack
* Asiago
* Pepperjack
* Gouda
* Gorgonzola
* Ricotta Balls

## Cuts

* 4 piece
* 6 piece
* 8 piece
* Square cut (9 or 16 pieces depending on size and crust of pizza)

## Baking Length

* Light
* Regular (most customers order it that way)
* Well Done

## Specialty Pizzas

* Bacon Cheeseburger: Marinara sauce, smoked cheddar base, bacon, beef
* Buffalo Chicken: Buffalo sauce, pizza blend base, chicken, gorgonzola cheese
* Hawaiian: Marinara sauce, provolone base, pineapple, ham
* Level 8 Meltdown: Marinara sauce, pizza blend base, smoked cheddar, parmesan, colby jack, asiago, pepperjack, gouda (8 different cheeses on one pizza!)
* Meat Feast: Marinara sauce, provolone base, pepperoni, sausage, bacon, beef, ham, prosciutto
* Smokehouse: BBQ sauce, smoked cheddar base, pulled pork, bacon, onions
* More coming soon