If it bothers you to work from a general formula like this, I suggest writing out the pattern for your particular hat in detail before you start (fairly easy if you cut-and-paste on a computer).
Numbers you need to know:
- C = desired circumference of hat
- L = desired length from center to edge of hat
- G = gauge (stitches per inch in garter)
- R = row gauge (rows per inch in garter)
Multiply the circumference by rows per inch to figure out how many rows you need to go around the hat. Divide by 6 to get number of rows in each wedge. Round to an even number. Call this W, for wedge rows. In other words:
W = R*C/6 (rounded to even number)
Multiply the desired length by stitches per inch to get the number of stitches you need to cast on. Round to an even number. Call this S, for stitches. In other words:
S = L*G
In my pattern, C = 14", L = 6", G = 6.5 stitches/inch, R = 11 rows/inch. So W=11*14/6, which is 25 point something and rounds to 26. S = 6*6.5 = 39, which I rounded to 40.
The short row shaping is done over the stitches towards the top of the hat -- W/2 stitches, to be exact. To make writing the pattern a little simpler, let's give that number its own name (T for "top"):
T = W/2
Here's the general pattern:
Start by casting on S stitches with a provisional cast on.
Rows 1-3: Knit all S stitches.
Row 4: Knit until there are T stitches left, then turn.
Row 5 and all remaining odd-numbered rows: knit back to starting edge
Row 6: Knit until there are T-1 stitches left, then turn
Row 8: Knit until there are T-2 stitches left, then turn
.... and so on until...
Row W-4: Knit until there are 2 stitches left, then turn
Row W-2: Knit until there is 1 stitch left, then turn
Row W: Knit all S stitches.
Now you should have a wedge-shaped piece of fabric. Repeat the rows above 5 more times so that you have a total of 6 wedges. Put the loops from your provisional cast-on onto a needle and graft them together with the stitches at the end of your last row (S stitches on each).
If you don't want to use a provisional cast-on or Kitchener Stitch, you can do a regular cast-on and cast-off and just seam the start and end together. If you do this, I'd omit the rows 1 and 2 on the first wedge to make up for the width of the cast-on and cast-off. I haven't tried this.
Whichever way you join the side, there will be a little hole left on top. Run a length of yarn around the edges of the hole twice, then pull tight. Work in all the ends, turn up the cuff, and you're done!