{"id":47,"date":"2021-01-19T19:39:48","date_gmt":"2021-01-19T19:39:48","guid":{"rendered":"http:\/\/www.matthew-morris.com\/wp2\/?p=47"},"modified":"2025-10-30T23:15:12","modified_gmt":"2025-10-30T23:15:12","slug":"cmy-cmyk-pen-plotting-with-sakura-pigma-microns","status":"publish","type":"post","link":"https:\/\/www.matthew-morris.com\/wp2\/uncategorized\/cmy-cmyk-pen-plotting-with-sakura-pigma-microns\/","title":{"rendered":"CMY\/CMYK pen plotting with Sakura Pigma Microns"},"content":{"rendered":"\n<p>This is possibly the most obscure post I will ever write.<\/p>\n\n\n\n<p>Having recently built a &#8220;4xidraw&#8221; as per Misan&#8217;s instructable at <a href=\"https:\/\/www.instructables.com\/4xiDraw\/\">https:\/\/www.instructables.com\/4xiDraw\/<\/a> I&#8217;ve been investigating various uses: I would totally recommend this as a project for anyone into electronics. The accuracy is pretty solid, the speed is good, and the cost a fraction of the &#8220;Axidraw&#8221; from Evil Mad Scientists &#8211; although the &#8220;Axidraw&#8221; is obviously a <em>far<\/em> better buy for anyone who wants the machine to get out of the way and just get on with the art bit.<\/p>\n\n\n\n<p>One thing that interested me was the prospect of doing full-colour images, and the &#8220;4xidraw&#8221; design seems more than capable of overlaying multiple plots in different colours. The theory here is that you combine Cyan, Magenta and Yellow in various combinations &#8211; the &#8220;CMY&#8221; part. If there&#8217;s a certain base level shared by all 3, you can draw that out into a &#8220;Key&#8221; level that is black, giving &#8220;CMYK&#8221; as the overall name. So by using 3 pens, you can potentially do full-colour designs.<\/p>\n\n\n\n<p>However the pens that many recommend for archival quality plot prints (Sakura Pigma Microns) don&#8217;t come in CMY colours. The best we can do is &#8220;Blue&#8221; (not &#8220;Royal Blue&#8221;) for &#8220;C&#8221;, while &#8220;M&#8221; is &#8220;Rose&#8221; and &#8220;Y&#8221; is yellow. The blue, in particular, is way too dark. What to do?<\/p>\n\n\n\n<p>It turns out that with a bit of adjustment, one can rebalance the colour to something pretty acceptable. I arrived at my mix by eye, dong test plots with a small image containing blocks with each of red, green, blue, cyan, magenta, yellow and 50% grey. Note that I only tuned colours in 10% increments. First thing to do was to reduce the &#8220;C&#8221; (blue, really) in the mix. Setting this at 50% was best &#8211; but then &#8220;Y&#8221; was slightly overpresent. Reducing that to 80% produced the best mix that I was able to come up with using Sakura colours.<\/p>\n\n\n\n<p>I ended up with the following Python code to map from RGB to CMYK. Note that I&#8217;m always setting K to zero because, for the kind of plotting I&#8217;m doing (&#8220;wiggle plots&#8221; &#8211; where you spiral outwards and wobble back and forth by an amount proportional to the amount of colour), it doesn&#8217;t make sense to draw out colour onto a K-layer. <\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>def rgb_cmyk_convert_sakura(r, g, b):\n    RGB_SCALE = 255\n\n    # rgb &#91;0,255] -&gt; cmy &#91;0,1]\n    # white = no wiggle (0), black = maximum wiggle (1)\n    if (r, g, b) == (0, 0, 0):\n        # black\n        return (1, 1, 1)\n\n    rc = r \/ RGB_SCALE\n    gc = g \/ RGB_SCALE\n    bc = b \/ RGB_SCALE\n    k = 0.0 # we don't use black as this we are calculating for \"wiggle\" plots: here, using black doesn't make sense\n    c = (1 - rc - k) \/ (1 - k) * 0.5\n    m = (1 - gc - k) \/ (1 - k)\n    y = (1 - bc - k) \/ (1 - k) * 0.8\n\n    return (c, m, y, k)\n<\/code><\/pre>\n\n\n\n<p>The results can be seen below. The green of the clown&#8217;s body at the bottom right is furthest off &#8211; Sakura&#8217;s blue doesn&#8217;t really have any green in it so we are missing some saturation there. But the match overall is not too shabby.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large is-resized\"><img loading=\"lazy\" src=\"http:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/Testcard_F-1.jpg\" alt=\"\" class=\"wp-image-51\" width=\"685\" height=\"681\" srcset=\"https:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/Testcard_F-1.jpg 149w, https:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/Testcard_F-1-100x100.jpg 100w\" sizes=\"(max-width: 685px) 100vw, 685px\" \/><figcaption>Original<\/figcaption><\/figure>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" width=\"1024\" height=\"1015\" src=\"http:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/drawing_testcard-1024x1015.jpg\" alt=\"\" class=\"wp-image-49\" srcset=\"https:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/drawing_testcard-1024x1015.jpg 1024w, https:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/drawing_testcard-300x298.jpg 300w, https:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/drawing_testcard-150x150.jpg 150w, https:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/drawing_testcard-768x762.jpg 768w, https:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/drawing_testcard-100x100.jpg 100w, https:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/drawing_testcard.jpg 1080w\" sizes=\"(max-width: 767px) 89vw, (max-width: 1000px) 54vw, (max-width: 1071px) 543px, 580px\" \/><figcaption>&#8220;Wiggle Plot&#8221; rendition using CMY mapping above<\/figcaption><\/figure>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" width=\"1024\" height=\"1014\" src=\"http:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/drawing_testcard_2-1024x1014.jpg\" alt=\"\" class=\"wp-image-53\" srcset=\"https:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/drawing_testcard_2-1024x1014.jpg 1024w, https:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/drawing_testcard_2-300x297.jpg 300w, https:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/drawing_testcard_2-150x150.jpg 150w, https:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/drawing_testcard_2-768x760.jpg 768w, https:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/drawing_testcard_2-100x100.jpg 100w, https:\/\/www.matthew-morris.com\/wp2\/wp-content\/uploads\/2021\/01\/drawing_testcard_2.jpg 1080w\" sizes=\"(max-width: 767px) 89vw, (max-width: 1000px) 54vw, (max-width: 1071px) 543px, 580px\" \/><figcaption>Staedler CMY Pigment Liner pens with a &#8220;true&#8221; (unweighted) mapping &#8211; admittedly, far better colour balance!<\/figcaption><\/figure>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>This is possibly the most obscure post I will ever write. Having recently built a &#8220;4xidraw&#8221; as per Misan&#8217;s instructable at https:\/\/www.instructables.com\/4xiDraw\/ I&#8217;ve been investigating various uses: I would totally recommend this as a project for anyone into electronics. The accuracy is pretty solid, the speed is good, and the cost a fraction of the &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www.matthew-morris.com\/wp2\/uncategorized\/cmy-cmyk-pen-plotting-with-sakura-pigma-microns\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;CMY\/CMYK pen plotting with Sakura Pigma Microns&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"_links":{"self":[{"href":"https:\/\/www.matthew-morris.com\/wp2\/wp-json\/wp\/v2\/posts\/47"}],"collection":[{"href":"https:\/\/www.matthew-morris.com\/wp2\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.matthew-morris.com\/wp2\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.matthew-morris.com\/wp2\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.matthew-morris.com\/wp2\/wp-json\/wp\/v2\/comments?post=47"}],"version-history":[{"count":4,"href":"https:\/\/www.matthew-morris.com\/wp2\/wp-json\/wp\/v2\/posts\/47\/revisions"}],"predecessor-version":[{"id":552,"href":"https:\/\/www.matthew-morris.com\/wp2\/wp-json\/wp\/v2\/posts\/47\/revisions\/552"}],"wp:attachment":[{"href":"https:\/\/www.matthew-morris.com\/wp2\/wp-json\/wp\/v2\/media?parent=47"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.matthew-morris.com\/wp2\/wp-json\/wp\/v2\/categories?post=47"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.matthew-morris.com\/wp2\/wp-json\/wp\/v2\/tags?post=47"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}