PlayTune
by Alan Tan
16 Jun 2006
(Updated 21 Jul 2006)
No BSD License
This function plays musical tunes. Write your own musical tune and call the function to play it.
Download Now
|
Watch this File
|
| File Information |
| Description |
This function plays musical tunes. Write your own musical tune and call the function to play it.
Notation:
[CDEFGAB] keys, 5 full octaves
[12345678] key/rest duration, with the default [1] semiquaver, [2] quaver, [4] crochet and [8] minim
[#] sharp / [b] flat / [.] rest / [^] raise octave / [_] lower octave
The musical scores for Canon in D (Pachelbel), Prelude No 1 (Bach), The Globe Trotter and Fantasie Impromptu (Chopin) are also attached.
Essential files: playtune.m
Accompanying files: canon_in_d.m, prelude_no_1.m, the_globe_trotter.m, fantasie_impromptu.m |
| MATLAB release |
MATLAB 5.3.1 (R11.1)
|
| Zip File Content |
|
| Other Files |
canon_in_d.m, prelude_no_1.m, the_globe_trotter.m, fantasie_impromptu.m, playtune.m
|
|
Tags for This File
|
| Everyone's Tags |
|
| Tags I've Applied |
|
| Add New Tags |
Please login to tag files.
|
| Comments and Ratings (5) |
| 28 Jun 2006 |
John D'Errico
|
|
|
| 29 Jun 2006 |
Alan Tan
|
|
|
| 20 Sep 2006 |
S Murphy
|
|
|
| 18 Apr 2007 |
Ruoting Yang
|
|
|
| 26 Oct 2008 |
Ameya Deoras
|
|
|
| Updates |
| 20 Jun 2006 |
Edited the function for a more natural sounding tone. |
| 21 Jun 2006 |
Added residual phase to generating signals. |
| 22 Jun 2006 |
Added the musical score of Prelude No 1 by Bach. |
| 27 Jun 2006 |
Enabled customizable tone generator; at the same time, set the lowest note to C(-2), i.e., two octaves below the middle C of the piano. Also added a new musical score "The Globe Trotter" which plays both right and left hands. |
| 27 Jun 2006 |
Tidied up the codes. |
| 28 Jun 2006 |
Edited description. |
| 29 Jun 2006 |
Added additional help and examples in playtune. |
| 21 Jul 2006 |
Added Fantasie Impromptu (plays both hands), one of my favorite pieces by Chopin. |
|
MATLAB Central Terms of Use
NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for
all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content.
Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available
via MATLAB Central.
Read the complete Terms prior to use.
Contact us at files@mathworks.com