<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" ><generator uri="https://jekyllrb.com/" version="3.10.0">Jekyll</generator><link href="https://paulhe.com/feed.xml" rel="self" type="application/atom+xml" /><link href="https://paulhe.com/" rel="alternate" type="text/html" /><updated>2026-07-13T16:27:15-04:00</updated><id>https://paulhe.com/feed.xml</id><title type="html">Paul He</title><author><name>Paul He</name></author><entry><title type="html">The French Quarter</title><link href="https://paulhe.com/2025/05/16/french-quarter.html" rel="alternate" type="text/html" title="The French Quarter" /><published>2025-05-16T00:00:00-04:00</published><updated>2025-05-21T00:00:00-04:00</updated><id>https://paulhe.com/2025/05/16/french-quarter</id><content type="html" xml:base="https://paulhe.com/2025/05/16/french-quarter.html"><![CDATA[<p>Philadelphia is the best city in America.
And as everyone always says, Philly is a city of neighbourhoods.
But what nobody says is that one of these neighbourhoods is the French Quarter.
And no, I’m not talking about New Orleans, Philadelphia has its very own <a href="https://en.wikipedia.org/w/index.php?title=French_Quarter,_Philadelphia&amp;oldid=1277031229">French Quarter</a>.</p>

<p><img src="/assets/gmaps.png" alt="Google Maps screenshot of the French Quarter boundaries" /></p>

<p>Note: This post was supposed to be completed a few years ago, but delays resulted in me getting <a href="https://billypenn.com/2023/05/24/philadelphia-french-quarter-rittenhouse-history/">scooped</a>.
Unlike Billy Penn, I don’t have a Twitter account, so I can’t include any fun Twitter screenshots, but I do think I have a few new things to add, thanks to some on-the-ground reporting and digging through the archives.</p>

<h2 id="walking-the-french-quarter">Walking the French Quarter</h2>

<p>Walking through the neighbourhood you’ll see street signs on some of the corners of the neighbourhood boundaries: Walnut, Sansom, 17th, and 18th (not 19th!).</p>

<p><img src="/assets/17sansom.jpg" alt="Photo of the street sign at 17th and Sansom" /> <img src="/assets/18sansom.jpg" alt="Photo of the street sign at 18th and Sansom" /> <img src="/assets/18walnut.jpg" alt="Photo of the street sign at 18th and Walnut" /></p>

<p>Interestingly, the signs at 17th and Walnut are missing. Maybe it should be called the French Three-Quarters.</p>

<p><img src="/assets/17walnut.jpg" alt="Photo of the street sign at 17th and Walnut" /></p>

<p>There are no signs on 19th Street.
In fact, most of the sources online that say the Quarter goes between 17th and 19th are wrong, like Google Maps and Wikipedia, along with many sources that use it, including the Billy Penn article.
A newspaper article from the day before the French Quarter name was made official in 1999 lists the correct boundaries: “Sansom and Walnut Streets between 17th and 18th”. <sup id="fnref:bastille" role="doc-noteref"><a href="#fn:bastille" class="footnote" rel="footnote">1</a></sup></p>

<p><img src="/assets/19sansom.jpg" alt="Photo of the street sign at 19th and Sansom" /> <img src="/assets/19walnut.jpg" alt="Photo of the street sign at 19th and Walnut" /></p>

<p>Another thing you might notice walking through the neighbourhood is that it’s not especially French.
There is the Sofitel, which is on the north side of Sansom and thus outside the boundaries of the Quarter.
Parc, the popular French restaurant, is a little further down the street at 18th and Locust, definitely outside the rectangle.
As is La Colombe, at 19th and Walnut, and the nearby Alliance Francaise de Philadelphie, at 15th and Walnut.</p>

<p>So what is French in the boundaries of the French Quarter?
The Fleur d’Or Nail Bar, which has a decidedly French name.
There is also Anthropologie, which sounds French enough (it’s not).
Today, there are far fewer French connections (none?) compared to the first years of the French Quarter.</p>

<h2 id="history">History</h2>

<p>The neighbourhood was given its name on July 14, 1999—Bastille Day <sup id="fnref:bastille:1" role="doc-noteref"><a href="#fn:bastille" class="footnote" rel="footnote">1</a></sup>.
I tried to track down some of the official city documentation by going to the city archives, but was told that:</p>
<ol>
  <li>They have never heard of the French Quarter before.</li>
  <li>Ed Rendell—who was mayor 1992-2000—is still too recent for his records to be public, so the records are sealed. So we won’t know for many more years who paid for this designation (I suspect a baguette-toting hotel chain—see below).</li>
</ol>

<p>What we do know is that Mayor Rendell said “There are so many cultural, educational and social connections between Rittenhouse Row and France that it is most appropriate to have an area identified as the French Quarter.” <sup id="fnref:sofitel" role="doc-noteref"><a href="#fn:sofitel" class="footnote" rel="footnote">2</a></sup></p>

<p>It seems the one who made these connections was Dan Rottenberg in the previous year.
On his website he lists his major and minor achievements, and a minor one is “First to identify Center City Philadelphia neighborhood of 17th-18th-Walnut-Sansom as ‘The French Quarter,’ later officially designated as such on street signs (Philadelphia Magazine, July 1998).” <sup id="fnref:rottenberg" role="doc-noteref"><a href="#fn:rottenberg" class="footnote" rel="footnote">3</a></sup>
At least he got the neighbourhood boundaries right.
I found this issue of Phillymag at the library and include some interesting passages here:</p>

<blockquote>
  <p>And unlike most immigration waves, this French invasion has no apparent downside. Not every Frenchman arrives carrying what instantly becomes America’s greatest art collection, as Napoleon’s brother, Joseph Bonaparte, did when he settled on 9th Street after the Battle of Waterloo. But where other immigrants come here trailing the wretched refuse of their teeming shores, the French tend to tote with them assets, connections, impeccable taste and unlimited quantities of joie de vivre, not to mention a strange and seemingly instinctive talent for creating croissants and soufflés to die for.</p>
</blockquote>

<p>Phillymag lives up to the stereotypes.</p>

<blockquote>
  <p>Thanks in part to this influx, Center City’s Walnut Street/Rittenhouse Square vicinity, which was plagued with vacant storefronts 10 years ago, has lately evolved into an incipient “French Quarter” where every chic Gallic establishment that goes under (Auray, Suzanne Gross Gallery, Descamps, Louis Vuitton, Mephisto) seems immediately to be replaced by an even tonier French business (Rodier, Monique Messin, Mademoiselle de Paris, Vog, La Colombe, Brasserie Perrier) to join the old standbys (Le Bec-Fin, Jacques Ferber Furs and Madeleine Ulitsky’s Happy Rooster).</p>
</blockquote>

<p>It seems that there were more French businesses in 1998.
Of them, only La Colombe survives to this day.</p>

<h2 id="wikipedia">Wikipedia</h2>

<p>The <a href="https://en.wikipedia.org/w/index.php?title=French_Quarter,_Philadelphia&amp;oldid=1277031229">Wikipedia article</a> provides a little information about the neighbourhood, and cites an <a href="https://web.archive.org/web/20201018154540/https://mycitypaper.com/articles/101499/feat.slant.shtml">article from the Philadelphia City Paper</a><sup id="fnref:quarter" role="doc-noteref"><a href="#fn:quarter" class="footnote" rel="footnote">4</a></sup> describing the French Quarter.
The <a href="https://en.wikipedia.org/w/index.php?title=Talk:French_Quarter,_Philadelphia&amp;oldid=1207304605">talk page</a> has some discussions of confused Wikipedians, all of whom suspect the City Paper article to be fake or an ad.</p>

<p>The article, which I won’t quote as you really should read it yourself, was published in the paper’s “Slant” section.
This section was created in 1998 by the newspaper, and was <a href="https://web.archive.org/web/20211214184226/https://mycitypaper.com/articles/102998/slant.shtml">described</a> as a space for editorials, written both by the staff and by readers<sup id="fnref:slant" role="doc-noteref"><a href="#fn:slant" class="footnote" rel="footnote">5</a></sup>.
With this context, it becomes more clear that the article by Tom Javian is dripping with sarcasm, and is a work of satire.
Unfortunately, this means the neighbourhood was never blessed with the opening of Say Fromage! and Ooh La Yogurt.</p>

<p>The Philadelphia City Paper shut down in 2015, and its archives lived on—for a while—on the website of “My City Paper”, which seemed to be a small online news site that focused on New York City.
The now-defunct paper seemed to mostly repost fluff articles and pictures, but amusingly did post a <a href="https://www.reddit.com/r/rust/comments/7era78/is_it_me_or_does_the_rust_on_this_nyc_bridge_look/">picture</a> on the Rust subreddit.</p>

<h2 id="sofitel">Sofitel</h2>

<p>Prior to the hotel opening in 2000, the general manager of Sofitel at the time said:</p>

<blockquote>
  <p>It is an upscale, luxurious French hotel with a lot of French touches that most hotels don’t have.
For example, all of our guests receive fresh turn downs every night, but we deliver a fresh rose for the bathroom and a bottle of Evian and a weather card telling what the weather will be for the next morning.
We have wash mitts instead of washcloths and guests receive a fresh baguette at check out.
So really you’re going to get European French service in the hotel. <sup id="fnref:sofitel:1" role="doc-noteref"><a href="#fn:sofitel" class="footnote" rel="footnote">2</a></sup></p>
</blockquote>

<p>Unfortunately my blog income did not allow me to stay at the Sofitel, and my dignity did not allow me to ask them about the baguettes.
I couldn’t find any reviews raving about baguettes at check out, so I assume they no longer do this—if they ever did.
I can only imagine they chose to give out the baguettes at check out instead of check in to avoid cleaning up crumbs in the rooms.</p>

<p>My budget <em>did</em> allow for a visit to the Liberté Urban Chic Lounge in the hotel.
For this trip in April 2023 I was accompanied by renowned researcher and Francophile <a href="https://orcid.org/0000-0003-3748-6692">Anne-Marie Zaccarin</a>.
With her expertise, we were able to make the following observations:</p>
<ol>
  <li>Accents were often wrong on the menu, for example they were missing on liberté and brûlé.</li>
  <li>The “French people” at the hotel did not know French.</li>
  <li>The “French people” at the hotel had Hydroflasks, the least French water bottle.</li>
  <li>The décor featured a prominent American flag.</li>
</ol>

<p>We concluded that the lounge was not very French at all.
Perhaps that went away at the same time as the baguettes.</p>

<p>One of the newspaper articles I consulted actually stated that the area “… will be christened Philly’s French Quarter by Mayor Rendell in honor of the Hotel Sofitel, under construction at 17th and Sansom.” <sup id="fnref:bastille:2" role="doc-noteref"><a href="#fn:bastille" class="footnote" rel="footnote">1</a></sup>
This—along with the date and location of the designation—leads me to believe that Sofitel paid for the French Quarter name.</p>

<h2 id="references">References</h2>

<div class="footnotes" role="doc-endnotes">
  <ol>
    <li id="fn:bastille" role="doc-endnote">
      <p>Lessy, Harriet. “Bastille Day on Sansom, Philly’s ‘French Quarter’”. <em>Philadelphia Daily News</em>, 13 July 1999, p. 24. <a href="#fnref:bastille" class="reversefootnote" role="doc-backlink">&#8617;</a> <a href="#fnref:bastille:1" class="reversefootnote" role="doc-backlink">&#8617;<sup>2</sup></a> <a href="#fnref:bastille:2" class="reversefootnote" role="doc-backlink">&#8617;<sup>3</sup></a></p>
    </li>
    <li id="fn:sofitel" role="doc-endnote">
      <p>Crews, Christina. “Hotel will bring French flair to city: Sofitel Philadelphia to open in old Stock Exchange Building”. <em>Philadelphia Tribune</em>, 20 Jul 1999, p. 1D <a href="#fnref:sofitel" class="reversefootnote" role="doc-backlink">&#8617;</a> <a href="#fnref:sofitel:1" class="reversefootnote" role="doc-backlink">&#8617;<sup>2</sup></a></p>
    </li>
    <li id="fn:rottenberg" role="doc-endnote">
      <p><a href="https://danrottenberg.com/wp/major-and-minor-achievements/">https://danrottenberg.com/wp/major-and-minor-achievements/</a> <a href="#fnref:rottenberg" class="reversefootnote" role="doc-backlink">&#8617;</a></p>
    </li>
    <li id="fn:quarter" role="doc-endnote">
      <p>Javian, Tom. “Buddy, Can You Spare a Quarter?”. <em>Philadelphia City Paper</em>, 14 October 1999. <a href="#fnref:quarter" class="reversefootnote" role="doc-backlink">&#8617;</a></p>
    </li>
    <li id="fn:slant" role="doc-endnote">
      <p>Warner, David. “It’s Different”. <em>Philadelphia City Paper</em>, 29 October 1998. <a href="#fnref:slant" class="reversefootnote" role="doc-backlink">&#8617;</a></p>
    </li>
  </ol>
</div>]]></content><author><name>Paul He</name></author><summary type="html"><![CDATA[Philadelphia is the best city in America. And as everyone always says, Philly is a city of neighbourhoods. But what nobody says is that one of these neighbourhoods is the French Quarter. And no, I’m not talking about New Orleans, Philadelphia has its very own French Quarter.]]></summary></entry><entry><title type="html">Dissertatiometer</title><link href="https://paulhe.com/2024/07/30/dissertatiometer.html" rel="alternate" type="text/html" title="Dissertatiometer" /><published>2024-07-30T00:00:00-04:00</published><updated>2024-07-30T00:00:00-04:00</updated><id>https://paulhe.com/2024/07/30/dissertatiometer</id><content type="html" xml:base="https://paulhe.com/2024/07/30/dissertatiometer.html"><![CDATA[<p>For my dissertation, I kept track of my progress on this page, which is now archived as a blog post.
I counted the number of words in my Latex source using <code class="language-plaintext highlighter-rouge">texcount</code>.
I started counting on February 9, 2023, starting from the contents of my thesis proposal.
Data points were only added on days with changes.</p>

<p>I didn’t do much writing for a long time during my job search, and started again in earnest on March 4, 2024 (day 389).
The graph starting from then is below.</p>

<p>I finished the first version for my committee on June 5, 2024 (day 482), and defended on June 25, 2024 (day 502).
I finished revisions on July 30, 2024 (day 537).</p>

<h2 id="plots">Plots</h2>

<p><img src="/assets/dissertatiometer.png" alt="Zoomed in plot of word count for dissertation" /></p>

<p>The older and uglier plot is here, showing data points from day 0:
<img src="/assets/dissertatiometer_old.png" alt="Zoomed out plot of word count" /></p>

<p>Me during these months of writing:
<img src="/assets/thesis.webp" alt="meme" /></p>]]></content><author><name>Paul He</name></author><summary type="html"><![CDATA[For my dissertation, I kept track of my progress on this page, which is now archived as a blog post. I counted the number of words in my Latex source using texcount. I started counting on February 9, 2023, starting from the contents of my thesis proposal. Data points were only added on days with changes.]]></summary></entry><entry><title type="html">Mathematics or Science?</title><link href="https://paulhe.com/2022/12/28/mathematics-or-science.html" rel="alternate" type="text/html" title="Mathematics or Science?" /><published>2022-12-28T00:00:00-05:00</published><updated>2022-12-28T00:00:00-05:00</updated><id>https://paulhe.com/2022/12/28/mathematics-or-science</id><content type="html" xml:base="https://paulhe.com/2022/12/28/mathematics-or-science.html"><![CDATA[<p>As part of the program chair’s report for POPL 1992, Andrew Appel wrote a paper titled <a href="https://www.cs.princeton.edu/~appel/papers/science.pdf">“Is POPL Mathematics or Science?”</a>
His paper measured how theoretical a conference is using the author ordering of the papers published.
While this paper was meant to “provide some laughs”, I thought it was very interesting and reproduced the results for both the same data and for present-day programming languages conferences.</p>

<p>Most scientific fields usually order by the amount of work each author contributed, sometimes with other conventions, like students being listed first or the grant holder being listed last.
Mathematical fields, however, typically order authors alphabetically, since small ideas are often instrumental in a paper, and it can be difficult to rank the importance of each author’s contributions.
Computer science can go in either direction, depending on the subfield and the paper.
Using the author ordering, we can measure how applied (science) vs. theoretical (math) a conference is.</p>

<h2 id="reproducing-the-1992-results">Reproducing the 1992 Results</h2>

<p>Following Appel’s approach, I recreated the algorithm to compute the most likely proportion of mathematicians to scientists in each conference, with associated error bars.
The code can be found at <a href="https://github.com/Grain/appel">this Git repo</a>.
The data for these conferences was collected from DBLP (copy and pasted, then cleaned up using emacs macros).</p>

<p>The original plot:
<img src="/assets/1992paper.png" alt="Plot of results from the paper" /></p>

<p>My plot, with sloppy manually-added lines:
<img src="/assets/1992mine.png" alt="Plot of results I generated" /></p>

<p>If you look closely at the data, you may notice that many of my results differ from Appel’s original paper.
I had a hard time figuring out the reasons for this.
One possible reason is that sometimes surnames are difficult to discern.
My code uses the <a href="https://github.com/datamade/probablepeople">probablepeople</a> library to guess the surname portion of the name, and sometimes I have to decide when the library can’t figure it out, for example by manually removing whitespace or adding hyphenation in a name.
However, I tried different hyphenation and whitespace combinations for the POPL authors, with no success in reproducing the original paper’s results.
Note that this may still be a factor for other conferences, which I didn’t look at in detail.</p>

<p>My second hypothesis was that the DBLP data differed from the actual author lists that Appel used in 1992.
To test this, I needed a paper copy of the proceedings, since the digital copies on the ACM digital library did not include front matter, and only the individual papers.
I could have looked at each paper individually for the author lists, but I deemed that to be too much work.
Instead, I found a copy of one of the POPL proceedings in the Penn library, and requested for the table of contents to be scanned and sent to me.
A few days later I confirmed that this was the source of the discrepency, at least for that specific data point.
Some of the authors switched to publishing under a different surname, and DBLP displayed their most current name, even for older papers.</p>

<p>To make my work easier, I didn’t do anything to solve these two issues, so my results will differ from Appel’s original results.
For the first, I didn’t do any special handling of surnames, taking the name that probablepeople returned, and only intervening if it could not determine a unique surname.
For the second, I just used the DBLP data as-is.</p>

<h2 id="newer-data">Newer Data</h2>

<p>Next, I ran the algorithm on modern data.
The most difficult part was resolving name issues, when probablepeople could not figure out an author’s surname.
When this happened, I looked up the author and tried to figure out their surname from their personal webpages.
If their surname didn’t really matter, for example when the author list is clearly not alphabetical, I was less careful.
This means that even for the same person, I would edit names inconsistently when it didn’t matter for alphabetical ordering.
Apologies if you’re one of these authors, or if I messed up your name!</p>

<p>One interesting thing I learned while collecting the data is that many of the ACM conferences were consistently held in the US early on.
I was surprised since some of the major conferences currently alternate (well, usually) between North American and non-North-American locations.
I thought this was a tradition since the start, but this has only been happening for about 20 years.
For example, PLDI was in North America for its first 22 iterations.
POPL was in the US until the 14th in Munich, and did not leave the US again until the 24th POPL.</p>

<p>Finally, the results are plotted below.
They suggest that POPL has been getting more practical over time, and that POPL is the most theoretical of the PL conferences, both of which I agree with.</p>

<h3 id="popl">POPL</h3>
<p><img src="/assets/popl.png" alt="Plot of results for all POPL conferences up to 2022" /></p>

<p>The errors bars are far smaller nowadays, owing to the lower number of single-author papers and the higher overall number of papers presented each year.</p>

<h3 id="pl-conferences-20202022">PL Conferences 2020–2022</h3>
<p><img src="/assets/2022.png" alt="Plot of results for some PL conferences from 2020 to 2022" /></p>]]></content><author><name>Paul He</name></author><summary type="html"><![CDATA[As part of the program chair’s report for POPL 1992, Andrew Appel wrote a paper titled “Is POPL Mathematics or Science?” His paper measured how theoretical a conference is using the author ordering of the papers published. While this paper was meant to “provide some laughs”, I thought it was very interesting and reproduced the results for both the same data and for present-day programming languages conferences.]]></summary></entry><entry><title type="html">CV of Failures</title><link href="https://paulhe.com/2021/11/10/cv-failures.html" rel="alternate" type="text/html" title="CV of Failures" /><published>2021-11-10T00:00:00-05:00</published><updated>2026-03-29T00:00:00-04:00</updated><id>https://paulhe.com/2021/11/10/cv-failures</id><content type="html" xml:base="https://paulhe.com/2021/11/10/cv-failures.html"><![CDATA[<p>Most of what we publicly show of ourselves is positive.
This can give others the impression that they are the odd one out, who has failures when everyone else only seems to succeed.
But in reality, everybody fails—we simply hide the failures.
This CV of failures aims to make my efforts more transparent, and to provide a more balanced perspective on my career.</p>

<p>This idea is not new, but originates from an <a href="https://doi.org/10.1038/nj7322-467a">article</a> by Melanie Stefan.</p>

<h2 id="conference-submission-rejections">Conference Submission Rejections</h2>

<ul>
  <li>Koli Calling 2025</li>
  <li>ICER 2025</li>
  <li>TLS (at U of T) 2025</li>
  <li>SIGCSE 2025</li>
  <li>ESOP 2023</li>
  <li>OOPSLA 2022 (both rounds of submission!)</li>
  <li>PLDI 2021</li>
  <li>ICFP 2019</li>
  <li>MFCS 2018</li>
  <li>LICS 2018</li>
</ul>

<h2 id="fellowship-and-award-rejections">Fellowship and Award Rejections</h2>

<ul>
  <li>Penn CTL Graduate Fellowship 2021-2022</li>
  <li>NSERC PGS D 2021</li>
  <li>Facebook Fellowship 2021</li>
  <li>Penn CTL Graduate Fellowship 2020-2021</li>
  <li>NSERC PGS D 2020</li>
  <li>NSERC CGS M 2018 at McGill</li>
  <li>NSERC CGS M 2018 at uOttawa</li>
  <li>UWaterloo K.D. Fryer Medal 2018</li>
</ul>

<h2 id="rejected-school-and-job-applications">Rejected School and Job Applications</h2>

<ul>
  <li>Around 20 teaching-track faculty positions, 2023</li>
  <li>CMU CS PhD program 2018</li>
  <li>Around 100 software engineering internships at UWaterloo, 2014-2016</li>
</ul>

<h2 id="other-rejections">Other Rejections</h2>

<ul>
  <li>Working group (round 1) at ITiCSE 2026</li>
  <li>Student volunteering at conferences during my PhD, all the time</li>
  <li>PLDI 2020 SRC, where the top 3 posters win a prize, there were 4 entrants, and I got 4th</li>
</ul>]]></content><author><name>Paul He</name></author><summary type="html"><![CDATA[Most of what we publicly show of ourselves is positive. This can give others the impression that they are the odd one out, who has failures when everyone else only seems to succeed. But in reality, everybody fails—we simply hide the failures. This CV of failures aims to make my efforts more transparent, and to provide a more balanced perspective on my career.]]></summary></entry><entry><title type="html">Weak weeks</title><link href="https://paulhe.com/2019/10/23/weak-weeks.html" rel="alternate" type="text/html" title="Weak weeks" /><published>2019-10-23T00:00:00-04:00</published><updated>2019-10-23T00:00:00-04:00</updated><id>https://paulhe.com/2019/10/23/weak-weeks</id><content type="html" xml:base="https://paulhe.com/2019/10/23/weak-weeks.html"><![CDATA[<p>In August I tried to abandon the concept of the days of the week.</p>

<p>I had very few scheduled responsibilities: only a single meeting scheduled for each week.
The goal was to reduce mood changes due to the day of the week, like getting no work done on Fridays and disappointment on Sundays.
Though studies on this <sup id="fnref:1" role="doc-noteref"><a href="#fn:1" class="footnote" rel="footnote">1</a></sup> suggest that there is little support for some of these phenomena, I wanted to see for myself.</p>

<p>The first few week were fine; I’d try to go to work around five days a week, and take days off when I felt like I needed one.
I especially tried to work on weekends, since I was more productive (or at least happier with music on my speakers) when the office was empty.
This was a pretty good setup.
I felt like I had a lot of flexibility and got a decent amount done.</p>

<p>But then I got a cat.
I stayed home way too much to watch her, even though she was still adjusting and wasn’t especially playful.
The summer ended with me doing far less than I wanted to.
Nevertheless, I’d like to try this experiment again, especially since it seemed fruitful from the first few weeks.</p>

<p>Anyways, here’s some photos of my cat Strawberry, the real reason for the post.</p>

<p><img src="/assets/strawberry1.jpg" alt="Strawberry" />
<img src="/assets/strawberry2.jpg" alt="Strawberry" />
<img src="/assets/strawberry3.jpg" alt="Strawberry" />
<img src="/assets/strawberry4.jpg" alt="Strawberry" />
<img src="/assets/strawberry5.jpg" alt="Strawberry" />
<img src="/assets/strawberry6.jpg" alt="Strawberry" /></p>

<div class="footnotes" role="doc-endnotes">
  <ol>
    <li id="fn:1" role="doc-endnote">
      <p>Arthur A. Stone, Stefan Schneider &amp; James K. Harter (2012) Day-of-week mood patterns in the United States: On the existence of ‘Blue Monday’, ‘Thank God it’s Friday’ and weekend effects, The Journal of Positive Psychology, 7:4, 306-314, DOI: 10.1080/17439760.2012.691980 <a href="#fnref:1" class="reversefootnote" role="doc-backlink">&#8617;</a></p>
    </li>
  </ol>
</div>]]></content><author><name>Paul He</name></author><summary type="html"><![CDATA[In August I tried to abandon the concept of the days of the week.]]></summary></entry><entry><title type="html">Coinduction</title><link href="https://paulhe.com/2019/04/17/coinduction.html" rel="alternate" type="text/html" title="Coinduction" /><published>2019-04-17T00:00:00-04:00</published><updated>2019-10-23T00:00:00-04:00</updated><id>https://paulhe.com/2019/04/17/coinduction</id><content type="html" xml:base="https://paulhe.com/2019/04/17/coinduction.html"><![CDATA[<p>Coinduction is the mathematical dual to an indispensible mathematical tool: induction.
While mathematical induction has been known for thousands of years, coinduction has only been studied for a few decades.
It is still primarily used in computer science, from which it originated in the field of concurrency theory.
Coinduction allows us to define circular or <em>infinite</em> objects (such as <a href="https://en.wikipedia.org/wiki/Stream_(computer_science)">streams</a>, lists that can be infinitely long), and to prove things about them.</p>

<p>It should not be confused with <a href="https://en.wikipedia.org/wiki/Coinduction_(anaesthetics)">this coinduction</a>, which may put you to sleep instead.</p>

<h2 id="inductive-definitions">Inductive definitions</h2>

<p>Inductive (or recursive) definitions are ubiquitous in mathematics, to the point where they are often implicit.
They follow a common pattern to build up a set of objects incrementally.
A base case (or multiple) is first established, and then rules for building up objects based on previous levels are defined.</p>

<p>The set of finite strings \(S\) on an alphabet \(\Sigma\) is the set inductively defined by the following rules, in <a href="https://en.wikipedia.org/wiki/Rule_of_inference">inference rule</a> notation:</p>

\[\frac{}{\epsilon \in S} \qquad \frac{s \in S \quad \sigma \in \Sigma}{\sigma s \in S}\]

<p>So \(\epsilon\) (the empty string) is a string, and for any symbol \(\sigma\) in the alphabet, we can prepend that onto another string to yield a string.
Only the objects generated from the rules are in \(S\).</p>

<p>Inductive definitions can be thought of as an iterative process: we start with the empty set and keep adding objects according to the definition, until in the limit, we reach a <a href="https://en.wikipedia.org/wiki/Fixed_point_(mathematics)">fixed point</a>, when applying the rules no longer adds anything new to the set.
We add \(\epsilon\), then the length 1 strings, then the length 2 strings, and so on, until we have the infinite set of strings over \(\Sigma\)  of any length in \(\mathbb{N}\).</p>

<p>An inductive definition is thus the <em>smallest</em> set closed <em>forward</em> under its defining rules.
That is, \(S\) is the smallest set such that \(\epsilon \in S\) and that if \(s \in S\), then \(\sigma s \in S\) for any \(\sigma \in \Sigma\).
We apply the rules from premises to conclusion.</p>

<h2 id="coinductive-definitions">Coinductive definitions</h2>

<p>Since coinduction is the dual to induction, let’s try “flipping” the inductive definition.
A coinductive definition is the <em>largest</em> set closed <em>backward</em> under its defining rules.</p>

<p>What does this mean?
For an inductive definition, we can think of the set as starting from \(\varnothing\) and iteratively adding elements according to the rules.
For a coinductive definition, we can think of the set as starting from the set of all possible objects (even infinite ones), and iterative removing objects that contradict the rules.</p>

<p>If we use the same rules that inductive defined \(S\) above, the coinductively defined set \(S'\) is the largest set such that \(\epsilon \in S'\) and that if \(\sigma s \in S\), then \(s \in S\) (and \(\sigma \in \Sigma\)).
Here, the backward closure goes from the conclusion to the premises, the opposite of the forward closure.
The set of finite strings, \(S\), is included in \(S'\).
But we also have some new strings in \(S'\), the infinitely long strings.
Consider the string \(s = aaaaaa \dots\), where \(a \in \Sigma\).
We cannot construct it using the base case, but it doesn’t lead to a contradiction either, since if \(s = aaaaa \dots \in S\), taking off the first \(a\) results in the same infinite string \(s\), and \(s \in S\) as desired.</p>

<p>The proof tree for \(s\) is infinite, and looks like the following:</p>

\[\large \frac{a \in \Sigma \quad \frac{ a \in \Sigma \quad \frac{ \cdots }{ aaa \dots \in S' } }{ aaa \dots \in S' }}{ aaa \dots \in S' }\]

<p>While objects of inductive definitions require finite derivations, objects of coinductive definitions can have infinite derivations.</p>

<h2 id="proof-principles">Proof principles</h2>

<p>For the following, I will skip over some (many) details.</p>

<p>The function \(F\) can be thought of as the set of rules for a given (co)inductive definition.
\(F(X)\) is the set of conclusions obtained after applying the rules using \(X\) as the set of premises.</p>

<p>Recall that an inductive definition is the least fixed point of a set of rules, and that a coinductive definition is the greatest fixed point.
Now here is a specialization of the Knaster–Tarski fixpoint theorem:</p>

<p><strong>Theorem:</strong> <br />
The least fixed point of \(F = \mu F = \bigcap \{ X \mid F(X) \subseteq X \}\). <br />
The greatest fixed point of \(F = \nu F = \bigcup \{ X \mid X \subseteq F(X) \}\).</p>

<p>\(F(X) \subseteq X\) captures the meaning of the informal “closed forwards” definition from earlier.
Given a set \(T\) where the premises \(X \subseteq T\), we can apply <em>all</em> rules in the “forwards” direction, obtaining the set of conclusions \(F(X)\) which are also in \(T\): \(F(X) \subseteq X \subseteq T\).</p>

<p>Dually, \(X \subseteq F(X)\) captures the meaning of “closed backwards”.
Given a set \(T\) where the conclusions \(F(X) \subseteq T\) from some set of premises \(X\), we can apply <em>some</em> rule for each \(t \in F(X)\) in the “backwards” direction, obtaining the set of premises \(X\) which are also in \(T\): \(X \subseteq F(X) \subseteq T\).</p>

<p>Simple corollaries of the fixpoint theorem gives us proof principles for inductive and coinductive definitions:</p>

<p><strong>Lemma (Induction Principle):</strong> <br />
If \(F(X) \subseteq X\), then \(\mu F \subseteq X\). <br />
<strong>Lemma (Coinduction Principle):</strong> <br />
If \(X \subseteq F(X)\), then \(X \subseteq \nu F\).</p>

<h3 id="proof-by-induction">Proof by induction</h3>

<p>Using the induction principle, we can show that every element of a inductively defined set satisfies some condition, by showing that the condition is preserved for each rule of the definition.</p>

<p>We can derive the more familiar principle of mathematical induction using this.
Let \(F(X) = \{ 0 \} \cup \{ 1 + x \mid x \in X \}\).
This is the set of rules for the natural numbers.
It may be more familiar if I write it as the following:</p>

\[\frac{}{0 \in \mathbb{N}} \qquad \frac{n \in \mathbb{N}}{1 + n \in \mathbb{N}}\]

<p>Then to prove some fact about the natural numbers, we just need to show that it is preserved when applying these rules in the forwards direction.
For example, we will show that \(1 + 2 + \dots + n = \frac{n(n+1)}{2}\) is true for all natural numbers.
Let’s take \(X = \{ n \in \mathbb{N} \mid 1 + 2 + \dots + n = \frac{n(n+1)}{2} \}\).
Then we will prove that \(\mu F = \mathbb{N} \subseteq X\).
This is exactly the conclusion of the Induction Principle, so we need to show that \(F(X) \subseteq X\).</p>

<p>An element of \(F(X)\) can either be \(0\) (the base case), which we can easily verify is in \(X\), or \(1 + n\) (the inductive case) where \(n \in X\) (the inductive hypothesis).
This should look familiar.
Some fiddling will show that the second case is true as well, and we are done! \(\Box\)</p>

<h3 id="proof-by-coinduction">Proof by coinduction</h3>

<p>Dually, using the coinduction principle, we can show that an element is in the coinductively defined set.</p>

<p>Using just \(S'\), our only coinductively defined set so far, would not be very interesting, since it would involve only the membership proofs we saw earlier.
Let’s make another coinductive definition, this time a relation on elements of \(S'\): let \(F(X) = \{ (\epsilon, \epsilon) \} \cup \{ (\sigma_1 s_1, \sigma_2 s_2) \mid \sigma_1 \le \sigma_2 \land (s_1, s_2) \in X \}\), where \(\le\) is some ordering on the alphabet (the usual one on the English alphabet, for instance).
Can you tell what relation this defines?
Let’s write down the inference rules:</p>

\[\frac{}{\epsilon \leqslant \epsilon} \qquad \frac{\sigma_1 \le \sigma_2 \qquad s_1 \leqslant s_2}{\sigma_1 s_1 \leqslant \sigma_2 s_2}\]

<p>The notation should help: \(\nu F\) is the lexicographic ordering relation on our (possibly) infinite strings, displayed here as \(\leqslant\).</p>

<p>Now we can prove that some strings are related by this relation.
For an example, we will show \(aaaa \dots \leqslant baaaa \dots\).
Note that these are infinitely long strings.</p>

<p>Using the coinduction principle, we just need to show that \((aaaa \dots, baaaa \dots)\) is in some set of pairs of strings that is closed backwards under \(F\).
Let’s try the singleton set \(X = \{(aaaa \dots, baaaa \dots)\}\) first.
Then \(F(X) = \{ (\epsilon, \epsilon) \} \cup \{ (\sigma_1 aaaa \dots, \sigma_2 baaaa \dots) \mid \sigma_1 \le \sigma_2 \}\).
But then \(X \not \subseteq F(X)\), since the second string of every pair in \(F(X)\) has a \(b\) as the second symbol.</p>

<p>\(X\) is our “coinductive hypothesis”.
Like how during induction we sometimes have to strengthen the inductive hypothesis, here we have to strengthen the coinductive hypothesis by making it bigger.</p>

<p>Recall the “backwards closed” intuition.
We want to show that by applying <em>some</em> rule “backwards”, we obtain something still in \(X\).
If we start with \((aaaa \dots, baaaa \dots)\), we can only apply the second rule, stripping off the first symbol of each string.
\(a \le b\), so that premise is fine, and we just need to show that \((aaaa \dots, aaaa \dots) \in X\) now.
It looks like we need to grow \(X\) by adding this new pair to it, strengthening the coinductive hypothesis.</p>

<p>Now \(X = \{ (aaaa \dots, baaaa \dots), (aaaa \dots, aaaa \dots) \}\), and \(F(X) = \{ (\epsilon, \epsilon) \} \cup \\ \{ (\sigma_1 aaaa \dots, \sigma_2 baaaa \dots) \mid \sigma_1 \le \sigma_2 \} \cup \\ \{ (\sigma_1 aaaa \dots, \sigma_2 aaaa \dots) \mid \sigma_1 \le \sigma_2 \}\)</p>

<p>Let’s check that \(X \subseteq F(X)\). <br />
\((aaaa \dots, baaaa \dots) = (a\cdot aaaa \dots, b\cdot aaaa \dots)\), and \(a \le b\). <br />
\((aaaa \dots, aaaa \dots) = (a\cdot aaaa \dots, a\cdot aaaa \dots)\), and \(a \le a\).</p>

<p>And since \((aaaa \dots, baaaa \dots) \in X\), we’re done! \(\Box\)</p>

<h2 id="conclusion">Conclusion</h2>

<p>Recently I’ve been working on <a href="https://github.com/DeepSpec/InteractionTrees/">Interaction Trees</a>, a library that provides a coinductive data structure for reasoning about interactive programs in Coq.
Coinduction is less convenient than induction in Coq.
For example, in the coinductive proof above the “coinductive hypothesis” included exactly the conclusion we were trying to prove.
When doing the proof informally, we know we must apply one of the rules backwards and only then can we apply the coinductive hypothesis.</p>

<p>Doing this in a proof assistant like Coq is more complex.
Using “vanilla” Coq, it will allow you to apply the coinductive hypothesis immediately, and then complain that you got it wrong when you try to finish the proof.
The <a href="https://github.com/snu-sf/paco">paco</a> library solves this problem, but more complex reasoning quickly gets complex, which is why I started learning more about the theory behind coinduction.</p>

<p>I find it really intriguing how (relatively) new coinduction is and how useful it has become.
There’s been a lot of work recently on areas related to coinduction, and I’m excited to do more work in this area.</p>

<h2 id="resources">Resources</h2>

<p>I first encountered coinduction in <a href="https://www.cis.upenn.edu/~bcpierce/tapl/">Types and Programming Languages</a> by Benjamin C. Pierce, where they are introduced to talk about the metatheory of recursive types. While I wouldn’t recommend reading this if you’re <em>just</em> interested in coinduction, it serves as an excellent introduction to programming languages and type systems.</p>

<p><a href="http://www.cs.unibo.it/~sangio/IntroBook.html">Introduction to Bisimulation and Coinduction</a> by Davide Sangiorgi is a very accessible textbook that goes into detail about all of this and more.
It cleared up a lot of questions I had about coinduction, and helped me understand it more rigorously.</p>]]></content><author><name>Paul He</name></author><summary type="html"><![CDATA[Coinduction is the mathematical dual to an indispensible mathematical tool: induction. While mathematical induction has been known for thousands of years, coinduction has only been studied for a few decades. It is still primarily used in computer science, from which it originated in the field of concurrency theory. Coinduction allows us to define circular or infinite objects (such as streams, lists that can be infinitely long), and to prove things about them.]]></summary></entry><entry><title type="html">Welcome</title><link href="https://paulhe.com/2019/03/06/first-post.html" rel="alternate" type="text/html" title="Welcome" /><published>2019-03-06T00:00:00-05:00</published><updated>2020-08-18T00:00:00-04:00</updated><id>https://paulhe.com/2019/03/06/first-post</id><content type="html" xml:base="https://paulhe.com/2019/03/06/first-post.html"><![CDATA[<p>Welcome to my blog! This is the first (official) post, hopefully of many.</p>

<h2 id="goals">Goals</h2>

<p>I decided to start this blog because I rarely write anything longer than a sentence at a time, which seems like a useful thing to practice for a PhD student.
I’ve also always felt pretty weak at communicating about research or technical stuff (not to mention just in general).
Hopefully this will help me with these things, as well as improve my understanding of the technical material I’ll be writing about.</p>

<p>I plan to write about various technical things I encounter during my research work.
These will probably be things related to functional programming and programming language theory.</p>

<h2 id="website">Website</h2>

<p>Let me tell you a bit about the inner workings of the website, which I spent (and will continue to spend) a lot of time on—instead of writing posts.
The site is static, hosted on <a href="https://pages.github.com/">Github Pages</a>, and is generated by <a href="https://jekyllrb.com/">Jekyll</a>.
I don’t want to handle any complexity related to hosting, so a static website seems fine to me.</p>

<p>However if you look at the bottom of the page, you’ll see something less standard: an ugly hacked together comment system.
I originally tried using <a href="https://disqus.com/">Disqus</a>, which was really quite nice and easy to use.
You can see an example of it on my blog <a href="/2019/02/28/first-post.html">here</a>.</p>

<p>I preferred something more lightweight though, and also something I controlled entirely.
Here’s an <a href="/2019/02/28/second-post.html">example</a> of what my current solution looks like.
You can even embed html (what’s sanitization?)!</p>

<p>I’m using <a href="https://staticman.net/">Staticman</a> to display user-generated content.
When a comment is submitted, it goes through the Staticman web service, which creates a pull request on my website’s Github repo to add the comment as a text file, to be included in the (updated) static site.</p>

<p>I think this is super cool.
No databases or anything to deal with!
Staticman was pretty nice to use, though the documentation is a little out of date.
Originally it was run as a single public instance, and due to the number of users it had it was hitting the rate limit for the Github API (see <a href="https://github.com/eduardoboucas/staticman/issues/243">this Github issue</a> for details).
The developer then updated Staticman to be a Github app, so each user would get their own instance and thus their own API quota.
However, this was fairly recent (Dec 2018) and the documentation wasn’t updated to reflect this, so it took me a few hours to get it working.</p>

<p><strong>Edit</strong> Oct 3: Staticman died at some point! The service is open source, so maybe I will host my own instance on Heroku. <br />
<strong>Edit</strong> Aug 18 2020: Finally hosted my own instance on Heroku. <br />
<strong>Edit</strong> Dec 21 2022: Heroku shut down their free tier, but I’ve managed to migrate to fly.io’s free tier with basically a single click using their migration tool.</p>

<h2 id="to-come">To Come</h2>

<p>I’ll be working on updating the site a bit more to add a navigation menu (<strong>Edit</strong> Mar 7: Done!), less ugly comments (<strong>Edit</strong> Mar 8: Arguably done!), and so on.
For my research I’ll be spending most of my time in the next few weeks on coinduction, a very cool proof technique, and I hope to write something introductory about it soon.</p>]]></content><author><name>Paul He</name></author><summary type="html"><![CDATA[Welcome to my blog! This is the first (official) post, hopefully of many.]]></summary></entry><entry><title type="html">Blogging Like a Hacker</title><link href="https://paulhe.com/2019/02/28/first-post.html" rel="alternate" type="text/html" title="Blogging Like a Hacker" /><published>2019-02-28T00:00:00-05:00</published><updated>2019-02-28T00:00:00-05:00</updated><id>https://paulhe.com/2019/02/28/first-post</id><content type="html" xml:base="https://paulhe.com/2019/02/28/first-post.html"><![CDATA[<h1 id="test">Test</h1>

<div id="disqus_thread"></div>
<script>
    /**
     *  RECOMMENDED CONFIGURATION VARIABLES: EDIT AND UNCOMMENT THE SECTION BELOW TO INSERT DYNAMIC VALUES FROM YOUR PLATFORM OR CMS.
     *  LEARN WHY DEFINING THESE VARIABLES IS IMPORTANT: https://disqus.com/admin/universalcode/#configuration-variables
     */
    /*
    var disqus_config = function () {
        this.page.url = https://paulhe.com/2019/02/28/first-post.html
        this.page.identifier = /2019/02/28/first-post
    };
    */
    (function() {  // DON'T EDIT BELOW THIS LINE
        var d = document, s = d.createElement('script');

        s.src = 'https://paulhe.disqus.com/embed.js';

        s.setAttribute('data-timestamp', +new Date());
        (d.head || d.body).appendChild(s);
    })();
</script>

<noscript>Please enable JavaScript to view the <a href="https://disqus.com/?ref_noscript" rel="nofollow">comments powered by Disqus.</a></noscript>

<script id="dsq-count-scr" src="//paulhe.disqus.com/count.js" async=""></script>]]></content><author><name>Paul He</name></author><summary type="html"><![CDATA[Test]]></summary></entry><entry><title type="html">Comments</title><link href="https://paulhe.com/2019/02/28/second-post.html" rel="alternate" type="text/html" title="Comments" /><published>2019-02-28T00:00:00-05:00</published><updated>2019-02-28T00:00:00-05:00</updated><id>https://paulhe.com/2019/02/28/second-post</id><content type="html" xml:base="https://paulhe.com/2019/02/28/second-post.html"><![CDATA[]]></content><author><name>Paul He</name></author><summary type="html"><![CDATA[]]></summary></entry></feed>