This commit is contained in:
William Ball 2021-03-29 17:16:35 -07:00
parent 495139741f
commit d740a18fe1

View file

@ -16,7 +16,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 1, "execution_count": 3,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -30,7 +30,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 2, "execution_count": 4,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -42,7 +42,7 @@
"[ 0 0 0 1]" "[ 0 0 0 1]"
] ]
}, },
"execution_count": 2, "execution_count": 4,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -62,7 +62,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 3, "execution_count": 5,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -99,7 +99,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 4, "execution_count": 6,
"metadata": { "metadata": {
"scrolled": true "scrolled": true
}, },
@ -113,7 +113,7 @@
"[-2 -2 -2 -4]" "[-2 -2 -2 -4]"
] ]
}, },
"execution_count": 4, "execution_count": 6,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -140,7 +140,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 5, "execution_count": 7,
"metadata": { "metadata": {
"scrolled": true "scrolled": true
}, },
@ -154,7 +154,7 @@
"[-1/4 -1/4 -1/4 1/8]" "[-1/4 -1/4 -1/4 1/8]"
] ]
}, },
"execution_count": 5, "execution_count": 7,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -165,7 +165,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 6, "execution_count": 8,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -197,7 +197,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 7, "execution_count": 9,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -206,7 +206,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 8, "execution_count": 10,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -218,7 +218,7 @@
"[ 0 0 0 1]" "[ 0 0 0 1]"
] ]
}, },
"execution_count": 8, "execution_count": 10,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -229,7 +229,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 9, "execution_count": 11,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -238,7 +238,7 @@
"b1^2 + b2^2 + b3^2 - b1*b_avg - b2*b_avg - b3*b_avg + 1/4*b_avg^2" "b1^2 + b2^2 + b3^2 - b1*b_avg - b2*b_avg - b3*b_avg + 1/4*b_avg^2"
] ]
}, },
"execution_count": 9, "execution_count": 11,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -269,20 +269,21 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 10, "execution_count": 12,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
"def weyl_generators(matrix, alphas):\n", "def weyl_generators(matrix, alphas):\n",
" retval = []\n", " retval = []\n",
" for alpha in alphas:\n", " for alpha in alphas:\n",
" retval.append(identity_matrix(len(alphas)) - 2 * alpha * alpha.transpose() * matrix)\n", " scale_factor = (alpha.transpose() * matrix * alpha)[0][0]\n",
" retval.append(identity_matrix(len(alphas)) - 2 * alpha * alpha.transpose() * matrix / scale_factor)\n",
" return retval" " return retval"
] ]
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 11, "execution_count": 13,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -292,33 +293,56 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 12, "execution_count": 14,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"[ 2 0 0 -1]\n",
"[ 0 2 0 -1]\n",
"[ 0 0 2 -1]\n",
"[ -1 -1 -1 1/2]"
]
},
"execution_count": 14,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"4 * M.inverse()"
]
},
{
"cell_type": "code",
"execution_count": 15,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
"data": { "data": {
"text/plain": [ "text/plain": [
"[\n", "[\n",
"[-1 0 0 1] [ 1 0 0 0] [ 1 0 0 0] [ 1 0 0 0]\n", "[-1 0 0 1] [ 1 0 0 0] [ 1 0 0 0] [ 1 0 0 0]\n",
"[ 0 1 0 0] [ 0 -1 0 1] [ 0 1 0 0] [ 0 1 0 0]\n", "[ 0 1 0 0] [ 0 -1 0 1] [ 0 1 0 0] [ 0 1 0 0]\n",
"[ 0 0 1 0] [ 0 0 1 0] [ 0 0 -1 1] [ 0 0 1 0]\n", "[ 0 0 1 0] [ 0 0 1 0] [ 0 0 -1 1] [ 0 0 1 0]\n",
"[ 0 0 0 1], [ 0 0 0 1], [ 0 0 0 1], [ 1 1 1 1/2]\n", "[ 0 0 0 1], [ 0 0 0 1], [ 0 0 0 1], [ 4 4 4 -1]\n",
"]" "]"
] ]
}, },
"execution_count": 12, "execution_count": 15,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
], ],
"source": [ "source": [
"S_i = weyl_generators(2 * M.inverse(), standard_basis(4))\n", "S_i = weyl_generators(4 * M.inverse(), standard_basis(4))\n",
"S_i" "S_i"
] ]
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 13, "execution_count": 16,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -337,7 +361,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 14, "execution_count": 17,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -346,7 +370,7 @@
"(7, 2, 4, 6)" "(7, 2, 4, 6)"
] ]
}, },
"execution_count": 14, "execution_count": 17,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -358,7 +382,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 15, "execution_count": 18,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -367,7 +391,7 @@
"(-1, 4, 4, 6)" "(-1, 4, 4, 6)"
] ]
}, },
"execution_count": 15, "execution_count": 18,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -378,7 +402,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 16, "execution_count": 19,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -387,7 +411,7 @@
"(-1, 2, 2, 6)" "(-1, 2, 2, 6)"
] ]
}, },
"execution_count": 16, "execution_count": 19,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -396,36 +420,9 @@
"S3 * root" "S3 * root"
] ]
}, },
{
"cell_type": "markdown",
"metadata": {},
"source": [
"For some reason, I have no idea why, $s_4$ doesn't seem to work. Instead this weird matrix does appear to work."
]
},
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 17, "execution_count": 20,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"(-1, 2, 4, 8)"
]
},
"execution_count": 17,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"S4 * root"
]
},
{
"cell_type": "code",
"execution_count": 18,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -434,18 +431,13 @@
"(-1, 2, 4, 14)" "(-1, 2, 4, 14)"
] ]
}, },
"execution_count": 18, "execution_count": 20,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
], ],
"source": [ "source": [
"matrix([\n", "S4 * root"
" [1, 0, 0, 0],\n",
" [0, 1, 0, 0],\n",
" [0, 0, 1, 0],\n",
" [4, 4, 4, -1]\n",
"]) * root"
] ]
}, },
{ {
@ -459,7 +451,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 19, "execution_count": 21,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -483,7 +475,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 20, "execution_count": 22,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -548,7 +540,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 21, "execution_count": 23,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -565,7 +557,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 22, "execution_count": 24,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -577,7 +569,7 @@
"[ 0 0 0 1 -1/2 1/2 1/2 1/2]" "[ 0 0 0 1 -1/2 1/2 1/2 1/2]"
] ]
}, },
"execution_count": 22, "execution_count": 24,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -594,7 +586,7 @@
" [0, 2, 0, -1],\n", " [0, 2, 0, -1],\n",
"])\n", "])\n",
"\n", "\n",
"Wc.transpose().echelon_form()" "Wc.transpose().rref()"
] ]
}, },
{ {
@ -621,7 +613,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 23, "execution_count": 25,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -635,7 +627,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 24, "execution_count": 26,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -647,7 +639,7 @@
"[-3 -3 -3 1]" "[-3 -3 -3 1]"
] ]
}, },
"execution_count": 24, "execution_count": 26,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -659,30 +651,30 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 25, "execution_count": 27,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
"data": { "data": {
"text/plain": [ "text/plain": [
"[ 5 -3 -3 -3]\n", "[ 2 -6/5 -6/5 -6/5]\n",
"[-3 5 -3 -3]\n", "[-6/5 2 -6/5 -6/5]\n",
"[-3 -3 5 -3]\n", "[-6/5 -6/5 2 -6/5]\n",
"[-3 -3 -3 5]" "[-6/5 -6/5 -6/5 2]"
] ]
}, },
"execution_count": 25, "execution_count": 27,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
], ],
"source": [ "source": [
"32 * m.inverse()" "32 * m.inverse() * 2/5"
] ]
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 26, "execution_count": 28,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -694,7 +686,7 @@
"[bt4 b4 h14 h24]" "[bt4 b4 h14 h24]"
] ]
}, },
"execution_count": 26, "execution_count": 28,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -713,7 +705,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 27, "execution_count": 29,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -722,7 +714,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 28, "execution_count": 30,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -731,7 +723,7 @@
"5*b1^2 - 6*b1*b2 + 5*b2^2 - 6*b1*b3 - 6*b2*b3 + 5*b3^2 - 6*b1*b4 - 6*b2*b4 - 6*b3*b4 + 5*b4^2" "5*b1^2 - 6*b1*b2 + 5*b2^2 - 6*b1*b3 - 6*b2*b3 + 5*b3^2 - 6*b1*b4 - 6*b2*b4 - 6*b3*b4 + 5*b4^2"
] ]
}, },
"execution_count": 28, "execution_count": 30,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -758,7 +750,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 29, "execution_count": 31,
"metadata": { "metadata": {
"scrolled": true "scrolled": true
}, },
@ -767,26 +759,31 @@
"data": { "data": {
"text/plain": [ "text/plain": [
"[\n", "[\n",
"[-1 6 6 6] [ 1 0 0 0] [ 1 0 0 0] [ 1 0 0 0]\n", "[ -1 6/5 6/5 6/5] [ 1 0 0 0] [ 1 0 0 0]\n",
"[ 0 1 0 0] [ 6 -1 6 6] [ 0 1 0 0] [ 0 1 0 0]\n", "[ 0 1 0 0] [6/5 -1 6/5 6/5] [ 0 1 0 0]\n",
"[ 0 0 1 0] [ 0 0 1 0] [ 6 6 -1 6] [ 0 0 1 0]\n", "[ 0 0 1 0] [ 0 0 1 0] [6/5 6/5 -1 6/5]\n",
"[ 0 0 0 1], [ 0 0 0 1], [ 0 0 0 1], [ 6 6 6 -1]\n", "[ 0 0 0 1], [ 0 0 0 1], [ 0 0 0 1],\n",
"\n",
"[ 1 0 0 0]\n",
"[ 0 1 0 0]\n",
"[ 0 0 1 0]\n",
"[6/5 6/5 6/5 -1]\n",
"]" "]"
] ]
}, },
"execution_count": 29, "execution_count": 31,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
], ],
"source": [ "source": [
"S_i = weyl_generators(m, standard_basis(4))\n", "S_i = weyl_generators(m.inverse(), standard_basis(4))\n",
"S_i" "S_i"
] ]
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 30, "execution_count": 32,
"metadata": { "metadata": {
"scrolled": true "scrolled": true
}, },
@ -794,23 +791,23 @@
{ {
"data": { "data": {
"text/plain": [ "text/plain": [
"[ 1 -3 -3 -3 -1 -1 -1 -5]\n", "[ 1 0 0 0 1/2 1/2 1/2 -1/2]\n",
"[-3 1 -3 -3 -1 -1 -5 -1]\n", "[ 0 1 0 0 1/2 1/2 -1/2 1/2]\n",
"[-3 -3 1 -3 -1 -5 -1 -1]\n", "[ 0 0 1 0 1/2 -1/2 1/2 1/2]\n",
"[-3 -3 -3 1 -5 -1 -1 -1]\n", "[ 0 0 0 1 -1/2 1/2 1/2 1/2]\n",
"[-1 -1 -1 -5 1 -3 -3 -3]\n", "[ 0 0 0 0 0 0 0 0]\n",
"[-1 -1 -5 -1 -3 1 -3 -3]\n", "[ 0 0 0 0 0 0 0 0]\n",
"[-1 -5 -1 -1 -3 -3 1 -3]\n", "[ 0 0 0 0 0 0 0 0]\n",
"[-5 -1 -1 -1 -3 -3 -3 1]" "[ 0 0 0 0 0 0 0 0]"
] ]
}, },
"execution_count": 30, "execution_count": 32,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
], ],
"source": [ "source": [
"Wc * P * Wc.transpose()" "(Wc * P * Wc.transpose()).rref()"
] ]
}, },
{ {
@ -823,7 +820,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 31, "execution_count": 33,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -839,7 +836,7 @@
" relation = root_matrix.transpose().rref() * vector([ var('b' + str(i)) for i in range(1, root_matrix.dimensions()[0] + 1)])\n", " relation = root_matrix.transpose().rref() * vector([ var('b' + str(i)) for i in range(1, root_matrix.dimensions()[0] + 1)])\n",
" \n", " \n",
" # step 2: find matrix of quadratic form\n", " # step 2: find matrix of quadratic form\n",
" W = root_matrix[0:4]\n", " W = root_matrix[-4:]\n",
" M = W * P * W.transpose()\n", " M = W * P * W.transpose()\n",
" \n", " \n",
" # step 3: repeat with arbitrary matrix\n", " # step 3: repeat with arbitrary matrix\n",
@ -858,7 +855,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 32, "execution_count": 34,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -877,14 +874,19 @@
"data": { "data": {
"text/plain": [ "text/plain": [
"[\n", "[\n",
"[-9 6 6 6] [ 1 0 0 0] [ 1 0 0 0] [ 1 0 0 0]\n", "[ -1 6/5 6/5 6/5] [ 1 0 0 0] [ 1 0 0 0]\n",
"[ 0 1 0 0] [ 6 -9 6 6] [ 0 1 0 0] [ 0 1 0 0]\n", "[ 0 1 0 0] [6/5 -1 6/5 6/5] [ 0 1 0 0]\n",
"[ 0 0 1 0] [ 0 0 1 0] [ 6 6 -9 6] [ 0 0 1 0]\n", "[ 0 0 1 0] [ 0 0 1 0] [6/5 6/5 -1 6/5]\n",
"[ 0 0 0 1], [ 0 0 0 1], [ 0 0 0 1], [ 6 6 6 -9]\n", "[ 0 0 0 1], [ 0 0 0 1], [ 0 0 0 1],\n",
"\n",
"[ 1 0 0 0]\n",
"[ 0 1 0 0]\n",
"[ 0 0 1 0]\n",
"[6/5 6/5 6/5 -1]\n",
"]" "]"
] ]
}, },
"execution_count": 32, "execution_count": 34,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -900,7 +902,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 33, "execution_count": 35,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -920,13 +922,13 @@
"text/plain": [ "text/plain": [
"[\n", "[\n",
"[-1 4 4 2] [ 1 0 0 0] [ 1 0 0 0] [ 1 0 0 0]\n", "[-1 4 4 2] [ 1 0 0 0] [ 1 0 0 0] [ 1 0 0 0]\n",
"[ 0 1 0 0] [ 4 -7 0 4] [ 0 1 0 0] [ 0 1 0 0]\n", "[ 0 1 0 0] [ 1 -1 0 1] [ 0 1 0 0] [ 0 1 0 0]\n",
"[ 0 0 1 0] [ 0 0 1 0] [ 4 0 -7 4] [ 0 0 1 0]\n", "[ 0 0 1 0] [ 0 0 1 0] [ 1 0 -1 1] [ 0 0 1 0]\n",
"[ 0 0 0 1], [ 0 0 0 1], [ 0 0 0 1], [ 2 4 4 -1]\n", "[ 0 0 0 1], [ 0 0 0 1], [ 0 0 0 1], [ 2 4 4 -1]\n",
"]" "]"
] ]
}, },
"execution_count": 33, "execution_count": 35,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -949,7 +951,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 34, "execution_count": 36,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -975,7 +977,7 @@
"]" "]"
] ]
}, },
"execution_count": 34, "execution_count": 36,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -1019,7 +1021,8 @@
"nbconvert_exporter": "python", "nbconvert_exporter": "python",
"pygments_lexer": "ipython3", "pygments_lexer": "ipython3",
"version": "3.9.2" "version": "3.9.2"
} },
"name": "Apollonian Circle Packings.ipynb"
}, },
"nbformat": 4, "nbformat": 4,
"nbformat_minor": 4 "nbformat_minor": 4