ebook img

Automated Harmonisation of a Melody into a Four Part Barbershop Arrangement PDF

141 Pages·2005·0.73 MB·English
by  
Save to my drive
Quick download
Download
Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.

Preview Automated Harmonisation of a Melody into a Four Part Barbershop Arrangement

Automated Harmonisation of a Melody into a Four Part Barbershop Arrangement Steve Roberts BSc (Hons) in Computer Information Systems 2005 i Automated Harmonisation of a Melody into a Four Part Barbershop Arrangement Submitted by Steve Roberts COPYRIGHT Attentionisdrawntothefactthatcopyrightofthisthesisrestswithitsauthor. TheIntellectualPropertyRightsoftheproductsproducedaspartoftheproject belongtotheUniversityofBath(seehttp://www.bath.ac.uk/ordinances/#intelprop). Thiscopyofthethesishasbeensuppliedonconditionthatanyonewhoconsults itisunderstoodtorecognisethatitscopyrightrestswithitsauthorandthatno quotation from the thesis and no information derived from it may be published without the prior written consent of the author. Declaration This dissertation is submitted to the University of Bath in accordance with the requirements of the degree of Batchelor of Science in the Department of Com- puter Science. No portion of the work in this dissertation has been submitted in support of an application for any other degree or qualification of this or any other university or institution of learning. Except where specifically acknowl- edged, it is the work of the author. Signed: Abstract The domain of algorithmic composition has been combined with many music styles in the past, but not barbershop. This project aims to draw together barbershop and algorithmic harmonisation and fuse them in an investigation as to whether a fundamentally creative process can be formalised into rules. It uses knowledge of existing barbershop arrangement practices and existing rules in order to create arrangements from a melody input. A system was produced based on testing possible chords and voicings against rulesthatwerehardcoded. Thisfunctionalitywassplitdownintoidentifyingthe chords then voicing them. The latter function proved to be successful; however the implementation of the former was naive and did not produce arrangements of a professional standard. Theconclusiondrawnfromthisworkisthatalthoughitispossibletoformalise the creative process into rules, it does not yield ‘good’ arrangements. Rules are not enough on their own to create a good arrangement as experience from previous arranging will influence the arranger when approaching a melody. i Acknowledgements For guidance throughout the project: Professor J. Fitch For moral support througout: Meri Williams For showing an interest in the research and evaluating the outputs: Rick Spencer (SPEBSQSA) John Wiggins (BABS) Mike Lofthouse (BABS) The Rivertones The Alley Barbers Robin Jackson For getting me started with initial pointers: Neil Watkins (BABS) For being someone to measure progress against and exchange knowledge of Csound and Lilypond: Paul Morris For proof–reading the drafts: Anne Roberts Anna Skeoch Caroline Reay Dedicated in Memory of Steve Hall Contents 1 Problem Identification 1 2 Background and Previous Work 3 2.1 Literature search definition . . . . . . . . . . . . . . . . . . . . . 3 2.2 Arranging barbershop music . . . . . . . . . . . . . . . . . . . . . 3 2.2.1 Introduction to the style . . . . . . . . . . . . . . . . . . . 3 2.2.2 Arranging method one . . . . . . . . . . . . . . . . . . . . 4 2.2.3 Arranging method two . . . . . . . . . . . . . . . . . . . . 5 2.2.4 Arranging method three . . . . . . . . . . . . . . . . . . . 6 2.2.5 Analysis of arranging methods . . . . . . . . . . . . . . . 6 2.3 Music and computers. . . . . . . . . . . . . . . . . . . . . . . . . 7 2.3.1 Representing music in computers . . . . . . . . . . . . . . 7 2.3.2 Input and output of computer music . . . . . . . . . . . . 8 2.4 Algorithmic composition . . . . . . . . . . . . . . . . . . . . . . . 9 2.4.1 Rule-based composition . . . . . . . . . . . . . . . . . . . 9 2.4.2 Genetic Algorithms in composition . . . . . . . . . . . . . 10 2.4.3 A comparison between these two approaches . . . . . . . 11 2.5 How these subjects are related . . . . . . . . . . . . . . . . . . . 11 3 Solutions Considered 13 3.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 3.2 The tasks to be completed . . . . . . . . . . . . . . . . . . . . . . 13 3.2.1 Inputting a melody into the computer . . . . . . . . . . . 14 3.2.2 Adding primary harmonies to the melody . . . . . . . . . 14 3.2.3 Voicing the harmonies for four voices . . . . . . . . . . . . 15 3.2.4 Adding typical barbershop embellishments. . . . . . . . . 16 3.2.5 Outputting the arrangement . . . . . . . . . . . . . . . . 16 3.3 Initial conclusions . . . . . . . . . . . . . . . . . . . . . . . . . . 16 4 Chosen Solution 18 4.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 4.2 Data Representation . . . . . . . . . . . . . . . . . . . . . . . . . 19 4.3 Data structures . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 4.3.1 The score . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 4.3.2 Circle of Fifths . . . . . . . . . . . . . . . . . . . . . . . . 20 4.3.3 Voicing comparison. . . . . . . . . . . . . . . . . . . . . . 21 4.3.4 Lookup table of every 4-part chord . . . . . . . . . . . . . 21 4.4 Processes + Techniques . . . . . . . . . . . . . . . . . . . . . . . 23 ii CONTENTS iii 4.4.1 Translating input into the representation . . . . . . . . . 23 4.4.2 Adding primary harmonies . . . . . . . . . . . . . . . . . 23 4.4.3 Voicing the harmonies . . . . . . . . . . . . . . . . . . . . 24 4.4.4 Outputting to Lilypond . . . . . . . . . . . . . . . . . . . 25 4.4.5 Outputting to Csound . . . . . . . . . . . . . . . . . . . . 25 5 Implementation 26 5.1 The flow through the program . . . . . . . . . . . . . . . . . . . 26 5.2 Details of the function algorithms . . . . . . . . . . . . . . . . . . 27 5.2.1 Creating and populating the score . . . . . . . . . . . . . 27 5.2.2 Harmonising the melody . . . . . . . . . . . . . . . . . . . 27 5.2.3 Voicing the harmonies . . . . . . . . . . . . . . . . . . . . 27 5.2.4 Creating a Lilypond output . . . . . . . . . . . . . . . . . 28 5.2.5 Creating a Csound output . . . . . . . . . . . . . . . . . . 28 5.3 Decisions made and deviations from chosen solution . . . . . . . 28 5.3.1 Alterations to the data structures. . . . . . . . . . . . . . 28 5.3.2 Inputting of the melody . . . . . . . . . . . . . . . . . . . 30 5.3.3 Process for extracting the primary harmonies . . . . . . . 30 5.3.4 Audio Output. . . . . . . . . . . . . . . . . . . . . . . . . 31 5.3.5 Musical decisions . . . . . . . . . . . . . . . . . . . . . . . 32 5.4 Problems encountered . . . . . . . . . . . . . . . . . . . . . . . . 33 5.4.1 Problems with octaves . . . . . . . . . . . . . . . . . . . . 33 5.4.2 Problems with the harmonic rhythm . . . . . . . . . . . . 34 6 Conclusions from solutions 35 6.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 6.2 Evaluation of the representation . . . . . . . . . . . . . . . . . . 35 6.3 Evaluation of the main functions . . . . . . . . . . . . . . . . . . 36 6.3.1 Voicing of the harmonies. . . . . . . . . . . . . . . . . . . 37 6.3.2 Identifying the primary harmonies . . . . . . . . . . . . . 38 6.4 Evaluation of the general methods . . . . . . . . . . . . . . . . . 39 6.4.1 Rules or learning . . . . . . . . . . . . . . . . . . . . . . . 40 6.4.2 Backtracking . . . . . . . . . . . . . . . . . . . . . . . . . 41 7 Critical appraisal and further work 42 7.1 Appraisal of the process . . . . . . . . . . . . . . . . . . . . . . . 42 7.1.1 Approach to the implementation . . . . . . . . . . . . . . 42 7.1.2 Unimplemented functionality . . . . . . . . . . . . . . . . 43 7.1.3 Further comments . . . . . . . . . . . . . . . . . . . . . . 44 7.2 Work that could build on this . . . . . . . . . . . . . . . . . . . . 45 7.2.1 Human/Agent intervention . . . . . . . . . . . . . . . . . 45 7.2.2 Extensions to the work . . . . . . . . . . . . . . . . . . . 45 7.2.3 New directions . . . . . . . . . . . . . . . . . . . . . . . . 46 A Methodology used for this project i A.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . i A.2 Requirements elicitation and analysis . . . . . . . . . . . . . . . . i A.2.1 Requirements elicitation . . . . . . . . . . . . . . . . . . . i A.2.2 Requirements Specification . . . . . . . . . . . . . . . . . ii A.2.3 Functional requirements . . . . . . . . . . . . . . . . . . . ii CONTENTS iv A.2.4 System requirements . . . . . . . . . . . . . . . . . . . . . iv A.2.5 Domain Requirements . . . . . . . . . . . . . . . . . . . . v A.3 Analytical testing . . . . . . . . . . . . . . . . . . . . . . . . . . . vi A.4 User testing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . vii B Input and Outputs viii B.1 Input to system . . . . . . . . . . . . . . . . . . . . . . . . . . . . viii B.2 Outputs from the voicing tests . . . . . . . . . . . . . . . . . . . viii B.3 Outputs from the primary harmony tests . . . . . . . . . . . . . ix C Program Code xi C.1 Libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xi C.1.1 AllChords.h . . . . . . . . . . . . . . . . . . . . . . . . . . xi C.1.2 AllChords.c . . . . . . . . . . . . . . . . . . . . . . . . . . xiii C.1.3 Chord.h . . . . . . . . . . . . . . . . . . . . . . . . . . . . xvi C.1.4 Chord.c . . . . . . . . . . . . . . . . . . . . . . . . . . . . xvii C.1.5 CircleFifths.h . . . . . . . . . . . . . . . . . . . . . . . . . xix C.1.6 CircleFifths.c . . . . . . . . . . . . . . . . . . . . . . . . . xx C.1.7 Compare.h . . . . . . . . . . . . . . . . . . . . . . . . . . xxvii C.1.8 Compare.c . . . . . . . . . . . . . . . . . . . . . . . . . . xxix C.1.9 Lookup.h . . . . . . . . . . . . . . . . . . . . . . . . . . . xxxvii C.1.10 Lookup.c . . . . . . . . . . . . . . . . . . . . . . . . . . . xxxviii C.1.11 Note.h . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xli C.1.12 Note.c . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xlii C.1.13 Pitches.h . . . . . . . . . . . . . . . . . . . . . . . . . . . xliii C.1.14 Pitches.c. . . . . . . . . . . . . . . . . . . . . . . . . . . . xliv C.1.15 Ratios.h . . . . . . . . . . . . . . . . . . . . . . . . . . . . xlvi C.1.16 Ratios.c . . . . . . . . . . . . . . . . . . . . . . . . . . . . xlvii C.1.17 Score.h . . . . . . . . . . . . . . . . . . . . . . . . . . . . l C.1.18 Score.c . . . . . . . . . . . . . . . . . . . . . . . . . . . . . lii C.2 Test code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . lxii C.2.1 AllChordsTest.c . . . . . . . . . . . . . . . . . . . . . . . lxii C.2.2 CircleFifthsTest.c . . . . . . . . . . . . . . . . . . . . . . . lxiii C.2.3 CircleFifthsTest2.c . . . . . . . . . . . . . . . . . . . . . . lxiv C.2.4 CircleFifthsTest3.c . . . . . . . . . . . . . . . . . . . . . . lxv C.2.5 CompareTest.c . . . . . . . . . . . . . . . . . . . . . . . . lxvi C.2.6 CompareTest2.c . . . . . . . . . . . . . . . . . . . . . . . lxvii C.2.7 CompareTest3.c . . . . . . . . . . . . . . . . . . . . . . . lxix C.2.8 CompareTest4.c . . . . . . . . . . . . . . . . . . . . . . . lxxi C.2.9 csound.h. . . . . . . . . . . . . . . . . . . . . . . . . . . . lxxiii C.2.10 input.ly . . . . . . . . . . . . . . . . . . . . . . . . . . . . lxxiv C.2.11 LookupTest.c . . . . . . . . . . . . . . . . . . . . . . . . . lxxv C.2.12 lpondlexer.h . . . . . . . . . . . . . . . . . . . . . . . . . . lxxvi C.2.13 lpondparser.c . . . . . . . . . . . . . . . . . . . . . . . . . lxxvii C.2.14 PitchesTest.c . . . . . . . . . . . . . . . . . . . . . . . . . lxxix C.2.15 RatiosTest.c . . . . . . . . . . . . . . . . . . . . . . . . . . lxxx C.2.16 ScoreTest.c . . . . . . . . . . . . . . . . . . . . . . . . . . lxxxi C.2.17 ScoreTest2.c. . . . . . . . . . . . . . . . . . . . . . . . . . lxxxiv Chapter 1 Problem Identification ‘Rock ‘n’ Roll had become stagnant. ‘Achy Breaky Heart’ was seven years away. Something had to fill the void, and that something was barbershop’ - Homer Simpson in ‘Homer’s Barbershop Quartet’ Algorithmic composition is the process of creating a piece of music using rules laid down by a human operator, but where the computer determines the notes and rhythms. The SPEBSQSA’s (Society for the Preservation and Encouragement of Barber Shop Quartet Singing in America) Contest and Judging Handbook defines bar- bershop as ‘...a style of unaccompanied vocal music characterized by consonant four-partchordsforeverymelodynoteinapredominantlyhomophonictexture’. Barbershop music is one of many styles where the harmonies are dictated by a set of rules. The origins of barbershop actually stem from the circle of fifths; a method of harmonisation that has been in use since the 16th Century. As the rules are so strictly defined for barbershop harmonies, the style lends itself to algorithmic composition, because the rules can be laid down by a human operator, whilst a computer can determine the details. Algorithmic composition is not a new concept, and existing projects have used this tool to generate music in the style of Bach, as well as using it for personal compositions. As such, there is no similar tool for arranging barbershop, there- fore,asmuchasthisisresearchintowhetherbarbershopmusiccanbearranged just through rules, it may also prove to be a tool for amateur arrangers. Automatedarrangementofbarbershophaspreviouslybeenattempted,butthis was20yearsagointhedaysofFORTRANandassembler. Morerecently, there have beenmany attempts at algorithmic composition andharmonisation, using a variety of methods. Thisproject includesaninvestigationinto possible methods ofalgorithmichar- monisation, with particular focus on three areas: 1 CHAPTER 1. PROBLEM IDENTIFICATION 2 • Backtracking through data structures • Analysis of existing pieces to build a knowledge base • Rule–based harmonisation The main task to be completed will be to create a program that will accept a melody as an input and add 3 harmony lines before outputting a barbershop arrangement. Withinthisprogram,therewillhavetobeprocedurestodealwith identifying the primary harmonies of the melody, voicing the harmonies (and possiblymovingthemelodytoadifferentvoice),ensuringthateachharmonyis amelodiclineinitsownright, andmakingsurethatthereisageneralcohesion to the piece. There will be outputs in the form of sheet music and an audio file. These will allow the output to be used as both a preview function (the audio), and will also in the future have the potential of producing sheet music. Chapter 2 Background and Previous Work ‘Learning music by reading about it is like making love by mail’ - Luciano Pavarotti 2.1 Literature search definition This literature review will be used to identify the key concepts within the project, bringing them together into one coherent entity. The concepts that are relevant, which will be researched are: • The style of barbershop • Representing music within a computer • Algorithmic composition These will then be brought together and links and dependencies between the subject areas will be identified. 2.2 Arranging barbershop music 2.2.1 Introduction to the style Barbershop originated from groups of men who would sing songs together in the19thCenturybyear. Initsformaldefinition,barbershopis‘unaccompanied vocal music characterized byconsonant four-part chords for every melodynote’ [18]. The four parts are: 3

Description:
uses knowledge of existing barbershop arrangement practices and existing rules in order to create arrangements from a melody input. A system was
See more

The list of books you might like

Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.