aboutsummaryrefslogtreecommitdiff
path: root/mindmap
diff options
context:
space:
mode:
authorPreston Pan <preston@nullring.xyz>2023-06-11 17:43:34 -0700
committerPreston Pan <preston@nullring.xyz>2023-06-11 17:43:34 -0700
commit846b48b0b179fcaa49c494d0da0e23db71b989dd (patch)
treead76990055afed803a8de5ed08b89a73e8a32967 /mindmap
first commit
Diffstat (limited to 'mindmap')
-rw-r--r--mindmap/duality.org9
-rw-r--r--mindmap/emergence.org9
-rw-r--r--mindmap/everything.org36
-rw-r--r--mindmap/factorial.org8
-rw-r--r--mindmap/index.org21
-rw-r--r--mindmap/python.org6
-rw-r--r--mindmap/recursion.org71
-rw-r--r--mindmap/self-assembly.org9
-rw-r--r--mindmap/stack.org6
9 files changed, 175 insertions, 0 deletions
diff --git a/mindmap/duality.org b/mindmap/duality.org
new file mode 100644
index 0000000..3836272
--- /dev/null
+++ b/mindmap/duality.org
@@ -0,0 +1,9 @@
+:PROPERTIES:
+:ID: 1b1a8cff-1d20-4689-8466-ea88411007d7
+:END:
+#+title: duality
+#+author: Preston Pan
+#+html_head: <link rel="stylesheet" type="text/css" href="../style.css" />
+#+date: <2023-06-10 Sat>
+* One or Two?
+This is placeholder text.
diff --git a/mindmap/emergence.org b/mindmap/emergence.org
new file mode 100644
index 0000000..9a146cf
--- /dev/null
+++ b/mindmap/emergence.org
@@ -0,0 +1,9 @@
+:PROPERTIES:
+:ID: b005fb71-2a16-40f9-9bb6-29138f4719a2
+:END:
+#+title: emergence
+#+author: Preston Pan
+#+html_head: <link rel="stylesheet" type="text/css" href="style.css" />
+
+* Emergence systems are…
+Many things.
diff --git a/mindmap/everything.org b/mindmap/everything.org
new file mode 100644
index 0000000..8e93fe7
--- /dev/null
+++ b/mindmap/everything.org
@@ -0,0 +1,36 @@
+:PROPERTIES:
+:ID: 2b8515d8-9f3c-44a3-a40d-147f6a2bbb25
+:END:
+#+title: everything
+#+author: Preston Pan
+#+html_head: <link rel="stylesheet" type="text/css" href="../style.css" />
+#+date: <2023-06-10 Sat>
+
+* Everything?
+This article is about everything. No, really, it is.
+Every possible thought you could have is encapsulated
+inside a digital copy of my brain.
+
+You can model everything in terms of [[id:1b1a8cff-1d20-4689-8466-ea88411007d7][duality]] and [[id:8f265f93-e5fd-4150-a845-a60ab7063164][recursion]].
+There are other ways to model everything as well; for example,
+circular structures and self destructing structures. However, these
+other frameworks I posit can be explained well with these other
+general ones, and for the purpose of saving time in explaining
+everything, I'll start with these two things.
+** What is the point in explaining everything?
+So you can be a god! All knowing! Who wouldn't want that?
+** But you have to explain this article in order to explain everything
+No I don't. See? I explained this article!
+** This is not very coherent
+I'd like to see you try.
+** Okay, but seriously…
+Yeah. I get your complaint. It's a hard task to actually explain everything
+and you have to omit details. However, I think this is a pretty reasonable
+attempt at doing so and you will soon notice that the frameworks that I
+am presenting can in fact be used to explain the article itself, albeit
+in a somewhat contradictory way.
+* Something
+I linked them above, but if you want to read about something that is not
+everything, go here:
+- [[id:8f265f93-e5fd-4150-a845-a60ab7063164][recursion]]
+- [[id:1b1a8cff-1d20-4689-8466-ea88411007d7][duality]]
diff --git a/mindmap/factorial.org b/mindmap/factorial.org
new file mode 100644
index 0000000..345fe39
--- /dev/null
+++ b/mindmap/factorial.org
@@ -0,0 +1,8 @@
+:PROPERTIES:
+:ID: aed6b5dc-c2ec-4e8c-b793-538cd5d6e355
+:END:
+#+title: factorial
+#+author: Preston Pan
+#+options: num:nil
+#+html_head: <link rel="stylesheet" type="text/css" href="../style.css" />
+#+options: tex:dvipng
diff --git a/mindmap/index.org b/mindmap/index.org
new file mode 100644
index 0000000..b2d1015
--- /dev/null
+++ b/mindmap/index.org
@@ -0,0 +1,21 @@
+#+title: Mindmap
+#+author: Preston Pan
+#+date: <2023-06-10 Sat>
+#+html_head: <link rel="stylesheet" type="text/css" href="../style.css" />
+
+* Introducing: the Mindmap
+Do you want to know everything like me and be a smart person instead of dumb?
+Well, you've come to the right place! 👍
+
+** What is this?
+It's a place that hopes to explain *EVERYTHING!!*
+** Isn't that unrealistic?
+I answer that in my [[file:everything.org][mindmap]]! It has all the answers!
+** Doesn't it have to explain itself?
+Yeah, we answered that one too. Just read the [[file:everything.org][mindmap]].
+** Batteries included?
+No, it's a mindmap you fucking idiot.
+* Rules
+- Don't use the back button on your browser
+- Everything here is going to be a link to another mindmap page.
+- Therefore, if there is a page you want to go back to, you must navigate until you find a loop back to the original page.
diff --git a/mindmap/python.org b/mindmap/python.org
new file mode 100644
index 0000000..6234beb
--- /dev/null
+++ b/mindmap/python.org
@@ -0,0 +1,6 @@
+:PROPERTIES:
+:ID: 5d2e2f3b-96ac-4196-9baf-4c3d6d349c98
+:END:
+#+title: python
+#+author: Preston Pan
+#+html_head: <link rel="stylesheet" type="text/css" href="../style.css" />
diff --git a/mindmap/recursion.org b/mindmap/recursion.org
new file mode 100644
index 0000000..bf42261
--- /dev/null
+++ b/mindmap/recursion.org
@@ -0,0 +1,71 @@
+:PROPERTIES:
+:ID: 8f265f93-e5fd-4150-a845-a60ab7063164
+:END:
+#+title: recursion
+#+author: Preston Pan
+#+html_head: <link rel="stylesheet" type="text/css" href="../style.css" />
+#+html_head: <script src="https://polyfill.io/v3/polyfill.min.js?features=es6"></script>
+#+html_head: <script id="MathJax-script" async src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
+#+startup: latexpreview
+#+OPTIONS: broken-links:t
+* Recursion is Recursion
+Exactly as I say in the title.
+** but what is recursion?
+Recursion.
+** No, seriously, what is it?
+Self reference.
+** haha, very clever, it's not like that joke has been made 10 million times
+Yeah, but I think it's a good introduction to the subject. You can think of recursion
+as [[id:42dbae12-827c-43c4-8dfc-a2cb1e835efa][self-assembly]] and it has deep connections to topics such as [[id:b005fb71-2a16-40f9-9bb6-29138f4719a2][emergence]]. I will first
+describe it in a mathematics context, and then a programming context.
+For demonstration purposes, I will use [[id:5d2e2f3b-96ac-4196-9baf-4c3d6d349c98][python]].
+* Mathematics Describes Recursion
+For this example, I will be using the factorial. One might define it like so:
+\begin{align*}
+f: \mathbb{N}\rightarrow\mathbb{N}\ s.t. \\
+f(0) = 1 \\
+f(n) = nf(n - 1) \\
+\end{align*}
+
+* Programming Describes Recursion
+#+begin_src python :exports both
+def factorial(x):
+ if x <= 0:
+ return 1
+ return x * factorial(x - 1)
+return factorial(5)
+#+end_src
+
+#+RESULTS:
+: 120
+** The stack frame
+We are now going to modify the code to be more transparent in the sense that it is going to print
+each factorial call out:
+#+begin_src python :results output :exports both
+def factorial(x):
+ if x <= 0:
+ print(1)
+ return 1
+ n = x * factorial(x - 1)
+ print(n)
+ return n
+factorial(5)
+#+end_src
+
+#+RESULTS:
+: 1
+: 1
+: 2
+: 6
+: 24
+: 120
+
+what is happening here? Why is it printing in the reverse order? Well, it is because we are calling
+the factorial function from within itself /before/ we print out the return value, which then
+keeps on happening for each iteration until it reaches the "base case" (the case in which x <= 0).
+
+You can model this behavior with a [[id:52d255d2-114c-42f4-b362-f0b4a2f7b83d][stack]], which is why it is called a stack frame. Think about each
+iteration as getting put on the top of the stack waiting to be printed, until the base case is evaluated
+and printed all in one step.
+* Recursion is not Recursion
+* Recursion is [[id:1b1a8cff-1d20-4689-8466-ea88411007d7][duality]]?
diff --git a/mindmap/self-assembly.org b/mindmap/self-assembly.org
new file mode 100644
index 0000000..a9ef3a1
--- /dev/null
+++ b/mindmap/self-assembly.org
@@ -0,0 +1,9 @@
+:PROPERTIES:
+:ID: 42dbae12-827c-43c4-8dfc-a2cb1e835efa
+:END:
+#+title: self-assembly
+#+author: Preston Pan
+#+html_head: <link rel="stylesheet" type="text/css" href="../style.css" />
+
+* Introduction
+bla bla bla.
diff --git a/mindmap/stack.org b/mindmap/stack.org
new file mode 100644
index 0000000..74d0138
--- /dev/null
+++ b/mindmap/stack.org
@@ -0,0 +1,6 @@
+:PROPERTIES:
+:ID: 52d255d2-114c-42f4-b362-f0b4a2f7b83d
+:END:
+#+title: stack
+#+author: Preston Pan
+#+html_head: <link rel="stylesheet" type="text/css" href="../style.css" />