Introducing Sharp Scale: A Series of Generative Quantum Art Pieces

Russell Huffman
Qiskit
Published in
6 min readFeb 22, 2022

By Joel Russell Huffman and Eduardo Reck Miranda

The Sharp Scale is a series of seven quantum generative art pieces by Joel Russell Huffman and Eduardo Reck Miranda produced with an IBM Quantum system, released as NFTs.

An animation of the visual portion of the series

This series is a part of the practice of using emerging technology in art. The use of computers to create art has evolved steadily since the 1960s. For example, in music, between 1967 and 1969 John Cage used a computer to compose HPSCHD, in collaboration with another pioneer, Lejaren Hiller. In visual art, Harold Cohen pioneered the use of artificial intelligence to make drawings in the 1970s, and Andy Warhol is known to have used an Amiga personal computer to create pop art in the 1980s.

Today, computers have become ubiquitous in art and music. And we think that emerging quantum computing technology will push this trend and its boundaries forward.

Nut and bolts

Our goal with the Sharp Scale was to create audio-visual pieces using a quantum computer’s interpretation of the musical symbol for “sharp.” To do so, we needed to be able to input the sharp symbol into a quantum system in a way it could recognize, and then we needed to do something both visually and audibly interesting with the output. The series can be broken down into three distinct but interconnected parts: the quantum computing element, the visual design, and the audio design. The audio and visual parts were driven by the data returned by the quantum system, so it is important to understand what the quantum computer actually did.

Like any computer, a quantum computer takes an input, performs operations on it, and returns an output — but those operations can be uniquely quantum. As an input, we used the ASCII representation for the hash symbol as the sharp sign , converted into binary code— 100011. We then encoded that binary string as a quantum oracle using the Bernstein-Vazirani Algorithm (an in-depth explanation of the Bernstein-Vazirani algorithm can be found here). We can use the algorithm to measure the oracle and find this “secret” string. With an ideal quantum computer, the oracle’s string could be found in just one measurement, but because we are working with noisy quantum systems, we executed the algorithm 4096 times.

After running the quantum algorithm, we stored the outputs in a text file that consisted of a series of binary strings from each measurement. Henceforth this will be referred to as the quantum data. On an ideal machine, the quantum data would have been the binary string 100011 repeated 4096 times. But the effects of noise meant that the quantum data also included other 6 bit combination of 0s and 1s. That’s okay. For our artistic purposes this is exactly what we want and we will use the noise to craft our composition.

The Visual part

We created the visual aspect of this piece with Processing. The quantum data was stored in the data folder of the Processing project and imported into the Processing sketch for usage. The shape of the sharp sign was not created with a quantum system — we fed the program a hash sign in the IBM Plex typeface.

The Processing sketch iterates over the pixels of the sharp sign, with one pixel per animation frame. For each pixel of the # sign, the program references the quantum data, one at a time. If the quantum value was correct (ie 100011), it draws a black filled square. If the value is incorrect, the program draws a hollow square of a size determined by converting the binary quantum value to an integer. The program continues this way until the entire composition is drawn, which is an enlarged representation of the sharp symbol composed of squares created with the above rules from the quantum data. Further reading on the visual elements of this composition can be found here (https://medium.com/qiskit/quantum-computer-meets-pen-plotter-21c0f0c136d2) in a similar project Huffman did with a quantum alphabet.

The Audio part

The audio portion of the composition was ultimately assembled in Processing as well, but the audio files themselves were composed. Because our quantum oracle was 6 bits, there are 64 different possible returned values. We created 63 different audio files, one for each incorrect value (each binary value between 000000 and 111111 that is not 100011). We created a separate set of audio files containing a melody to be played when the correct value was returned.

The audio files are triggered with the same logic as the visual aspect. If the correct value was returned from the quantum data, the animation stops and plays a snippet of the core melody. If the value is incorrect, the binary string is converted to a number, and the audio file corresponding to that index is played. The incorrect audio files do not pause the animation and are triggered at each frame, meaning multiple can be played at the same time, creating a cacophonous sound analogous to the quantum noise used to create the piece. Both the audio and visual aspects triggered by the quantum data creates the final compositions of each of the pieces in the series.

The goal of this piece was not to be a demonstration or a representation of quantum mechanics, nor do we ask why the world is governed by quantum mechanics. Instead, we set out to wield these quantum mechanical properties as a force for creativity. The audio files and overall artistic compositions are determined by us as artistic creators while the quantum computer was used as a form of paintbrush or instrument to determine when the audio files would be played, and where the individual squares would be placed. To some people this may be a trivialization of the fundamental quantum mechanical properties that govern the world. But to us, the core value of quantum computing is to explore what can be done with quantum mechanics;— to put quantum mechanics to work. With this artwork, we are wielding quantum mechanics as a creative mechanism.

We are publishing the series as a set of NFTs composed of seven compositions, each named after one of the seven musical notes of a diatonic musical scale. We understand that NFTs (non-fungible tokens) are a controversial topic marred by hype, and in many cases the hype isn’t warranted. However, as digital artists,we felt that this is an appropriate way to authenticate our art. We won’t do a deep dive into NFTs here, but for our purposes, an NFT is a certificate of authenticity that denotes a piece of digital artwork as a one-of-a-kind original that cannot be replicated. Like NFTs, quantum information cannot be replicated. Also, because quantum computers are non-deterministic, no two artistic compositions will be the same, even when they are run from the same code. For this reason, we minted 7 NFTs, all coming from the same source code, but all 7 are different. No matter how many times the code is run, the output compositions will always be one-of-a-kind unique, despite using the same constituent parts.

If you would like to see and hear the final audio visual compositions, they can be found on here on opensea.io where they were packaged up as a video and minted as NFTs.

About the authors

Eduardo Reck Miranda is a composer working at the crossroads of music and science, and a professor at the University of Plymouth, UK. More about Miranda can be found with the following links: https://medium.com/@ed.miranda
https://medium.com/qiskit/presenting-the-1st-international-symposium-on-quantum-computing-and-musical-creativity-87a3301b9726

Russell Huffman is an artist working with quantum computing as a creative medium, and designer with IBM Quantum focusing on education and the open source community. More about Huffman can be found with the following links:
https://medium.com/@jrussellhuffman
https://www.instagram.com/jrussellhuffman/

Editor’s note: The work depicted in this blog post is a creation solely of the blog’s authors, and is not a product created, sold, or endorsed by IBM, IBM Quantum, or Qiskit.

--

--

Russell Huffman
Qiskit
Writer for

I am a product manager with Quantum Computing Inc. I have an art background but grad school at Georgia Tech brought me into the tech scene.