Show all tags

Nice find, detective! ;)

Latest Posts


Turning Studio Headphones Into a Headset

In a recent virtual meeting a new colleague was surprised to see me using a Beyerdynamic DT 770 PRO headset – a product Beyerdynamic does not even list. The DT 770 PRO are well-known studio headphones, and so are all the other entries in Beyerdynamic’s studio line. Only their gaming line of products features headsets. So how could I possibly be using a device that does not seem to exist?

The solution is unspectacular if one is aware of “detachable microphones”. To turn a wired studio headphone into a headset all one needs to do is to make it possible to attach such a microphone. This post illustrates

  • how replacing the integrated headphone cable by an audio jack achieves this,
  • the concrete implementation using my DT 770 PRO as a test object.
» Read more

Solving the "Seven Segment Search" Puzzle with Z3

This week I stumbled upon someone wondering whether the second part of the recent Advent of Code puzzle “Seven Segment Search” can be expressed as a constraint satisfaction problem. As attested by the replies: yes, it can. However, I think the question deserves a more extensive discussion than just a few comments in a thread. This post tries to provide a more instructive answer and raise awareness for the tradeoffs or solver misuses some solutions put up with.

I assume that the reader is familiar with mathematical notation and

  • just struggles to express the posed problem in a formal, declarative way, or
  • is interested in seeing how the SMT solver Z3 can be used to express and solve the problem in several logics. It takes only few steps to get from a quantifier-laden high-level formulation to what is effectively propositional logic.
» Read more

Generating Crosswords via SAT/SMT

Recently I got interested in designing personalised crosswords as a way to spice up photo book presents. This made me realise how hard generating high-quality crosswords actually is. Trying to create a crossword from a set of words – or a subset thereof – I checked out several tools but found all of them to be based on heuristics and yield rather sparse crosswords.

In line with the general theme of my previous posts, this one illustrates how we can leverage SAT solving to solve this problem. In contrast to related approaches, which assume a fixed grid structure and search for fitting words, we consider word placement as part of the problem and eventually end up with an integrated solution to generating crosswords of adjustable quality.

» Read more

Playing Hard Mastermind Games with a SAT-based AI

Back in the day, Mastermind was a popular two player code-breaking game, and many variations thereof still exist as both standalone games and puzzles within other games. Although it is difficult for a human player to make optimal guesses of the secret code, or at least guesses that do not conflict with the provided clues, the setting is usually simple enough for an AI to find such candidates via explicit exploration of the game tree.

However, such approaches become unfeasible when the number of possibilities for secret codes grows into the millions. This post illustrates the problem with standard approaches, and how finding consistent candidates can be approached with SAT solving – yielding an AI that can handle orders-of-magnitude harder Mastermind instances.

» Read more

Solving a Logic Synthesis Puzzle via SAT/SMT

A few weeks ago, I was asked the following riddle: Design a logic circuit with three inputs and three outputs, such that the outputs are the inverted inputs. You may use arbitrary many AND and OR gates, but at most two NOT gates. Although the characterisation of this problem as an SMT instance is straightforward, I found it necessary to reduce it to SAT and incorporate further assumptions to achieve reasonable performance.

This post illustrates said process, ranging from the original idea to a standard formulation of SAT-based logic synthesis to a problem-specific and more constrained instance.

» Read more