{"id":912,"date":"2014-03-03T12:00:43","date_gmt":"2014-03-03T17:00:43","guid":{"rendered":"https:\/\/blogs.mathworks.com\/cleve\/?p=912"},"modified":"2014-03-15T13:49:38","modified_gmt":"2014-03-15T18:49:38","slug":"music-sparse-matrices-and-london-billboards","status":"publish","type":"post","link":"https:\/\/blogs.mathworks.com\/cleve\/2014\/03\/03\/music-sparse-matrices-and-london-billboards\/","title":{"rendered":"Music, Sparse Matrices, and London Billboards"},"content":{"rendered":"<div class=\"content\"><!--introduction--><!--\/introduction--><h3>Contents<\/h3><div><ul><li><a href=\"#b5fcfe85-13e7-43df-ae8b-456be09e2376\">Tim Davis<\/a><\/li><li><a href=\"#b7b1f3e2-8c98-41e1-97d6-d4632c4561c7\">Sparse Matrix Visualizations<\/a><\/li><li><a href=\"#6162cc8d-9772-45d3-a67d-ff3f6742d536\">Music Visualizations<\/a><\/li><li><a href=\"#0c737f49-4892-48f2-a3dc-685db8e66f4a\">Metastaseis<\/a><\/li><li><a href=\"#cf836558-2d46-4f95-a6ee-7f824684600c\">Blue Monday<\/a><\/li><li><a href=\"#7334260b-7214-4353-8428-0be9454117e2\">Electrodoodle<\/a><\/li><li><a href=\"#468c8c38-9f26-4e07-aff8-da842087aa1e\">Morning Has Broken<\/a><\/li><li><a href=\"#48b92ee9-1a19-4ad3-843a-e831131ed9b2\">Bach Toccata and Fugue<\/a><\/li><li><a href=\"#2bfb7d80-cc7b-427c-89a9-8a486fa574d8\"><a href=\"http:\/\/notesartstudio.com\">NotesArt Studio<\/a><\/a><\/li><\/ul><\/div><h4>Tim Davis<a name=\"b5fcfe85-13e7-43df-ae8b-456be09e2376\"><\/a><\/h4><p>At the recent SIAM conference on Parallel Processing for Scientific Computing, I met my friend Tim Davis.  Tim is a professor at the University of Florida, a consultant to MathWorks, and author of many of the functions involved in MATLAB sparse matrix calculations.  One of his hobbies involves the use of sparse matrices to translate music into visual art.<\/p><h4>Sparse Matrix Visualizations<a name=\"b7b1f3e2-8c98-41e1-97d6-d4632c4561c7\"><\/a><\/h4><p>Tim maintains the <a href=\"http:\/\/www.cise.ufl.edu\/research\/sparse\/matrices\">University of Florida Sparse Matrix Collection<\/a>, which he and others use to test their sparse matrix algorithms.  The collection includes web pages of beautiful visualizations of the sparse matrices created by a package called <a href=\"http:\/\/www.graphviz.org\">Graphviz<\/a>.<\/p><p>A London design agency saw the images, and contacted Tim to see if music could be visualized.  Tim hadn't done music before, but agreed to give it a try.  The agency liked what they saw, and commissioned Tim to do the artwork for the <a href=\"http:\/\/leaflondon.net\">London Electronic Arts Festival<\/a> held last November.  His artwork appeared as the theme artwork for LEAF 2013, appearing on posters and billboards around London last fall, and still appears as the background on the agency's web page today.<\/p><h4>Music Visualizations<a name=\"6162cc8d-9772-45d3-a67d-ff3f6742d536\"><\/a><\/h4><p>To produce this art, Tim created an algorithm in MATLAB which processes the music via the FFT and then translates the frequencies into a MATLAB sparse matrix.  The matrix is then drawn via Graphviz, a force-directed graph visualization package.  To generate the visualization, Graphviz places electrical charges on the nodes and springs on the edges, and then does a physics simulation to find a low-energy state.  The color reflects the notes, where low frequencies are blue and high ones are red, using the MATLAB jet colormap.<\/p><h4>Metastaseis<a name=\"0c737f49-4892-48f2-a3dc-685db8e66f4a\"><\/a><\/h4><p><img decoding=\"async\" vspace=\"5\" hspace=\"5\" src=\"https:\/\/blogs.mathworks.com\/images\/cleve\/Metastaseis.png\" alt=\"\"> <\/p><p><a href=\"http:\/\/notesartstudio.com\/metastaseis.html\">Link to gallery image.<\/a> <a href=\"http:\/\/www.amazon.com\/gp\/product\/B00BURK0UW\/ref=dm_ws_sp_tlw_trk1_B00BURK0UW\">Link to music.<\/a><\/p><p>Metastaseis is a complex orchestral piece by <a href=\"http:\/\/en.wikipedia.org\/wiki\/Iannis_Xenakis\">Iannis Xenakis<\/a>, a composer and architect who translated his architectural thoughts of space and structure into music, relying heavily on mathematics and algorithms.  In Xenakis' preliminary sketches for Metastaseis, lines and their intersection in space form hyperbolic paraboloids, which he translated into musical notes and chords. Xenakis described his process as \"vision -&gt; rules -&gt; works of art.\" He describes an inverse path as \"rules -&gt; vision.\" Tim's visualization completes Xenakis' inverse path by using algorithms to create visual artwork from Xenakis' music.<\/p><h4>Blue Monday<a name=\"cf836558-2d46-4f95-a6ee-7f824684600c\"><\/a><\/h4><p><img decoding=\"async\" vspace=\"5\" hspace=\"5\" src=\"https:\/\/blogs.mathworks.com\/images\/cleve\/Blue_Monday.png\" alt=\"\"> <\/p><p><a href=\"http:\/\/notesartstudio.com\/blue-monday.html\">Link to gallery image.<\/a> <a href=\"http:\/\/www.amazon.com\/Blue-Monday-2011-Total-Version\/dp\/B0057U1ESK\">Link to music.<\/a><\/p><p>Blue Monday is by <a href=\"http:\/\/en.wikipedia.org\/wiki\/New_Order\">New Order<\/a>, a British rock band that combines new wave and electronic dance music. Tim's rules do not specify \"build a mesh here.\" Instead, mesh-like structures arise because of the repetitive bass notes that appear in electronic music.<\/p><h4>Electrodoodle<a name=\"7334260b-7214-4353-8428-0be9454117e2\"><\/a><\/h4><p><img decoding=\"async\" vspace=\"5\" hspace=\"5\" src=\"https:\/\/blogs.mathworks.com\/images\/cleve\/Electrodoodle.png\" alt=\"\"> <\/p><p><a href=\"http:\/\/notesartstudio.com\/electrodoodle.html\">Link to gallery image and music.<\/a><\/p><p>Electrodoodle is a piece of electronic music by <a href=\"http:\/\/en.wikipedia.org\/wiki\/Kevin_MacLeod_(composer)\">Kevin Macleod<\/a>. Like Blue Monday, this piece of music has lots of deep repetitive bass notes.<\/p><h4>Morning Has Broken<a name=\"468c8c38-9f26-4e07-aff8-da842087aa1e\"><\/a><\/h4><p><img decoding=\"async\" vspace=\"5\" hspace=\"5\" src=\"https:\/\/blogs.mathworks.com\/images\/cleve\/MorningHasBroken.png\" alt=\"\"> <\/p><p><a href=\"http:\/\/notesartstudio.com\/morning-has-broken.html\">Link to gallery image.<\/a> <a href=\"http:\/\/www.amazon.com\/Morning-Has-Broken\/dp\/B000W0AFDA\">Link to music.<\/a><\/p><p>Morning Has Broken is a hymn written in 1931 by <a href=\"http:\/\/en.wikipedia.org\/wiki\/Eleanor_Farjeon\">Eleanor Farjeon<\/a> who set it to an old Gaelic tune.  This version is arranged and performed by <a href=\"http:\/\/en.wikipedia.org\/wiki\/Cat_Stevens\">Cat Stevens<\/a>. Tim created this piece for Iain and Di Duff.  Iain's work appears in MATLAB as the algorithms underlying LDL and backslash when A is sparse and symmetric indefinite.<\/p><h4>Bach Toccata and Fugue<a name=\"48b92ee9-1a19-4ad3-843a-e831131ed9b2\"><\/a><\/h4><p><img decoding=\"async\" vspace=\"5\" hspace=\"5\" src=\"https:\/\/blogs.mathworks.com\/images\/cleve\/Bach.png\" alt=\"\"> <\/p><p><a href=\"http:\/\/notesartstudio.com\/tocatta-and-fugue.html\">Link to gallery image and music.<\/a><\/p><p>Tim's visualization of Bach's <a href=\"http:\/\/en.wikipedia.org\/wiki\/BWV565\">Toccata and Fugue in D minor (BWV565)<\/a> reflects the tensions in this complex orchestral piece.<\/p><h4><a href=\"http:\/\/notesartstudio.com\">NotesArt Studio<\/a><a name=\"2bfb7d80-cc7b-427c-89a9-8a486fa574d8\"><\/a><\/h4><p>All these images are reproduced here with Tim Davis's permission and may not be copied.  For many more images and information about Tim's work, see <a href=\"http:\/\/notesartstudio.com\">NotesArtStudio.com<\/a>.<\/p><script language=\"JavaScript\"> <!-- \r\n    function grabCode_8100aef97391478ba56d1671a95d8133() {\r\n        \/\/ Remember the title so we can use it in the new page\r\n        title = document.title;\r\n\r\n        \/\/ Break up these strings so that their presence\r\n        \/\/ in the Javascript doesn't mess up the search for\r\n        \/\/ the MATLAB code.\r\n        t1='8100aef97391478ba56d1671a95d8133 ' + '##### ' + 'SOURCE BEGIN' + ' #####';\r\n        t2='##### ' + 'SOURCE END' + ' #####' + ' 8100aef97391478ba56d1671a95d8133';\r\n    \r\n        b=document.getElementsByTagName('body')[0];\r\n        i1=b.innerHTML.indexOf(t1)+t1.length;\r\n        i2=b.innerHTML.indexOf(t2);\r\n \r\n        code_string = b.innerHTML.substring(i1, i2);\r\n        code_string = code_string.replace(\/REPLACE_WITH_DASH_DASH\/g,'--');\r\n\r\n        \/\/ Use \/x3C\/g instead of the less-than character to avoid errors \r\n        \/\/ in the XML parser.\r\n        \/\/ Use '\\x26#60;' instead of '<' so that the XML parser\r\n        \/\/ doesn't go ahead and substitute the less-than character. \r\n        code_string = code_string.replace(\/\\x3C\/g, '\\x26#60;');\r\n\r\n        copyright = 'Copyright 2014 The MathWorks, Inc.';\r\n\r\n        w = window.open();\r\n        d = w.document;\r\n        d.write('<pre>\\n');\r\n        d.write(code_string);\r\n\r\n        \/\/ Add copyright line at the bottom if specified.\r\n        if (copyright.length > 0) {\r\n            d.writeln('');\r\n            d.writeln('%%');\r\n            if (copyright.length > 0) {\r\n                d.writeln('% _' + copyright + '_');\r\n            }\r\n        }\r\n\r\n        d.write('<\/pre>\\n');\r\n\r\n        d.title = title + ' (MATLAB code)';\r\n        d.close();\r\n    }   \r\n     --> <\/script><p style=\"text-align: right; font-size: xx-small; font-weight:lighter;   font-style: italic; color: gray\"><br><a href=\"javascript:grabCode_8100aef97391478ba56d1671a95d8133()\"><span style=\"font-size: x-small;        font-style: italic;\">Get \r\n      the MATLAB code <noscript>(requires JavaScript)<\/noscript><\/span><\/a><br><br>\r\n      Published with MATLAB&reg; R2014a<br><\/p><p class=\"footer\"><br>\r\n      Published with MATLAB&reg; R2014a<br><\/p><\/div><!--\r\n8100aef97391478ba56d1671a95d8133 ##### SOURCE BEGIN #####\r\n%% Music, Sparse Matrices, and London Billboards\r\n%% Tim Davis\r\n% At the recent SIAM conference on Parallel Processing for Scientific Computing,\r\n% I met my friend Tim Davis.  Tim is a professor at the University of Florida,\r\n% a consultant to MathWorks, and author of many of the functions involved in\r\n% MATLAB sparse matrix calculations.  One of his hobbies involves the use of\r\n% sparse matrices to translate music into visual art.\r\n\r\n%% Sparse Matrix Visualizations\r\n% Tim maintains the <http:\/\/www.cise.ufl.edu\/research\/sparse\/matrices\r\n% University of Florida Sparse Matrix Collection>, which he and others\r\n% use to test their sparse matrix algorithms.  The collection includes web\r\n% pages of beautiful visualizations of the sparse matrices created by a\r\n% package called <http:\/\/www.graphviz.org Graphviz>.\r\n\r\n%%\r\n% A London design agency saw the images, and contacted Tim to see if music\r\n% could be visualized.  Tim hadn't done music before, but agreed to give it\r\n% a try.  The agency liked what they saw, and commissioned Tim to do the artwork\r\n% for the <http:\/\/leaflondon.net London Electronic Arts Festival>\r\n% held last November.  His artwork appeared as the theme artwork for LEAF 2013,\r\n% appearing on posters and billboards around London last fall, and still\r\n% appears as the background on the agency's web page today.\r\n\r\n%% Music Visualizations\r\n% To produce this art, Tim created an algorithm in MATLAB which processes the\r\n% music via the FFT and then translates the frequencies into a MATLAB sparse\r\n% matrix.  The matrix is then drawn via Graphviz, a force-directed graph\r\n% visualization package.  To generate the visualization, Graphviz places\r\n% electrical charges on the nodes and springs on the edges, and then does a\r\n% physics simulation to find a low-energy state.  The color reflects the notes,\r\n% where low frequencies are blue and high ones are red, using the MATLAB\r\n% jet colormap.\r\n\r\n%% Metastaseis\r\n%\r\n% <<Metastaseis.png>>\r\n%\r\n% <http:\/\/notesartstudio.com\/metastaseis.html\r\n% Link to gallery image.>\r\n% <http:\/\/www.amazon.com\/gp\/product\/B00BURK0UW\/ref=dm_ws_sp_tlw_trk1_B00BURK0UW\r\n% Link to music.>\r\n\r\n%%\r\n% Metastaseis is a complex orchestral piece by\r\n% <http:\/\/en.wikipedia.org\/wiki\/Iannis_Xenakis Iannis Xenakis>,\r\n% a composer and architect who translated his\r\n% architectural thoughts of space and structure into music, relying heavily on\r\n% mathematics and algorithms.  In Xenakis' preliminary sketches for Metastaseis,\r\n% lines and their intersection in space form hyperbolic paraboloids, which he\r\n% translated into musical notes and chords. Xenakis described his process as\r\n% \"vision -> rules -> works of art.\" He describes an inverse path as \"rules ->\r\n% vision.\" Tim's visualization completes Xenakis' inverse path by using\r\n% algorithms to create visual artwork from Xenakis' music.\r\n\r\n%% Blue Monday\r\n%\r\n% <<Blue_Monday.png>>\r\n%\r\n% <http:\/\/notesartstudio.com\/blue-monday.html\r\n% Link to gallery image.>\r\n% <http:\/\/www.amazon.com\/Blue-Monday-2011-Total-Version\/dp\/B0057U1ESK\r\n% Link to music.>\r\n\r\n%%\r\n% Blue Monday is by <http:\/\/en.wikipedia.org\/wiki\/New_Order New Order>,\r\n% a British rock band that combines new wave and electronic dance music.\r\n% Tim's rules do not specify \"build a mesh here.\" Instead, mesh-like structures\r\n% arise because of the repetitive bass notes that appear in electronic music.\r\n\r\n%% Electrodoodle\r\n%\r\n% <<Electrodoodle.png>>\r\n% \r\n% <http:\/\/notesartstudio.com\/electrodoodle.html \r\n% Link to gallery image and music.>\r\n\r\n%%\r\n% Electrodoodle is a piece of electronic music by\r\n% <http:\/\/en.wikipedia.org\/wiki\/Kevin_MacLeod_(composer) Kevin Macleod>.\r\n% Like Blue Monday, this piece of music has lots of deep repetitive bass notes.\r\n\r\n%% Morning Has Broken\r\n%\r\n% <<MorningHasBroken.png>>\r\n%\r\n% <http:\/\/notesartstudio.com\/morning-has-broken.html \r\n% Link to gallery image.>\r\n% <http:\/\/www.amazon.com\/Morning-Has-Broken\/dp\/B000W0AFDA\r\n% Link to music.>\r\n\r\n%% \r\n% Morning Has Broken is a hymn written in 1931 by\r\n% <http:\/\/en.wikipedia.org\/wiki\/Eleanor_Farjeon Eleanor Farjeon> who set it\r\n% to an old Gaelic tune.  This version is arranged and performed by \r\n% <http:\/\/en.wikipedia.org\/wiki\/Cat_Stevens Cat Stevens>.\r\n% Tim created this piece for Iain and Di Duff.  Iain's work appears in MATLAB\r\n% as the algorithms underlying LDL and backslash when A is sparse and\r\n% symmetric indefinite.\r\n\r\n%% Bach Toccata and Fugue\r\n%\r\n% <<Bach.png>>\r\n%\r\n% <http:\/\/notesartstudio.com\/tocatta-and-fugue.html\r\n% Link to gallery image and music.>\r\n\r\n%%\r\n% Tim's visualization of Bach's\r\n% <http:\/\/en.wikipedia.org\/wiki\/BWV565 Toccata and Fugue in D minor (BWV565)>\r\n% reflects the tensions in this complex orchestral piece.\r\n\r\n%% <http:\/\/notesartstudio.com NotesArt Studio>\r\n% All these images are reproduced here with Tim Davis's permission and may\r\n% not be copied.  For many more images and information about Tim's work, see\r\n% <http:\/\/notesartstudio.com NotesArtStudio.com>.\r\n\r\n\r\n##### SOURCE END ##### 8100aef97391478ba56d1671a95d8133\r\n-->","protected":false},"excerpt":{"rendered":"<div class=\"overview-image\"><img decoding=\"async\"  class=\"img-responsive\" src=\"https:\/\/blogs.mathworks.com\/images\/cleve\/Metastaseis.png\" onError=\"this.style.display ='none';\" \/><\/div><p>ContentsTim DavisSparse Matrix VisualizationsMusic VisualizationsMetastaseisBlue MondayElectrodoodleMorning Has BrokenBach Toccata and FugueNotesArt StudioTim DavisAt the recent SIAM conference on... <a class=\"read-more\" href=\"https:\/\/blogs.mathworks.com\/cleve\/2014\/03\/03\/music-sparse-matrices-and-london-billboards\/\">read more >><\/a><\/p>","protected":false},"author":78,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[5,23,6,22,8],"tags":[],"_links":{"self":[{"href":"https:\/\/blogs.mathworks.com\/cleve\/wp-json\/wp\/v2\/posts\/912"}],"collection":[{"href":"https:\/\/blogs.mathworks.com\/cleve\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blogs.mathworks.com\/cleve\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.mathworks.com\/cleve\/wp-json\/wp\/v2\/users\/78"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.mathworks.com\/cleve\/wp-json\/wp\/v2\/comments?post=912"}],"version-history":[{"count":12,"href":"https:\/\/blogs.mathworks.com\/cleve\/wp-json\/wp\/v2\/posts\/912\/revisions"}],"predecessor-version":[{"id":934,"href":"https:\/\/blogs.mathworks.com\/cleve\/wp-json\/wp\/v2\/posts\/912\/revisions\/934"}],"wp:attachment":[{"href":"https:\/\/blogs.mathworks.com\/cleve\/wp-json\/wp\/v2\/media?parent=912"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blogs.mathworks.com\/cleve\/wp-json\/wp\/v2\/categories?post=912"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blogs.mathworks.com\/cleve\/wp-json\/wp\/v2\/tags?post=912"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}