Hacker News new | past | comments | ask | show | jobs | submit login
‘Knitting Is Coding’ and Yarn Is Programmable in This Physics Lab (nytimes.com)
113 points by whack 32 days ago | hide | past | web | favorite | 62 comments



Sometimes outside of that physics lab. fbz over at knit yak (https://knityak.com) has been making very impressive computational "knitwear" for 4+ years.


> The yarn used is a 100% machine washable acrylic in black and white. Ships with source code, namely the command line one-liner that generated the image that is knit into the scarf.

I never expected to read this for any of the clothing I wear!


Welp. All sold out.


It's more like interpreting machine code. Looks like this:

... Row 20: sl 1, k9, ssk, k1, turn. Row 21: sl 1, p3, p2tog, p1, turn. Row 22: sl 1, k4, ssk, k1, turn. Row 23: sl 1, p5, p2tog, p1, turn. Row 24: sl 1, k6, ssk, k1, turn. Row 25: sl 1, p7, p2tog, p1, turn. Row 26: sl 1, k9, ssk, turn. Row 27: sl 1, p8, p2tog.

That's part of the code to make a sock.


Yes! I once had to translate this from english to swedish for my mother and wow. I was struck by how much it seemed like I was reciting assembler code.


Is 'uff da' really what the knitting error prints out?


How is that different to gcode?


It isn’t. In this environment the bugging is terrible though. You can’t just insert the cursor, instead you have to sequentially delete your good code to get back to your error.


Better than work pieces. Sorry boss someone out a 3/8th piece in the 5/8th holder. That $10e6 titanium piece is now scrap. We'll do better next time.


Ted Nelson pointed out that knitting (or was it weaving?) is one of the most popular programming languages back in 1979.

https://m.youtube.com/watch?v=RVU62CQTXFI

Edit to add: I wouldn’t be surprised if there are more knitting programmers today than all computer programming languages combined. Just the size and pervasive presence of Walmart or Joann’s yarn and fabric sections makes me almost certain.


The really nice yarn is not found at either of those places. You want to see serious knitters, find a dedicated yarn store, or check out a yarn convention. It's like an xmas movie where the shoppers are fighting over the last skein of yarn from a well known dyer.


Old domestic knitting machines had "software" in cards that were interpreted mechanically by the machine. Mom sill has an old Elgin in her house.


Computers and looms have always had a close-knit history (sorry I had to do it). During the industrial revolution there was a ton of innovation in looms, because producing fabric was very labor intensive. These early industrial looms are just sophisticated mechanical computers.


I believe that the reason early computers used punched cards, was because it was a technology already widely used for looms. Babbage just looked for what was already available for his Difference Engine.

https://en.m.wikipedia.org/wiki/Punched_card


What's interesting is that this idea has (very loose) roots in antiquity. Many beliefs had deities of fate that controlled the destinies of mortals by weaving.

source: https://en.wikipedia.org/wiki/Fates


The guy who showed it could be done automatically was Jacquard who built an automatic loom directed by punched cards, patented in 1804. Hollerith later took the idea but never acknowledged Jacquard's massive contribution.


John Von Neumann's dad brought home loom programming cards too.


This talk about programmable knitting machines is worth a watch: https://www.youtube.com/watch?v=02h74L1PmaU -- it goes into more depth about the details of their operation, including an absolutely wild and apparently official graphical programming language called "KnitPaint" that reminds me of the esoteric language Piet.


Knitting isn’t coding anymore than manually executing a C program with pencil and paper is. Designing or modifying a knitting pattern on the other hand is.


The professor which lectured the algorithms course at my university (and some others) published a paper some time ago which seems relevant: http://pages.di.unipi.it/bodei/publ-40/Fun07.pdf "Knitting for fun: a recursive sweater"


Ralph Griswold, designer of the Icon programming language, was very interested in weaving and maintained an “On-Line Digital Archive of Documents on Weaving and Related Topics”: https://www2.cs.arizona.edu/patterns/weaving/webdocs.html

Weaving-related topics were often discussed in The Icon Analyst newsletter, for instance (see earlier issues for more on T-sequences): https://www2.cs.arizona.edu/icon/analyst/backiss/IA66.pdf


To browse NyTimes with iOS when you have no articles left:

1. Settings

2. Safari

3. Advanced

4. Browser cache

5. Search for ‘nytime’ and delete

(Hope you pay if you often read their articles)


Swapping out nytimes.com for https://www.nytimes3xbfgragh.onion/ and opening in Tor has always gotten around the paywall for me - they don't seem to limit Tor users


a private tab works just as well on iOS


Not for me. Get a message that they don’t support private tab.


When I was a coding instructor, one of my students showed a knitting pattern. I immediately understood why she was one of the best students I have ever had.


Something isn't "coding" just because it involves following a set of instructions... you could argue that a knitting pattern is an algorithm of sorts, but that doesn't make it coding.


My partner is into knitting and what has struck me about it is the highly variable semantics and syntax of knitting patterns. Seems to be few standards as to how to describe how something should be knitted.


conceptually yes, but not so if your fine motor skills are poor. also dont understimate the manual labour involved in repetition, the computer makes it easier.


Yarn is ok but I prefer npm


Is leaving a piece of metal out in the rain coding? Is having coffee coding? Are snakes coding? Is a bad grade on a test coding? Is a musical note coding? Is a red gemstone coding? Is an even worse grade on a test coding? Is something found in an oyster shell coding?

Any other fun ones I missed?


> Is leaving a piece of metal out in the rain coding? Is having coffee coding? Are snakes coding? Is a bad grade on a test coding? Is a musical note coding? Is a red gemstone coding? Is an even worse grade on a test coding? Is something found in an oyster shell coding?

Rust, Java, Python, C++, C#, Ruby, C, Perl. God you guys totally missed it.

dang: now who had the shallow dismissal


Look, good jokes don't need to be explained but more importantly it's "Perl" and it has something to do with onions and camels.


There's also the connection between knitting and perling...


Pretty sure it's purling.


Another musical note (F#), a really bad grade on a test (D), a lady (Ada), more coffee (CoffeeScript), a follow on movie (SQL), a speech characteristic (Lisp), a branding image (Logo), A factory worker (Assembler), A Canal, Panama.


What you did there, they didn't see it.


If this was reddit and not HN, they would.


Can you guys be a little more serious. Some of us have to pretend we're working when we read this at work.


That's a riddle disguised as a joke


I thought people would get to the ruby part and immediately get it xD


"Please don't post shallow dismissals, especially of other people's work. A good critical comment teaches us something."

https://news.ycombinator.com/newsguidelines.html


You totally missed the joke.


That's always possible.


My wife knits. Yes, it’s like coding: it has a language, there are algorithms, instruction-sets and tools. And sometimes bugs you have to back-step to correct.


In fact some of the earliest programmable machines were weaving looms, automatically generating complex patterns. And, of course, this spurred the earliest protests against job losses to automation, with the Luddite movement.


My girlfriend knits too, and I think it's a toss up on which one of us curses more. Me when I realize the stupid thing I did which had been eluding me for the past hour, or her when she realizes how many rows she has to undo to get back to the point the incorrect stitch was made. At least I can just highlight, delete or just hit cmd-z. It can take her quite a bit more time to undo.


I hope she is aware of other ways of fixing knitting mistakes given here https://knitom.com/fix-knitting-mistakes-stress-free/ (or google for 'knit ladder down').


Without knowing what is being knitted, you may not be able to perform those techniques easily. Try that for a lace pattern with a finer yarn. Even frogging can be difficult.


>My wife knits.

I think we found the reason some folks are adamant it isn't coding.


Read the comment carefully before having a knee-jerk reaction next time. So sick of people on here assuming something is a negative comment.


So, if the comment isn't negative, then what is its content? Your explication https://news.ycombinator.com/item?id=19950959 points out the puns/jokes/over-literal descriptions (which, indeed, I missed on first read), but I still don't understand what the point of the comment was—the descriptions don't help me understand anything about the idea of knitting as coding.


It's a comment. It's meant to be fun -- the title got to have fun and play around with words, why can't we?

How I thought this would go: 30 upvotes and tons of people replying with more clever/forced programming languages fitting in that format.

How this went: no one gets it because everyone here is so ready for a fight that they don't even try to understand what people are saying, and the downvotes pile up. Deng swoops in and posts his generic "dont dismiss people's comments" message, which is hilarious because that's exactly what he did and it's exactly what you did.


There's two aspects to a joke that are equally important: one is being clever, the other is reading the room. A witty remark delivered in a snide tone followed up with a hot punchline is good for some lulz, but it's kinda like making a joke at the expense of the bartender who works at the comedy club every night.


Is piling parentheses coding? Is teasing with a feather coding? Is having a violent reaction coding?


Perl is coding, knitting has two standard commands: a knit, and a purl. It's a pun.

In your defense, I didn't get it until I read some of the other comments.


>Read the comment carefully before having a knee-jerk reaction next time. So sick of people on here assuming something is a negative comment.

If many, many people are misunderstanding your comment's sentiment, the problem is with the writer, not the parsers.


Better luck next time.


Reminds me of this tweet: https://twitter.com/1opter/status/810258612316729344

Knitting is Turing complete, and the punch card/jacquard loom analogies practically write themselves


reminds me of that software development conference where a developer could receive a tattoo with a favorite language icon from an O'Reilly book cover - thus becoming a better programmer, no doubt!


musical notes are...


[flagged]


I already did Rust.




Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | Legal | Apply to YC | Contact

Search: