Knitting is Coding and More

Dec 22, 2022 | Curriculum, Elementary School, In the News, Student Work

by Ashley Brickeen | Admissions Director, Nursery-Grade 8

Imagine your child learning a coding language that could be read, used and accurately executed hundreds of years into the future. That is knitting. Hundreds of years before computer coding, fiber artists had created a symbolic language that could be used by knitters, crocheters and weavers anywhere in the world to reliably create clothing, blankets and toys. With knitting, the code is based on K (knit) or P (purl) stitches rather than zeros and ones.

At its most basic, knitting is executing an algorithm. An algorithm is a set of steps used to complete a specific task. Students are given a code (knitting pattern) and they carefully translate the code, executing the functions in the code line by line, row by row. Knitting patterns often include looping instructions, similar to a while loop in coding.

At Waldorf Schools, we introduce students to knitting in first grade. Knitting strengthens the muscles of the hand, requires focused attention, and reinforces the mathematics students learn in their main lesson. In the early grades, students add and reduce rows and stitches, follow ratios and use mathematics to calculate gauge (variables that must be adjusted to ensure that their sock fits). Whether knitting, crocheting, or weaving, all of these patterns (codes) are executed line by line, row by row, as with computer coding.

In fifth grade, we introduce variables into the knitting pattern/code, much like a variable in a coding language. Pattern authors will create one pattern which will make an object of a certain size – for example, a pair of socks that will fit a medium-sized foot. Students, working with their teacher, learn how to replace certain variables within the pattern/code to make the final product the proper size. After weeks of careful, attentive work, they have the final creation – a beautiful sock, sized to fit their foot.

This relationship between fiber arts and coding is not accidental. The work of fiber artists and the patterns they created led directly to computer code. In the early 1800s, the Jacquard loom used a punch card system (hole/no hole) to create elaborate textile patterns. Mathematician Ada Lovelace was inspired by this process when she created what is considered the first example of computer programming, famously stating that “The Analytical Engine [the theoretical calculating machine] weaves algebraic patterns, just as the Jacquard-loom weaves flowers and leaves.” She pointed out that this binary process could be used for all sorts of complex calculations and in numerous fields of human endeavor.

While teachers do not make the linkage between fiber arts and computer coding languages explicit to our students, the knitters are still absorbing the lesson through the physical experience of knitting and crocheting, laying the groundwork for their future understanding when they do encounter their first computer language. Nowadays, this sort of learning is often called embodied cognition, a field of research which recognizes that the sensory and motor [movement] systems of the body are fundamentally integrated into cognition. While the field of embodied cognition is relatively new, Waldorf Education has worked out of the framework of embodied learning since its inception in 1919.

These embodied experiences can lead to major discoveries. In 1997, mathematician Dr. Daina Taimina attended a geometry workshop on the hyperbolic plane. Stated simply, hyperbolic geometry is used by statisticians when they work with multidimensional data and acoustic engineers when they design concert halls, among other things. At this time, mathematicians were unable to represent hyperbolic space physically. In the field of mathematics, hyperbolic space existed only in principle. What allowed Dr. Taimina to solve this problem while she sat in that lecture hall? She is an avid crocheter. While she had always seen algorithms and patterns in her crocheting, she now saw how she could easily create a physical model of hyperbolic space with yarn and a crochet hook.

Of course, as with so much in Waldorf Education, the handwork curriculum works within a student physically, emotionally, and intellectually. It develops aspects of character – patience, emotional resilience, and tenacity. It also lays the foundations for future learning and growth.


For more reading, see 

  • Crocheting Adventures with Hyperbolic Planes: Tactile Mathematics, Art and Craft for all to Explore, Second Edition by Dr. Daina Taimina
  • Making Mathematics with Needlework: Ten Papers and Ten Projects  by Dr. Sarah-Marie Belcastro
  • Siobhan Roberts, SR. (2019) ‘Knitting Is Coding’ and Yarn Is Programmable in This Physics Lab For Elisabetta Matsumoto, knot theory is knit theory, New York Times, May 17, 2019. Available here.

Feature Image credit: Daina Taimina, ‘Hyperbolic Crochet’. 10 Questions from Isolation. Fad Magazine.