I focus on the intersection of Mathematical Planning and Predictive Modeling. This blog is an exploration of applying these techniques to real world problems. Feel free to connect and ask questions. Enjoy!

## SliceMap Rework - Part 2

Welcome to part 2 of this series. In the previous post we setup our problem which is to speed up the SliceMap family of types for sparse data. We created benchmarks and measured the performance of the current implementation. I gave a brief overview of a new approach I had come up with and showed how it failed miserably. We were in a depressing place at the end of the last post but hope burns eternal!...

## SliceMap Rework - Part 1

I have been on a journey to overhaul the underpinnings of the Flips library and it has been a humbling experience. Part of what I believe provides a unique value add compared to other libraries for Mathematical Planning is the SliceMap types. They provide a convenient method for subsetting your data that is intuitive for someone who writes optimization models. The SliceMap types are heavily influenced by the TupleDict type in the Gurobi library for Python....

## Resources for Linear Programming

I was recently asked about what resources I would recommend for Linear Programming. My response was, “Are you interested in problem formulation? Solution techniques? Algorithmic implementation?” The answer was, “Yes!” Here are the resources that I would recommend for those wanting to dive deep into Linear Programming (LP). Note, I will be focusing strictly on LP instead of Mixed-Integer Programming (MIP). MIP is a logical evolution of LP but brings in a whole host of other challenges....

## Scheduling Jobs for Maximum Efficiency - Part 3

I’ve continued to consult with my friend on the job assignments problem that I have been discussing in post 1 and post 2. At first, he was excited about what we had come up with but I knew there were likely more complexities that had not been uncovered yet. He went back to the client and came away with some new information. He told me, “Mathew, it turns out that machines have limited capacity....

## Scheduling Jobs for Maximum Efficiency - Part 2

In my previous post I introduced a scheduling problem where I needed to assign jobs to machines to achieve the maximum efficiency. We say efficiency is calculated as the number of times a machine must change the job-type it is working on. I want to continue exploring this problem by adding some nuance. Note: Full code for this post can be found here Not Too Many Bad Jobs As my conversation continued with my friend regarding this problem a new constraint came up....

## Scheduling Jobs for Maximum Efficiency - Part 1

I was recently having a discussion with a friend when they brought up a new problem they were looking into. He asked me if it was a good candidate for Mathematical Planning and I said, “Absolutely!” I am abstracting away the specific domain, but this is the essence of the problem. There are a set of machines which can process jobs. The jobs are of different types and sizes....

## Minimizing Waste for the Cutting Stock Problem

I was recently posed the question, “Can you use Mathematical Planning to optimize the Cutting Stock problem?” For those who are not familiar with this problem, you can find the Wikipedia article here. In summary, you have a stock size of paper material from which you need to produce smaller sizes. In the example provided on Wikipedia, the stock size is 5600mm. You are asked to produce a variety of sizes between 1380mm and 2200mm....

## Learning Resources for F#

One of the questions that I get quite a bit is, “How did you learn F#?” I keep getting this question, so I decided to write a short post where I laid out what I have found to be the most useful resources to develop my F# skills. Practice This first piece of advice that I give to people is to choose an algorithm they already know and write it in F#....

## Maximizing Profitability of Inventory with Mathematical Planning and Machine Learning in F# - Part 3

In the previous two posts in this series we introduced the Food Cart Problem. We want a plan for stocking our Food Cart which will maximizes our revenue. In the first post we discussed the foods that we can stock and the restrictions we are operating under. We introduced a simple heuristic for stocking the food cart and created a simulation in order to validate what our expected revenue is....

## Maximizing Profitability of Inventory with Mathematical Planning and Machine Learning in F# - Part 2

In a previous post we discussed the problem of stocking our food cart to maximize our profitability. We created a simple heuristic and then performed simulations to evaluate the expected profitability. We discussed that knowing the expected profitability was not enough, we calculated Confidence Intervals to understand the where the true expected profitability lies. This week we want to find a better plan for packing the food cart. We will use Mathematical Planning to find an answer which maximize the expected profitability which outperforms the heuristic used in the first post....