aboutsummaryrefslogtreecommitdiffstats
path: root/notebooks/Untitled.ipynb
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--notebooks/Untitled.ipynb50
1 files changed, 12 insertions, 38 deletions
diff --git a/notebooks/Untitled.ipynb b/notebooks/Untitled.ipynb
index 23109f8..cdc5f74 100644
--- a/notebooks/Untitled.ipynb
+++ b/notebooks/Untitled.ipynb
@@ -38,7 +38,7 @@
{
"data": {
"text/plain": [
- "<map at 0x7f2fe63da820>"
+ "<map at 0x7fb7d4904a60>"
]
},
"execution_count": 3,
@@ -73,7 +73,7 @@
},
{
"cell_type": "code",
- "execution_count": 24,
+ "execution_count": 5,
"id": "2c43411f",
"metadata": {},
"outputs": [
@@ -83,7 +83,7 @@
"'0b1010101'"
]
},
- "execution_count": 24,
+ "execution_count": 5,
"metadata": {},
"output_type": "execute_result"
}
@@ -141,36 +141,11 @@
"id": "cb3fdfcc",
"metadata": {},
"outputs": [],
- "source": [
- "def modulate_16qam(m):\n",
- " sym = {\n",
- " # first column\n",
- " 0: -3 -3j,\n",
- " 1: -3 -1j,\n",
- " 2: -3 +3j,\n",
- " 3: -3 +1j,\n",
- " # second column\n",
- " 4: -1 -3j,\n",
- " 5: -1 -1j,\n",
- " 6: -1 +3j,\n",
- " 7: -1 +1j,\n",
- " # fourth column\n",
- " 8: 3 -3j,\n",
- " 9: 3 -1j,\n",
- " 10: 3 +3j,\n",
- " 11: 3 +1j,\n",
- " # third column\n",
- " 12: 1 -3j,\n",
- " 13: 1 -1j,\n",
- " 14: 1 +3j,\n",
- " 15: 1 +1j,\n",
- " }\n",
- " return map(lambda k: sym[k]*np.sqrt(0.1), m)\n"
- ]
+ "source": []
},
{
"cell_type": "code",
- "execution_count": 25,
+ "execution_count": 9,
"id": "01626f53",
"metadata": {
"scrolled": true
@@ -183,7 +158,7 @@
" (-0.9486832980505138-0.31622776601683794j)]"
]
},
- "execution_count": 25,
+ "execution_count": 9,
"metadata": {},
"output_type": "execute_result"
}
@@ -194,14 +169,13 @@
},
{
"cell_type": "code",
- "execution_count": 17,
+ "execution_count": 10,
"id": "df5b6858",
"metadata": {},
"outputs": [],
"source": [
"def modulate_16qam_2(m):\n",
" sym = {\n",
- " # first column\n",
" 0: 1 -1j,\n",
" 1: -1 -1j,\n",
" 2: 3 -3j,\n",
@@ -225,24 +199,24 @@
},
{
"cell_type": "code",
- "execution_count": 23,
+ "execution_count": 12,
"id": "f263ed95",
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
- "[(-0.31622776601683794-0.31622776601683794j),\n",
- " (-0.31622776601683794-0.31622776601683794j)]"
+ "[(-0.9486832980505138-0.9486832980505138j),\n",
+ " (0.9486832980505138+0.9486832980505138j)]"
]
},
- "execution_count": 23,
+ "execution_count": 12,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
- "list(modulate_16qam_2([1,1]))"
+ "list(modulate_16qam_2([3,9]))"
]
},
{