From 86cb36d80e1be9a1802d2426bd9ce11e6e2673fd Mon Sep 17 00:00:00 2001
From: Erik Strand <erik.strand@cba.mit.edu>
Date: Wed, 20 Feb 2019 14:28:12 -0500
Subject: [PATCH] Don't use default posts structure

---
 _config.yml                                       | 12 +++++++-----
 _data/navigation.yml                              |  2 ++
 _layouts/{post.html => note.html}                 |  4 ----
 _layouts/pset.html                                |  6 ++++++
 .../fourier_transform.md                          |  7 +++----
 _posts/2019-02-14-pset1.md => _psets/1.md         |  0
 _posts/2019-02-14-pset2.md => _psets/2.md         | 15 ++++++++-------
 notes.html                                        | 12 ++++++++++++
 psets.html                                        |  5 ++---
 9 files changed, 40 insertions(+), 23 deletions(-)
 rename _layouts/{post.html => note.html} (59%)
 create mode 100644 _layouts/pset.html
 rename _posts/2019-02-15-ch2-notes.md => _notes/fourier_transform.md (97%)
 rename _posts/2019-02-14-pset1.md => _psets/1.md (100%)
 rename _posts/2019-02-14-pset2.md => _psets/2.md (94%)
 create mode 100644 notes.html

diff --git a/_config.yml b/_config.yml
index 203825c..e378081 100644
--- a/_config.yml
+++ b/_config.yml
@@ -1,18 +1,20 @@
 collections:
-  authors:
+  psets:
+    output: true
+  notes:
     output: true
 
 defaults:
   - scope:
       path: ""
-      type: "authors"
+      type: "psets"
     values:
-      layout: "author"
+      layout: "pset"
   - scope:
       path: ""
-      type: "posts"
+      type: "notes"
     values:
-      layout: "post"
+      layout: "note"
   - scope:
       path: ""
     values:
diff --git a/_data/navigation.yml b/_data/navigation.yml
index cb67c7c..268b387 100644
--- a/_data/navigation.yml
+++ b/_data/navigation.yml
@@ -2,3 +2,5 @@
   link: /
 - name: Problem Sets
   link: /psets.html
+- name: Notes
+  link: /notes.html
diff --git a/_layouts/post.html b/_layouts/note.html
similarity index 59%
rename from _layouts/post.html
rename to _layouts/note.html
index 0fab084..b07fd4a 100644
--- a/_layouts/post.html
+++ b/_layouts/note.html
@@ -3,8 +3,4 @@ layout: default
 ---
 <h1>{{ page.title }}</h1>
 
-<p>
-  {{ page.date | date_to_string }}
-</p>
-
 {{ content }}
diff --git a/_layouts/pset.html b/_layouts/pset.html
new file mode 100644
index 0000000..b07fd4a
--- /dev/null
+++ b/_layouts/pset.html
@@ -0,0 +1,6 @@
+---
+layout: default
+---
+<h1>{{ page.title }}</h1>
+
+{{ content }}
diff --git a/_posts/2019-02-15-ch2-notes.md b/_notes/fourier_transform.md
similarity index 97%
rename from _posts/2019-02-15-ch2-notes.md
rename to _notes/fourier_transform.md
index 0015a63..693676e 100644
--- a/_posts/2019-02-15-ch2-notes.md
+++ b/_notes/fourier_transform.md
@@ -1,10 +1,9 @@
 ---
-title: Chapter 2 Notes
+title: Fourier Transforms
 ---
 
-This page contains some proofs that I needed to review to make sense of the material in chapter 2.
-
-It's based on my prior knowledge and some helpful websites:
+To really make sense of chapter 2 I needed to review the properties of Fourier Transforms. These
+notes are based on my prior knowledge and some helpful websites:
 
 - [Properties of Fourier Transform](http://fourier.eng.hmc.edu/e101/lectures/handout3/node2.html)
 - [symmetry.pdf](https://www.cs.unm.edu/~williams/cs530/symmetry.pdf)
diff --git a/_posts/2019-02-14-pset1.md b/_psets/1.md
similarity index 100%
rename from _posts/2019-02-14-pset1.md
rename to _psets/1.md
diff --git a/_posts/2019-02-14-pset2.md b/_psets/2.md
similarity index 94%
rename from _posts/2019-02-14-pset2.md
rename to _psets/2.md
index 94c286d..26710fb 100644
--- a/_posts/2019-02-14-pset2.md
+++ b/_psets/2.md
@@ -95,13 +95,14 @@ visible light?
 Note: in the previous problem I used $$\lambda$$ as the expected number of events of a Poisson process.
 Here I'll use $$N$$ to avoid confusion with wavelength.
 
-We have already found that $$\sigma = \sqrt{N}$$. For large $$N$$, the Poisson
-distribution is very close to the normal distribution. So about two thirds of the probability mass
-lies between $$N - \sigma$$ and $$N + \sigma$$. Thus if $$\sigma \leq 0.01 N$$, in
-any given second it's more likely than not that the number of photons emitted is within one percent
-of the true mean. Thus we'd need $$\sqrt{N} \leq 0.01 N$$, i.e. $$N \geq 10^4$$.
-To have the same probability that the number of observed photons is within $$10^{-6} N$$ of
-the true value, we need $$N \geq 10^{12}$$.
+Since the photons are generated independently and with a constant average rate, it's reasonable to
+model their creation as a Poisson process. We have already found that $$\sigma = \sqrt{N}$$. For
+large $$N$$, the Poisson distribution is very close to the normal distribution. So about two thirds
+of the probability mass lies between $$N - \sigma$$ and $$N + \sigma$$. Thus if $$\sigma \leq 0.01
+N$$, in any given second it's more likely than not that the number of photons emitted is within one
+percent of the true mean. Thus we'd need $$\sqrt{N} \leq 0.01 N$$, i.e. $$N \geq 10^4$$. To have the
+same probability that the number of observed photons is within $$10^{-6} N$$ of the true value, we
+need $$N \geq 10^{12}$$.
 
 The wavelength of visible light is about $$\num{500e-9} \si{m}$$, so the energy of each photon will
 be
diff --git a/notes.html b/notes.html
new file mode 100644
index 0000000..ff57d2e
--- /dev/null
+++ b/notes.html
@@ -0,0 +1,12 @@
+---
+title: Notes
+---
+<h1>Notes</h1>
+
+<ul>
+  {% for note in site.notes %}
+    <li>
+      <h2><a href="{{ note.url | real_relative_url }}">{{ note.title }}</a></h2>
+    </li>
+  {% endfor %}
+</ul>
diff --git a/psets.html b/psets.html
index 15284ea..1efc5d6 100644
--- a/psets.html
+++ b/psets.html
@@ -4,10 +4,9 @@ title: Problem Sets
 <h1>Problem Sets</h1>
 
 <ul>
-  {% for post in site.posts %}
+  {% for pset in site.psets %}
     <li>
-      <h2><a href="{{ post.url | real_relative_url }}">{{ post.title }}</a></h2>
-      <p>{{ post.excerpt }}</p>
+      <h2><a href="{{ pset.url | real_relative_url }}">{{ pset.title }}</a></h2>
     </li>
   {% endfor %}
 </ul>
-- 
GitLab