Laylock
 
  view basket

Currently browsing: programming

Stitch Pattern Calculator


Click here to access the Calculator

I spent a couple of hours several months back, working through the Javascript Fundamentals course at Codecademy and I was inspired to create a simple calculator to aid in shawl knitting. It solves two questions:

1. How many repeats of this stitch pattern can I fit into my stitch count?
2. How many stitches would I need to have for my stitch pattern to fit perfectly?

If you knit and design shawls on a regular basis, you’ll know how frequently you need to make this sort of calculation. Of course the calculator can be used for all sorts of knitting projects, but I thought I would briefly outline how to use it for shawls.

Using the Calculator for Shawl Borders

If you would like to add a simple border to a plain top-down shawl, you can use the technique I mentioned in Easy Shawl Borders in conjunction with the Shawl Knitting Cheat Sheet. Choose a stitch pattern, count the number of stitches on your needle, then use the calculator to determine how many repeats you can work. If you need a total number of stitches that your increase rate will not allow, then I recommend fudging. No one will know that you only increased 2 sts on that last row instead of 4! ;)

Using the Calculator for Shawl Edgings

You can also use the calculator to help you find/adjust edgings that will work for your shawl. This is easiest when you’re working a top-down shawl and are knitting an edging onto live stitches. In this case, instead of inputting the number of stitches your stitch pattern requires, you would use the number of rows in one repeat. The selvedge stitch number would usually be 0 unless you work a set-up or bind-off row.

Knitting & Programming

I love knitting and I love languages, so it follows that I should like programming. There is a long-standing tradition linking textiles and programming, and I recently came across this excellent article on Knitting as Programming (thanks to my Dad, who teaches Java). Alex draws a distinction between “executing” (knitting) a pattern, and actually programming it (writing/inventing the instructions). It all ties in (in my opinion) to the question of how detailed pattern instructions need to be. I certainly enjoy creating “design formulas” like my Crescent Shawl Shaping Worksheet, and the Fill-in-the-Blanks Shawl Design ebook I’m currently working on. The latter is particularly program-like, including if/else statements and loops. And while I have a long way to go before I can call myself even an intermediate programmer, I do enjoy Alex’s description of an experienced knitter, in particular the phrase “knot topology”:

When it comes to this kind of knitting, an experienced knitter is one who takes a modular approach, mixing and matching existing patterns and individual techniques, to build a finished product. It’s someone who can look at a pattern and figure out how to knit it in a different yarn, a different gauge, and a different size, without breaking a sweat over the calculations. It’s someone who geeks out on the knot topology, the 3D spatial reasoning, and the materials science of it all… and knows how to put them to practical use. It’s the difference between being a code monkey and being an engineer.

I hope you find my forays into programming useful, and have a go yourself at being a stitch engineer. :)

19th June, 2012  // Downloads, Knitwear Design // tags: , , , , .

Your Favourites ❤

  • Your favorites will be here.