• Implementing the Dense Array Interface in Julia

    A DenseArray describes a multidimensional array that has regular offets in memory. Implementing multidimensional arrays with the API flexibility of MATLAB (range indexing, colon indexing, etc.) is hard. Julia makes this easy by requiring only four methods to implement a DenseArray (five for copy semantics).

  • Searching for the Most Flexible Grid System

    Every so often, monitor resolutions increase. In tandem, new grid systems are created to support upcoming resolutions. During the era of 1024x960 monitors, we used the 960 grid system for its flexibility. During the era of 1366x768 laptop monitors, we used the 1200 grid system for its flexibility. Now with 4k monitors, what will be the size of the next flexible grid system?

  • Zero-Truncated Poisson Sampling Algorithm

    The Zero-Truncated Poisson distribution is a sample variant of the Poisson distribution that has no zero value. A simple example of this is a the distribution of items a customer has in their shopping cart before approaching a register where it is common to presume that the customer will not approach the cash register without any items to purchase. Efficient sampling algorithms exist and are common for the Poisson distribution, however, few sampling algorithms exist for the Zero-Truncated Poisson distribution. We derive such an algorithm here using the inverse transform method.

  • Why not use Bash for Algorithmic Interviews?

    During an interview, I asked, in jest, whether I could use Whitespace to solve the problem. The interviewer chuckled and said that if I implemented the algorithm in Bash, I would receive an offer on the spot; jokingly. I did not solve the problem in Bash that day; however, I've been wondering why I haven't tried using Bash for algorithmic interviews. This post is an exploration on the subject.

  • Exploring the Hailstone Sequence with Julia

    The hailstone sequence is a sequence of positive integers from an initial value that is popular through the Collatz conjecture, an unsolved problem in mathematics. We are interested in simulating the sequence at various initial values to gain insights to how the stopping time property relates to the initial value.