Latest Posts

Watchbill Planning with Integer Programming

22 Feb 2022

***Check out GitHub for my code!***

This month, I begin my third year serving aboard a PCU in the shipyard. This has offered me some unique challenges, among them, personnel management. When a Junior Officer like me shows up to the boat, they need to leave to get experience aboard an operational submarine, so they can be qualified to fully contribute when they get back here. I did this myself on USS John Warner in 2020. These rides are unpredictable: boat schedules constantly shift, along with the number of people they can support aboard. People have their own commitments, at work and in their personal lives. Work in the shipyard also demands some fraction of our officer population.

Mapping My Backyard

10 Jan 2022

I was lucky enough to get a few weeks of leave for Christmas, so I went home to my family’s house in Vermont with my wife, Jackie, and our cat. In between camping and ski-hiking, I was looking for another little project.

My parents bought the land which our house is on when we still lived in Beijing, and there’s a lot of history in the woods. Only two modern roads survive in the immediate area, but if you go into the woods it’s clear that there used to be others, which have been neglected for a long time. The woods are also home to an entire system of bike trails, maintained by the Brewster River Mountain Bike Club, of which my dad is a member. There’s a lot going on up there, but if you look at Google Maps, it’s utterly empty.

Testing Torpedos Part 2

08 Nov 2021

A while back I wrote an article about torpedo guidance strategy in a submarine game. The concept was to compare five different methods of torpedo control, and to implement each in C#. In this follow-up, I test each one and compare them, to see which is most effective.

Hausdorff's Backpacks

30 Sep 2021

Since my last post, I’ve gone backpacking a few times, and each time I try to bring a little less. No, I’m not ultralight yet (often defined as base weight under 10 pounds), but I’m pretty close. My last base weight was 12.1.

Once I went through the relatively easy phases of lightening my bag (bring smaller bottles of things, stop bringing changes of clothes, weigh my meals), I started to fantasize about buying another backpack. This time, I thought to myself, I would get one which was incredibly light. My current pack weighs almost two pounds (17% of my base weight!) and I was desperate to take a little weight off.

Novice Backpacking

06 Sep 2021

Over the long weekend, I took a trip with a few friends out to Seneca Rocks, WV. My friends are big rock climbers, so they spent all day on the rock face. I decided to use the time to take a step towards a long-term goal.

I’ve always wanted to go ski-camping. I have a really sweet pair of Alpine Touring (AT) skis, and I’ve used them to ski around a few resorts and state parks in my home state of Vermont.

Testing Torpedos Part 1

31 Aug 2021

I’ve played pretty much all the big modern submarine simulations (Dangerous Waters, 688I, Silent Service, Sub Command, etc.), and in my opinion, Cold Waters is the most fun by far. It’s not the most realistic game: there is pretty much no parallel between Cold Waters and how sonar, tracking, classification, etc. work in real life. Damage control is pretty simplistic. Driving the submarine is easy. That’s all okay, because that isn’t what Cold Waters is about. The fun part is dodging torpedos.

Moving Fake Objects with Fake Forces

06 Aug 2021

When I tried to design a movement controller for a submarine in Unity, I felt up to the challenge. After all, exerting forces on objects is my main way of interacting with the world. I’ve written previously about my submarine game project; essentially, I’m making a fun little game, inspired by my personal experience, where you drive a submarine around, hunt other submarines, dodge torpedos, etc. The game was never supposed to be a faithful representation of real life, it’s just for fun.

Remaking this Website

31 Jul 2021

I have a confession to make.

How Far is That By Car?

20 May 2021

All of this code is on Github, so check it out, if you can!

My wife, Jackie, is a medical student at UCSF, but this week she visited me! So far, we've had a ton of fun in Norfolk, and we have some great plans for the weekend.

Without fail, Jackie brings me new interesting problems every time she comes here. Right now, she's working on determining the distances from patients' homes to the hospital. For anonymity, only patients' zip codes are used. Essentially, the problem can be stated like this:

Navigating with Fractals

25 Apr 2021

I caught COVID at work earlier this year, so I ended up with a few weeks at home in isolation. In order to pass the time, I decided to try and learn a bit about the Unity game engine. I had a blast with it, and started to wonder how hard it would be to program a (simple) video game. The 3D physics simulation within Unity reminded me a lot of the phase spaces in continuous dynamics, which I have studied a fair bit, so I felt up to the challenge.