Writing Patterns
If you are going to write your own patterns, then, unfortunately, you will have to use maths. So, whose fault is it?
Diophantus of Alexandria
(about Ad 250)
Diaphantus was a brilliant mathematician. He was Greek and his work displayed an algebraic approach to the solution of equations in one or more unknowns, unlike earlier Greek methods that were more geometrical. In the books of Arithmetica that survive, particular numerical examples of more than 100 problems, are solved, probably to indicate the general methods of solution. These are mostly of the kind now referred to as Diophantine equations.
Different names you should get to know
 Magic formula
 Line sum
 The Diophantine equation
 Triangle formula
 Remainder Theorem
Mathematical terms you should get to know
 dividend
 divisor
 quotient
 remainder
The Magic Formula
The Magic Formula is the main formula used in writing knitting patterns. All knitting patterns are made up of squares, rectangles and triangles. For the squares and rectangles you can use the conversion formula to convert measurements into stitches and rows. To calculate a triangle formula is a little more difficult. In knitting we use only whole numbers. Half a stitch is meaningless! So, we need to work with remainders. For example, if you divide 5 into 14 you will get an answer of 2 plus a remainder of 4. Because this formula opens a door on a whole new world of design and practice, the Americans and then the British following Alles Hutchison’s example, began to call it “Magic”. A more accurate description is a line sum. However, “Magic Formula” is easier to remember and less scary. Mathematicians would called this Remainder Theorem.
Remainder theorem
The remainder theorem is a rather obscure piece of maths. It states:
If 17 divided by 3 = 5 with a remainder of 2.
Then (5 x 3) + 2 = 17.
i.e.
If dividend  divisor = quotient, remainder
Then
quotient x divisor + remainder = dividend.
To find the Remainder

establish what value must be given to the algebraic number x to make the divisor equal to zero.

substitute this value in the dividend

the numerical value of this dividend is then the remainder
The Magic formula is a long division sum in which the remainders are shown as integers or whole numbers and not as fractions of the divisor. The sum is set down in an established way, with arrows to show the connections between the various parts. In the old way of calculating stitch increases on the rows of the underarm seam, any leftovers would be tacked on at the end. The sequences would be arranged quite arbitrarily without any reference to the line that was prescribed. There are three main expressions of the formula:

For the regular decrease or increase of stitches in rows along a diagonal, as on underarm seams, V necks, darts, raglans, and. bias knitting of any kind i.e. knitting diagonally from corner to corner. In this expression there is always a hidden right angled triangle on one side of the diagonal. In each case, the diagonal is the hypotenuse of the triangle. Where a design is complicated and two or more diagonals can be seen along a line, then the triangles need to be traced in and the sum worked out for each stage.

For the even distribution of extra stitches which have to be decreased or increased for features like cuffs, peplums, waistbands and yoked sweaters. For even distribution of stitches/rows in buttonhole bands and for distributing shaping groups of stitches along the length of a sideways knitted skirt.

For the creation of flares and metres using the short row technique, and in skirt, polygon knitting and sideways knitted circular yokes, as well as for breakdowns for colour changes in holding position, geometric Intarsia. This particular technique of shaping using involves breakdowns every other rows
The City and Guilds calls this the Diophantine
If you divide the number of stitches into the number of rows you will usually get a remainder. The old method was to calculate the breakdowns and leave any leftovers to distribute as you please. This was not very scientific. The Triangle Formula uses a part of mathematics called Remainder Theorem. In knitting it is important that we work in stitches and rows, not in fractions and this means that we work in “integers”, or whole numbers.
’Drafting by Charts’
I have a book called ‘Drafting by Charts’, published in English by the Okamoto Publishing Co Ltd in 1976. In this book, the Magic or Triangle Formula is called “the sum”. However, in Chart Rite by the American authors Bonnie Ralston and Norma Sweet published by the authors in 1974 various applications of “the formula” are used for all the breakdown calculations. The term “Magic Formula’ appears in a book by Alles Hutchison called “Charting by the Magic Formula” (1975). Alles Hutchison traced the origin of the formula to a Greek mathematician (c AD 500) called Diophantus who presented remainders as integers or whole numbers, and whose formula is ideal for knitters who cannot work with fractions of stitches or rows.
It is not as difficult as it looks  honest!