rhythm_pattern_explorer

Rhythm Pattern Explorer

Mathematical Rhythm Pattern Generator and Analyzer

A comprehensive system for generating, analyzing, and manipulating rhythmic patterns using advanced mathematical algorithms including Euclidean rhythms, Barlow’s indispensability theory, and progressive transformations.

Project Structure

This repository is organized into two main components:

Note: For backward compatibility, app/ in the project root is a symbolic link to WebApp/app/

πŸŽ›οΈ Plugin/ - Audio Plugin Implementation

Plugin/
β”œβ”€β”€ Source/                  # C++ plugin source code
β”œβ”€β”€ RhythmPatternExplorer.jucer  # JUCE project file
β”œβ”€β”€ Builds/                  # Xcode build files
β”œβ”€β”€ Tests/                   # Comprehensive test suites
β”œβ”€β”€ Documentation/           # Plugin-specific docs
└── README.md               # Plugin development guide

Formats: Audio Unit (AU), VST3, Standalone
Platform: macOS (iOS experimental)
Status: βœ… Production ready

🌐 WebApp/ - Web Application (Reference Implementation)

WebApp/
β”œβ”€β”€ app/                     # Web application files
β”œβ”€β”€ serve-app.py            # Development server
β”œβ”€β”€ minimal-midi-bridge.py  # MIDI bridge utility
β”œβ”€β”€ *.md                    # Shared documentation
└── WEBAPP_README.md        # WebApp guide

Platform: Any modern web browser
Features: Full algorithm reference, interactive UI
Status: βœ… Stable reference implementation

Quick Start

# Navigate to plugin directory
cd Plugin/

# Open JUCE project
open RhythmPatternExplorer.jucer

# Build and install (see Plugin/README.md for details)

Using the Web App (For Development/Reference)

# Option 1: Use WebApp directory (recommended)
cd WebApp/
python3 serve-app.py

# Option 2: Use legacy app/ link (backward compatibility)
cd app/
python3 -m http.server 8000

# Open browser to http://localhost:8080 or http://localhost:8000

Core Features

Pattern Generation Algorithms

Progressive Transformations

UPI (Universal Pattern Input) Notation

E(3,8)                    # Basic Euclidean: 10010010
E(1,8)E>8                 # Progressive: 1β†’11111111
E(8,8)B>1                 # Barlow dilution: 11111111β†’10000000
P(5,12,0)                 # Pentagon rhythm
E(3,8)+P(5,12)           # Pattern combination
E(3,8)*P(5,12)           # Pattern multiplication
R(4,8,42)                # Random with seed

Implementation Relationship

WebApp (JavaScript)          Plugin (C++)
      ↓                          ↑
 Reference Algorithms    ←    Ported Algorithms
      ↓                          ↑
   Browser Testing       ←    DAW Integration
      ↓                          ↑
 Algorithm Validation    ←    Performance Testing

The WebApp serves as the reference implementation - all algorithms are first developed and validated in the browser, then ported to the Plugin for professional music production use.

Documentation

Shared Documentation (in WebApp/)

Plugin-Specific (in Plugin/)

WebApp-Specific (in WebApp/)

Development Workflow

Algorithm Development

  1. Prototype in WebApp (JavaScript)
  2. Validate algorithms and edge cases
  3. Port to Plugin (C++)
  4. Cross-validate outputs match
  5. Test in production environments

Testing Strategy

  1. WebApp: Browser-based algorithm validation
  2. Plugin: DAW integration testing
  3. Cross-validation: Ensure identical outputs
  4. Performance: Stress testing and benchmarks

Version History

Current: v0.02a (July 2024) - Major Timing Fixes Release

Key Milestones

Requirements

Plugin Development

WebApp Development

Installation

For Music Producers (Plugin)

# Quick install (if already built)
cp -R "Plugin/Builds/MacOSX/build/Release/Rhythm Pattern Explorer.component" ~/Library/Audio/Plug-Ins/Components/
cp -R "Plugin/Builds/MacOSX/build/Release/Rhythm Pattern Explorer.vst3" ~/Library/Audio/Plug-Ins/VST3/

For Developers (WebApp)

cd WebApp/app/
python3 -m http.server 8000
# Open http://localhost:8000

Compatibility

Plugin Hosts (Tested)

Browsers (WebApp)

Contributing

Code Organization

Algorithm Development

  1. Implement in WebApp first (easier debugging)
  2. Validate with comprehensive test cases
  3. Port to Plugin with identical behavior
  4. Cross-validate outputs between implementations

Research Foundation

Based on extensive research in:

Contact

License

[License information to be added]


Choose Your Platform: