Creating Rhythms - cover image

Subscribe to our newsletter and we'll email you a 50 % off coupon for one ebook.

* indicates required

Back to Abrazol.com

Creating Rhythms


By
Stefan Hollos, and J. Richard Hollos

Format and pricing:
paperback (113 pages) $14.95, Kindle/pdf $9.95
ISBN: 9781887187220 (paperback), 9781887187237 (ebook)
Publication date: Feb 2014

This book is the result of a lifelong love of music and an obsession with patterns. The authors have for many years been exploring methods to find, create, describe and analyze patterns. They wrote this book to show how some of these methods can be used to generate rhythms. The methods can produce an almost endless variety of new rhythms along with popular traditional ones. For a lover of music what could be more wonderful than that?

The study of patterns at anything beyond a superficial level does require some mathematics. Fortunately the mathematics can be kept at a very elementary level. Anyone comfortable with a little algebra should have no trouble understanding and using these rhythm generation methods. Only the last chapter on stochastic rhythms requires a bit more than elementary mathematics. Any reader who faints at the sight of an equation should probably not buy the book.

The book has many example rhythms for which there are MIDI files that you can listen to here. If you're reading an ebook version, there are individual links to the MIDI files. There is a MIDI player for every major operating system. A good free one is TiMidity.

Accompanying this book are free command-line programs for doing calculations and creating rhythms. The programs are written in the C programming language, and will have to be compiled before you can use them. You do not have to know C to use the programs or understand the contents of the book. There is a C language compiler for every major operating system. A good one that is also free is gcc. There is nothing operating system specific about any of the programs, so you should have no problems compiling them on any computer.

You can get this book now at Amazon.

Amazon buy button

You can also get this book instantly as a pdf from Gumroad where you will be able to download it immediately after purchase.

Buy pdf

About the authors: Stefan Hollos and J. Richard Hollos are physicists by training, and enjoy anything related to math, physics, and computing. They are the authors of Pattern Generation for Computational Art, Finite Automata and Regular Expressions: Problems and Solutions, Probability Problems and Solutions, Combinatorics Problems and Solutions, The Coin Toss: Probabilities and Patterns, Bet Smart: The Kelly System for Gambling and Investing, as well as Simple Trading Strategies That Work and Pairs Trading: A Bayesian Example, and are brothers and business partners at Exstrom Laboratories LLC in Longmont, Colorado. The websites for their work are Exstrom.com and QuantWolf.com.

Table of Contents

Software

Below are the C programs that accompany the book. You can download each as you need it, or all of them bundled into a zip file.

This software is free and distributed under the terms of the GNU General Public License. It is written in ANSI C and should compile with any C compiler. If you have questions or comments contact: Stefan (stefan at exstrom dot com) or Richard (richard at exstrom dot com).

Converting Binary Rhythms to MIDI

Here is a quick way to make a midi file, given rhythms in binary notation.

Let's say you want to hear the following two instrument binary rhythm set:

1111010110010000   Low Bongo
1000011110101100   High Bongo

Our procedure is to first convert the binary rhythm set to abc notation, then convert the resulting abc file to MIDI. To go from the binary rhythm set to abc notation we use our program bdrum.c which reads a binary rhythm definition file and sends the equivalent abc notation to standard output. In our example above, the input binary rhythm definition file would look like the following:

480 16 2
61 1111010110010000
60 1000011110101100

where 480 is the tempo (notes/minute), 16 is the number of notes per rhythm, 2 is the number of rhythms, 61 is the MIDI percussion instrument number for low bongo, and 60 is high bongo. So if our binary rhythm definition file is called b1.bdf then we run bdrum as follows:

./bdrum b1.bdf 4

where the number 4 specifies that the rhythm set is repeated 4 times. The result is an abc notation file that can be converted to MIDI with the program abc2midi (part of the abcMIDI package). The resulting MIDI file can be played by a program like TiMidity. You can listen to the above example here. All this can be done in one command line as follows:

./bdrum b1.bdf 4 > b1.abc;abc2midi b1.abc -o b1.mid;timidity -in b1.mid

Note the above command line works in the bash shell. In Linux and Mac OS X it should work with no problem (bash is the default shell in most Linux distros and OS X). On windows, you can get the bash shell by installing MinGW or Cygwin.


Send comments to: Richard Hollos (richard[AT]exstrom DOT com)
Copyright 2014 by Exstrom Laboratories LLC