{"id":8400,"date":"2015-08-05T09:15:57","date_gmt":"2015-08-05T16:15:57","guid":{"rendered":"https:\/\/blog.digilentinc.com\/?p=8400"},"modified":"2015-08-04T16:08:23","modified_gmt":"2015-08-04T23:08:23","slug":"a-wonderland-of-fractals-with-the-nexys-video","status":"publish","type":"post","link":"https:\/\/digilent.com\/blog\/a-wonderland-of-fractals-with-the-nexys-video\/","title":{"rendered":"A Wonderland of Fractals with the Nexys Video"},"content":{"rendered":"<div id='gallery-1' class='gallery galleryid-8400 gallery-columns-3 gallery-size-thumbnail'><figure class='gallery-item'>\n\t\t\t<div class='gallery-icon landscape'>\n\t\t\t\t<a href='https:\/\/digilent.com\/blog\/a-wonderland-of-fractals-with-the-nexys-video\/hamster-real-time2-1\/'><img loading=\"lazy\" decoding=\"async\" width=\"150\" height=\"150\" src=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/08\/Hamster-Real-Time2-1-150x150.jpg\" class=\"attachment-thumbnail size-thumbnail\" alt=\"\" \/><\/a>\n\t\t\t<\/div><\/figure><figure class='gallery-item'>\n\t\t\t<div class='gallery-icon landscape'>\n\t\t\t\t<a href='https:\/\/digilent.com\/blog\/a-wonderland-of-fractals-with-the-nexys-video\/hamster-real-time-6-1\/'><img loading=\"lazy\" decoding=\"async\" width=\"150\" height=\"150\" src=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/08\/Hamster-Real-Time-6-1-150x150.jpg\" class=\"attachment-thumbnail size-thumbnail\" alt=\"\" \/><\/a>\n\t\t\t<\/div><\/figure><figure class='gallery-item'>\n\t\t\t<div class='gallery-icon landscape'>\n\t\t\t\t<a href='https:\/\/digilent.com\/blog\/a-wonderland-of-fractals-with-the-nexys-video\/hamster-real-time\/'><img loading=\"lazy\" decoding=\"async\" width=\"150\" height=\"150\" src=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/08\/Hamster-Real-Time-150x150.jpg\" class=\"attachment-thumbnail size-thumbnail\" alt=\"\" \/><\/a>\n\t\t\t<\/div><\/figure>\n\t\t<\/div>\n<p>Last week I was admiring Hamster&#8217;s project,\u00a0<a href=\"http:\/\/hamsterworks.co.nz\/mediawiki\/index.php\/Mandelbrot_NG_1080i\" target=\"_blank\">On the Fly Fractals<\/a>, which uses the <a href=\"https:\/\/digilent.com\/blog\/Products\/Detail.cfm?NavPath=2,719,1476&amp;Prod=NEXYS-VIDEO\" target=\"_blank\">Nexys Video<\/a> to calculate and view a fractal known as the Mandelbrot Set. I was struck by the random fluidity of the\u00a0fractals. In Hamster\u2019s words, &#8220;it has a sort of an organic quality,&#8221; and I agree. \u00a0There is a natural flow, making me feel as if I was somehow watching a living organism evolving.<\/p>\n<figure id=\"attachment_8838\" aria-describedby=\"caption-attachment-8838\" style=\"width: 770px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-8838\" src=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/fractal-1-cropped-600x223.jpg\" alt=\"fractal 1 cropped\" width=\"770\" height=\"286\" srcset=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/fractal-1-cropped-600x223.jpg 600w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/fractal-1-cropped-1024x380.jpg 1024w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/fractal-1-cropped-225x83.jpg 225w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/fractal-1-cropped-800x297.jpg 800w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/fractal-1-cropped.jpg 1324w\" sizes=\"auto, (max-width: 770px) 100vw, 770px\" \/><figcaption id=\"caption-attachment-8838\" class=\"wp-caption-text\">More\u00a0of the Mandelbrot fractal set.<\/figcaption><\/figure>\n<p>Gazing upon the changing shapes and colors nearly put me in a trance. \u00a0I found myself thinking of scenes from Disney&#8217;s Alice in Wonderland, which I used to watch with my two little girls. \u00a0Do you remember the &#8220;Eat Me&#8221; and &#8220;Drink Me&#8221; scenes when Alice is supersized to 9-feet tall and then shrinks to a tiny version of her former self? \u00a0Zooming in and pulling back from the fractals in the video, I questioned my perception of size, just as Alice did.<\/p>\n<p>While I watched the video, I imaged that I was standing on the green area, as if it was a field of tall soft grass. \u00a0As the video started to roll, I was\u00a0quickly whisked away into the ever-changing landscape of color, mountains rising\u00a0around me.\u00a0 I was\u00a0swept away. \u00a0I was\u00a0on a never-ending\u00a0staircase into an ever-changing landscape. \u00a0The shapes and colors enveloped me. \u00a0I was\u00a0Alice, somewhere in a fractal wonderland.<\/p>\n<p>Intrigued, I contacted Hamster and asked him if he could break down these marvelous images for me in a &#8220;non-technical manner.&#8221;\u00a0 I had to hear more about this project. Thankfully he obliged and here is his explanation of fractals:<\/p>\n<p>&#8220;For every point on the screen, it runs a recursive calculation, and then plots how many times this calculation can perform before the result exceeds a limiting value. This results in a self-similar object with an infinite level of detail &#8211; a fractal.&#8221;<\/p>\n<figure id=\"attachment_8839\" aria-describedby=\"caption-attachment-8839\" style=\"width: 782px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-8839 \" src=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/fractals-cropped-600x208.jpg\" alt=\"fractals cropped\" width=\"782\" height=\"271\" srcset=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/fractals-cropped-600x208.jpg 600w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/fractals-cropped-1024x355.jpg 1024w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/fractals-cropped-225x78.jpg 225w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/fractals-cropped-800x277.jpg 800w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/fractals-cropped.jpg 1263w\" sizes=\"auto, (max-width: 782px) 100vw, 782px\" \/><figcaption id=\"caption-attachment-8839\" class=\"wp-caption-text\">A quick Google search brought up many more images of fractals.<\/figcaption><\/figure>\n<p>Hanging on the words, &#8220;infinite level of detail,&#8221; I, like Alice, dove even farther down the rabbit hole. I wanted to know more.<\/p>\n<p>Wikipedia has a <a href=\"https:\/\/en.wikipedia.org\/wiki\/Mandelbrot_set\" target=\"_blank\">full explanation of the Mandelbrot set<\/a>. But, to put it simply, the Mandelbrot set is a set of complex numbers plotted on a standard x\/y plane. The equation fc(z)=z^2+c is applied recursively to every point on the plane and colored in accordance to the results. For some points, the results of iterating that equation approach infinity. Those points are given various colors based on how quickly they approach infinity. That is pretty technical, but bear with me. The important thing is actually the points which represent numbers that never approach infinity. Some numbers, when plugged into that equation and iterated, never get very far from zero (they stay between -2 and 2). Those points are colored black.<\/p>\n<p>Again, for a full explanation, see the <a href=\"https:\/\/en.wikipedia.org\/wiki\/Mandelbrot_set\" target=\"_blank\">Wikipedia page about the Mandelbrot set<\/a>.<\/p>\n<p>Hamster\u2019s project uses the <a href=\"https:\/\/digilent.com\/blog\/Products\/Detail.cfm?NavPath=2,719,1476&amp;Prod=NEXYS-VIDEO\" target=\"_blank\">Nexys Video<\/a> to calculate the Mandelbrot set and display it in HD in real time, which is really cool. In order to display this fractal in real time, the Nexys Video must perform around 120 billion operations per second.<\/p>\n<p>&nbsp;<\/p>\n<p><iframe loading=\"lazy\" width=\"735\" height=\"413\" src=\"https:\/\/www.youtube.com\/embed\/4fCQMh3WhB0?feature=oembed\" frameborder=\"0\" allow=\"autoplay; encrypted-media\" allowfullscreen><\/iframe><\/p>\n<p>&nbsp;<\/p>\n<p><em>Hamster explains: &#8220;As a rough idea to the range of numbers used, if the full image was the size of the continental USA, The level of magnification is equivalent to\u00a0zooming down to the\u00a0pixels on a HD 4&#8243; cell phone display.&#8221; <\/em><\/p>\n<p>I learned that the original inspiration for Hamster\u2019s project struck him in the mid-1980\u2019s. An article in the <a href=\"http:\/\/www.scientificamerican.com\/article\/mandelbrot-set\/\" target=\"_blank\">Scientific American magazine<\/a> featured a decidedly more &#8220;organic&#8221; feel to the fractals than what he had seen prior, and he liked it.<\/p>\n<p>&nbsp;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-8840 size-medium\" src=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/mandelbrot-article-600x467.png\" alt=\"mandelbrot article\" width=\"600\" height=\"467\" srcset=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/mandelbrot-article-600x467.png 600w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/mandelbrot-article-225x175.png 225w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/mandelbrot-article.png 623w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><\/p>\n<p>&nbsp;<\/p>\n<p>Hamster sought to design something similar and aspired to reach 158,630,400,000 calculations per second. (Wow!)<\/p>\n<p>As to his efforts on with the Mandlebrot set and his <a href=\"https:\/\/digilent.com\/blog\/Products\/Detail.cfm?NavPath=2,719,1476&amp;Prod=NEXYS-VIDEO\">Nexys Video<\/a>\u00a0board, Hamster humbly writes, &#8220;Sadly my design falls just short of the\u00a0158,630,400,000 calculations needed per second, but maybe someday I will get there!&#8221; I have no doubt he will.<\/p>\n<p>Breaking it down into numbers was a real eye-opener for me. \u00a0We&#8217;re talking about billions of calculations per second. Yes, billions! Below is what he shared with me in regards to understanding the vast scope of the numbers and calculations involved.<\/p>\n<p>1. If the full image was the size of the continental USA, The level of magnification is equivalent to\u00a0zooming down to the\u00a0pixels on a HD 4&#8243; cell phone display.<\/p>\n<p>2. The sheer magnitude of the calculations taking place is mind-boggling (just short of the\u00a0158,630,400,000 calculations per second).<\/p>\n<p>3. Each of these calculations requires 10 basic operations (3 multiplies, and other 7 basic operations (e.g. addition)), and usually people stop when the calculation has been repeated 255 times per pixel (as 255 is the maximum value that can be held in a single byte).<\/p>\n<p>4. Assuming that we are stopping at 255, it takes 2550 operations to calculate the color to display for each pixel on the screen, for a total of\u00a05,287,680,000 operations for all the pixels of a 1920&#215;1080 image.<\/p>\n<p>5. For smooth scrolling and zooming, every pixel has to be recalculated for every frame, and, when using 1080i video, there are 30 frames every second.<\/p>\n<p>Crazy cool project, Hamster!<\/p>\n<p>Hamster is an active member on our forum and a valued part of our open source community. \u00a0He shares his knowledge by answering questions and posting his projects to our forum. \u00a0I encourage you to take some time to visit our forum and check out some of his other work.<\/p>\n<p>Do you have something to share? We invite you to join our community and share projects that you have created. \u00a0Maybe someday you will see your project featured on our blog! If you liked this post and have anything to add, feel free to leave a comment here.<\/p>\n<p>&nbsp;<\/p>\n<div class='watch-action'><div class='watch-position align-left'><div class='action-like'><a class='lbg-style6 like-8400 jlk' data-task='like' data-post_id='8400' data-nonce='1cb2a57891' rel='nofollow'><img src='https:\/\/digilent.com\/blog\/wp-content\/plugins\/wti-like-post-pro\/images\/pixel.gif' title='Like' \/><span class='lc-8400 lc'>0<\/span><\/a><\/div><div class='action-unlike'><a class='unlbg-style6 unlike-8400 jlk' data-task='unlike' data-post_id='8400' data-nonce='1cb2a57891' rel='nofollow'><img src='https:\/\/digilent.com\/blog\/wp-content\/plugins\/wti-like-post-pro\/images\/pixel.gif' title='Unlike' \/><span class='unlc-8400 unlc'>0<\/span><\/a><\/div><\/div> <div class='status-8400 status align-left'>Be the 1st to vote.<\/div><\/div><div class='wti-clear'><\/div>","protected":false},"excerpt":{"rendered":"<p>Check out some fascinating fractal displays with Hamster&#8217;s latest project!<\/p>\n","protected":false},"author":32,"featured_media":8838,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[1323,1561],"tags":[],"ppma_author":[4489],"class_list":["post-8400","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-digilent-forums","category-applications"],"jetpack_featured_media_url":"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2015\/07\/fractal-1-cropped.jpg","authors":[{"term_id":4489,"user_id":32,"is_guest":0,"slug":"holly-b","display_name":"Holly Lawrence","avatar_url":"https:\/\/secure.gravatar.com\/avatar\/ac897f5b8752820720031e0cd12aa1fa1e8639018737372986fd216d4efa596c?s=96&d=mm&r=g","1":"","2":"","3":"","4":"","5":"","6":"","7":"","8":"","9":"","10":""}],"post_mailing_queue_ids":[],"_links":{"self":[{"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/posts\/8400","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/users\/32"}],"replies":[{"embeddable":true,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/comments?post=8400"}],"version-history":[{"count":0,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/posts\/8400\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/media\/8838"}],"wp:attachment":[{"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/media?parent=8400"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/categories?post=8400"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/tags?post=8400"},{"taxonomy":"author","embeddable":true,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/ppma_author?post=8400"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}