Given an m * n grid, each edge must be colored. However, there are 2 constraints:
- Entire grid must use only 3 unique colors
- Each square in the grid must be colored using exactly 2 colors (2 edges per color)
I am a full-time consultant and provide services related to the design, implementation and deployment of mathematical programming, optimization and data-science applications. I also teach courses and workshops. Usually I cannot blog about projects I am doing, but there are many technical notes I'd like to share. Not in the least so I have an easy way to search and find them again myself. You can reach me at erwin@amsterdamoptimization.com.
Wednesday, July 12, 2023
Coloring edges of a grid
This is a little coloring problem from [1]:
Let's try to build a GAMS model for this. The question itself is not so interesting, but the modeling for setting up these grids is.
Thursday, July 6, 2023
A Julia thingy
In Julia, we can write 2x instead of 2*x. Not the most earth-shattering. But a bit special nonetheless.
The expression in the last cell is interpreted as a function call.
Sunday, July 2, 2023
Some confusion here
Sometimes you end up visiting strange sites. This is a question & answer site. The question is:
Obviously, this is not a good question. It is something like "what is the difference between a ham sandwich and butter?".
The answers are not so good either.
Subscribe to:
Posts (Atom)