<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Posts on Timothy Gebhard</title>
    <link>/posts/</link>
    <description>Recent content in Posts on Timothy Gebhard</description>
    <generator>Hugo</generator>
    <language>en</language>
    <lastBuildDate>Tue, 06 Jun 2023 00:00:00 +0000</lastBuildDate>
    <atom:link href="/posts/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Using git-latexdiff for paper rebuttals</title>
      <link>/posts/using-git-latexdiff-for-paper-rebuttals/</link>
      <pubDate>Tue, 06 Jun 2023 00:00:00 +0000</pubDate>
      <guid>/posts/using-git-latexdiff-for-paper-rebuttals/</guid>
      <description>&lt;p&gt;&lt;em&gt;As the title already suggests, the following post assumes that you write your research papers with &lt;strong&gt;LaTeX&lt;/strong&gt; (or XeTeX / LuaTeX / &amp;hellip;). If you are in one of the unfortunate fields of science that insist on using Word to write papers, your best bet is probably to use the built-in &amp;ldquo;track changes&amp;rdquo; feature?&lt;/em&gt;&lt;/p&gt;&#xA;&lt;p&gt;When you write a rebuttal for a research paper, you usually have to attach a revised version of your manuscript where you have marked all the changes that you have made.&#xA;Talking to some of my colleagues at work recently, I was surprised to learn that many people seem to do this manually: For example, when they change a sentence, they delete the old one and write the new one in bold, using &lt;code&gt;\textbf{}&lt;/code&gt;.&#xA;Obviously, this is a strategy that &lt;em&gt;works&lt;/em&gt;, but it is not very efficient:&#xA;If you go through several rounds of changes or revisions, it quickly becomes difficult to keep track of what is &amp;ldquo;new&amp;rdquo; (and relative to what), and of course, once your manuscript is accepted, you have to go through it again to remove all the commands you added to mark up your changes.&lt;sup id=&#34;fnref:1&#34;&gt;&lt;a href=&#34;#fn:1&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;1&lt;/a&gt;&lt;/sup&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Finding the smallest separation of Venus and Jupiter</title>
      <link>/posts/finding-the-smallest-separation-of-venus-and-jupiter/</link>
      <pubDate>Thu, 02 Mar 2023 00:00:00 +0000</pubDate>
      <guid>/posts/finding-the-smallest-separation-of-venus-and-jupiter/</guid>
      <description>&lt;p&gt;If you have looked up at the (cloud-free) sky around dawn or dusk these days, you may have noticed an unusual celestial sight: Venus and Jupiter in very close conjunction.&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;    &lt;img src=&#34;/posts/finding-the-smallest-separation-of-venus-and-jupiter/venus-jupiter-flickr.jpg&#34;&gt;&#xA;    &lt;figcaption&gt;&#xA;        The picture is &lt;a href=&#34;https://flic.kr/p/2ojCDpb&#34;&gt;from Michael Khan&#39;s Flickr&lt;/a&gt; (published under a &lt;a href=&#34;https://creativecommons.org/licenses/by-nd/2.0/&#34;&gt;CC BY-ND 2.0 license&lt;/a&gt;) because I did not have much luck with the cloud situation...&#xA;        Check out the full size original, you can even see some of Jupiter&#39;s moons!&#xA;    &lt;/figcaption&gt;&#xA;&lt;/figure&gt;&#xA;&lt;p&gt;The reason I bring it up here is that a good friend of mine used it as a sort of astronomical ammunition to &lt;a href=&#34;https://xkcd.com/356/&#34;&gt;nerd-snipe&lt;/a&gt; me.&#xA;He complained that all the popular science articles in mainstream news outlets just mentioned that Venus and Jupiter were going to get really close, but never said &lt;em&gt;when exactly&lt;/em&gt; that would happen or &lt;em&gt;how close exactly&lt;/em&gt; they would get.&#xA;He then went on to say:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Named groups for regex in Python</title>
      <link>/posts/named-groups-in-regex-in-python/</link>
      <pubDate>Sat, 23 Jul 2022 00:00:00 +0000</pubDate>
      <guid>/posts/named-groups-in-regex-in-python/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://en.wikipedia.org/wiki/Regular_expression&#34;&gt;Regular expressions  (regex)&lt;/a&gt; are still a bit of my Achilles&amp;rsquo; heel in programming.&#xA;I think they are super cool and useful, but I always have to rely heavily on cheatsheets, StackOverflow, and websites like &lt;a href=&#34;https://pythex.org/&#34;&gt;Pythex&lt;/a&gt; to really get them to do what I want.&#xA;Today was at least the third time in the past couple of weeks that I found myself searching for &amp;ldquo;named groups&amp;rdquo; and how exactly they work in Python.&#xA;Of course, I ended up on &lt;a href=&#34;https://stackoverflow.com/q/10059673/4100721&#34;&gt;the same StackOverflow question&lt;/a&gt; as always, and as all the times before, I was briefly confused because the code I wanted to copy is in the &lt;em&gt;question&lt;/em&gt;, not in the accepted answer.&lt;sup id=&#34;fnref:1&#34;&gt;&lt;a href=&#34;#fn:1&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;1&lt;/a&gt;&lt;/sup&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Descriptive placeholder figures with TikZ</title>
      <link>/posts/descriptive-placeholder-figures-with-tikz/</link>
      <pubDate>Fri, 03 Jun 2022 00:00:00 +0000</pubDate>
      <guid>/posts/descriptive-placeholder-figures-with-tikz/</guid>
      <description>&lt;p&gt;When I am just starting to write the first draft of a new paper, I like to use dummy figures as placeholders.&#xA;This allows me to structure everything and think about the overall &amp;ldquo;story&amp;rdquo; without immediately getting myself into the rabbit hole of making &lt;em&gt;nice&lt;/em&gt; figures.&lt;/p&gt;&#xA;&lt;p&gt;There are a number of options out there for placeholder figures in LaTeX, and &lt;a href=&#34;https://tex.stackexchange.com/questions/44195/placeholder-for-figure-includegraphics&#34;&gt;this StackOverflow thread should give you a nice overview&lt;/a&gt;.&lt;sup id=&#34;fnref:1&#34;&gt;&lt;a href=&#34;#fn:1&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;1&lt;/a&gt;&lt;/sup&gt;&#xA;However, none of them &lt;em&gt;really&lt;/em&gt; seems to give me what I would want, namely, the option to specify the size of the figure and add a description of what this figure will contain once I get around to actually making it.&#xA;So I just made my own macro using TikZ&lt;sup id=&#34;fnref:2&#34;&gt;&lt;a href=&#34;#fn:2&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;2&lt;/a&gt;&lt;/sup&gt;:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Adjusting the spacing of references in $\LaTeX$</title>
      <link>/posts/adjusting-spacing-references-latex/</link>
      <pubDate>Fri, 18 Mar 2022 00:00:00 +0000</pubDate>
      <guid>/posts/adjusting-spacing-references-latex/</guid>
      <description>&lt;p&gt;Putting the final polishing touches on the paper that I am currently working on, I noticed there was something &lt;em&gt;weird&lt;/em&gt; about the spacing of the entries in the bibliography:&#xA;For some reason, the space between the lines of one entry was larger than the space between different entries!&lt;/p&gt;&#xA;&lt;p&gt;Here is an example of what I am talking about:&lt;/p&gt;&#xA;&lt;figure&gt;&#xA;    &lt;img src=&#34;/posts/adjusting-spacing-references-latex/before.png&#34; alt=&#34;Before&#34;&gt;&#xA;    &lt;figcaption&gt;&#xA;        The references with default spacing.&#xA;    &lt;/figcaption&gt;&#xA;&lt;/figure&gt;&#xA;&lt;p&gt;Ugly, right?&#xA;Now, I do admit that this might not be the most important thing, and that some people perhaps would not even notice this, but to me it stuck out like a sore thumb, and frankly, it bothered me.&#xA;I have put a lot of work into this paper, and I want it to look &lt;em&gt;good&lt;/em&gt;.&#xA;I mean, wanting your work to look good is &lt;a href=&#34;https://en.wikipedia.org/wiki/TeX#History&#34;&gt;how the whole $\TeX$ thing got started&lt;/a&gt; in the first place.&#xA;So I did the inevitable and went on a journey through the depths of &lt;a href=&#34;https://tex.stackexchange.com&#34;&gt;StackExchange&lt;/a&gt;…&lt;/p&gt;</description>
    </item>
    <item>
      <title>Richer progress bars for _rich_</title>
      <link>/posts/richer-progress-bars-for-rich/</link>
      <pubDate>Wed, 16 Mar 2022 00:00:00 +0000</pubDate>
      <guid>/posts/richer-progress-bars-for-rich/</guid>
      <description>&lt;p&gt;I recently came across &lt;a href=&#34;https://github.com/Textualize/rich&#34;&gt;rich&lt;/a&gt;, &lt;em&gt;&amp;ldquo;a Python library for rich text and beautiful formatting in the terminal.&amp;rdquo;&lt;/em&gt;&#xA;It has about a gazillion features, but the one that I have used the most so far is the progress bar provided in &lt;code&gt;rich.progress.track()&lt;/code&gt;, which works very similar to &lt;em&gt;tqdm&lt;/em&gt;, but looks much nicer.&#xA;The only thing that has stopped me from ditching &lt;em&gt;tqdm&lt;/em&gt; and replacing it with &lt;em&gt;rich&lt;/em&gt; is that the latter, at least by default, does not show the elapsed time or the number of tasks completed.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Can we see JWST using Hubble?</title>
      <link>/posts/can-we-see-jwst-with-hubble/</link>
      <pubDate>Thu, 06 Jan 2022 00:00:00 +0000</pubDate>
      <guid>/posts/can-we-see-jwst-with-hubble/</guid>
      <description>&lt;p&gt;Ever since its Christmas present-like launch about two weeks ago, I have closely followed the &lt;a href=&#34;https://jwst.nasa.gov/content/webbLaunch/whereIsWebb.html&#34;&gt;progress&lt;/a&gt; of the &lt;em&gt;James Webb Space Telescope&lt;/em&gt; (JWST, or Webb, for short).&#xA;During one of the live streams, I was a bit surprised to learn that there are actually no cameras at all on JWST that can be used to visually monitor the progress of the deployments.&#xA;There are &lt;a href=&#34;https://youtu.be/IBPNi7uGgWM?t=1520&#34;&gt;a number of good reasons&lt;/a&gt; for this (including, e.g., the fact that they would require artificial light, add weight and complexity, and would have to work in pretty extreme conditions), but for me, that just made the whole thing even more impressive.&#xA;Talking to a friend about this, we jokingly came up with the idea that, in case something goes wrong and JWST needs debugging, we could try to use the &lt;em&gt;Hubble Space Telescope&lt;/em&gt; (Hubble, or HST) to take a closer look!&lt;/p&gt;</description>
    </item>
    <item>
      <title>A simple coin toss game?</title>
      <link>/posts/a-simple-toin-coss-game/</link>
      <pubDate>Thu, 16 Dec 2021 00:00:00 +0000</pubDate>
      <guid>/posts/a-simple-toin-coss-game/</guid>
      <description>&lt;p&gt;Let’s imagine we are playing the following simple game:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;In the beginning, we both have $N$ coins.&#xA;Each round, we flip a coin, and if the result is “heads”, you give me one of your coins, while if the result is “tails”, I give you one of my coins.&#xA;To make things a bit more interesting, let us assume that the coin is not necessarily fair, and that the probability for “heads” is $p \in (0, 1)$. The game ends as soon as one of us runs out of coins (that person loses).&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
