
This reproducible starter demonstrates quantum signal sonification using a synthetic, quantum-inspired measurement trace. It maps a simulated expectation-value time series to audio so the processing can be tested end to end. The data are generated classically; this example does not run a quantum computer, establish entanglement, or provide evidence of a biological or physical quantum signal.
What this demonstration does
- Creates a deterministic simulated trace bounded between -1 and +1.
- Maps the trace to pitch and amplitude using explicit, documented rules.
- Writes a WAV audio file that can be replayed and compared across runs.
- Provides simple checks for finite values, range, sample rate, and output duration.
Install requirements
python -m pip install numpy scipy
Runnable Python example
Save this as quantum_signal_sonification_demo.py and run it with Python 3.10 or newer. It creates simulated_quantum_signal.wav in the current directory.
import numpy as npfrom scipy.io.wavfile import write# Reproducible synthetic trace, not a real quantum measurement.sample_rate = 44_100duration_seconds = 8.0n_points = 400t = np.linspace(0.0, duration_seconds, n_points, endpoint=False)# Illustrative bounded signal with a slow trend and oscillation.signal = 0.65 * np.sin(2 * np.pi * 0.35 * t) + 0.25 * np.cos(2 * np.pi * 0.12 * t)signal = np.clip(signal, -1.0, 1.0)# Validation: finite data, expected range, and valid audio settings.assert np.isfinite(signal).all(), "Signal contains NaN or infinity"assert signal.min() >= -1.0 and signal.max() <= 1.0assert sample_rate > 0 and duration_seconds > 0# Piecewise-linear interpolation from the slow data trace to audio samples.audio_t = np.arange(int(sample_rate * duration_seconds)) / sample_ratetrace_t = np.linspace(0.0, duration_seconds, n_points, endpoint=False)mapped = np.interp(audio_t, trace_t, signal)# Mapping rules:# signal -1..+1 -> tone frequency 220..880 Hz# absolute signal -> amplitude envelope 0.15..0.80frequency = 220.0 + (mapped + 1.0) * 0.5 * (880.0 - 220.0)amplitude = 0.15 + np.abs(mapped) * 0.65# Integrate instantaneous frequency to create a continuous-phase tone.phase = 2.0 * np.pi * np.cumsum(frequency) / sample_rateaudio = amplitude * np.sin(phase)# Fade in/out to reduce clicks at the file boundaries.fade_samples = int(0.02 * sample_rate)fade = np.linspace(0.0, 1.0, fade_samples)audio[:fade_samples] *= fadeaudio[-fade_samples:] *= fade[::-1]# Convert safely to signed 16-bit PCM and write a mono WAV file.pcm = np.int16(np.clip(audio, -1.0, 1.0) * 32767)write("simulated_quantum_signal.wav", sample_rate, pcm)print(f"Wrote simulated_quantum_signal.wav ({duration_seconds:.1f} seconds)")print(f"Input range: {signal.min():.3f} to {signal.max():.3f}")
Audio-mapping rules
| Input feature | Mapping | Purpose |
|---|---|---|
| Signal value (-1 to +1) | Pitch from 220 to 880 Hz | Make signed changes audible as pitch movement |
| Absolute signal value (0 to 1) | Amplitude from 0.15 to 0.80 | Represent magnitude without silence at zero |
| Time | Linear interpolation to 44.1 kHz | Produce continuous audio samples |
Validation and reproducibility checklist
- Input integrity: verify all values are finite and within the documented range.
- Repeatability: the same script and library versions should produce the same synthetic input trace and mapping.
- Audio integrity: confirm the WAV sample rate, duration, channel count, and PCM range.
- Perceptual evaluation: compare multiple mappings and test whether listeners can reliably identify the changes being encoded.
- Controls: compare against shuffled, constant, and noise-only traces to detect patterns created by the mapping itself.
- Documentation: record code version, parameters, dependencies, input provenance, and any preprocessing.
Scientific limitations
This is a sonification software demonstration using simulated data. It is not a quantum simulator, does not calculate a quantum state, and cannot support conclusions about entanglement, quantum advantage, pineal activity, or biological quantum effects. For real research, replace the synthetic trace with documented measurement results or output from a validated quantum simulation, retain provenance and calibration details, and define controls and statistical tests before interpreting the sound. Sonification is a representation of data, not independent proof of the phenomenon represented.
Continue the 4realsy® research pathway
Read the Quantum Signal Sonification flagship research page, the Quantum Signal Translation, Validation, and Sonification Architecture, Quantum Data to Sound, What Is Quantum Sonification?, and Quantum Sonification Research & Applications.