tag:quandyfactory.com,2016-9-8:/201698 2016-9-8T12:00:00Z Quandy Factory Newsfeed - All Quandy Factory is the personal website of Ryan McGreal in Hamilton, Ontario, Canada.. http://quandyfactory.com/blog/170/a_third_year_of_running_plus_various_other_experiments 2016-07-28T12:00:00Z A Third Year of Running, Plus Various Other Experiments <p>As of today, I have been running recreationally for three years. My <a href="/blog/135/a_year_of_running">first year of running</a> was a triumphal sequence of milestones with only a couple of minor setbacks along the way. So it was perhaps inevitable that my <a href="/blog/155/a_second_year_of_running_plus_some_not_running_and_other_stuff">second year of running</a> would be a painful introduction to hubris and humility. </p> <p>I think it's fair to say that my third year has been a synthesis of the first two: I have finally internalized and accepted the lessons of my second year, which has allowed me to return to something akin to the accomplishments of my first.</p> <h3>Yet Another Foot Injury</h3> <p>Last summer and fall, I felt injury free and was going from strength to strength. On October 13, 2015, I set a new personal record (PR) for 10 km, maintaining an average speed of 11.31 km/h (5:19 min/km). I figured that was just a fluke, but I averaged 11 km/h on October 20, 11.13 km/h on October 22 and 11.12 km/h on November 3. Even on my slow days I was running in the range of 10.7-10.9 km/h. Through November, I cracked 11 km/h four times and got close to 11 km/h on my other 10 km runs. Yes, the speed monkey was once again perched firmly on my back.</p> <p class="image"> <img src="/static/images/calvin_hobbes_live_and_dont_learn.jpg" alt="Calvin and Hobbes: Live and don't learn" title="Calvin and Hobbes: Live and don't learn"><br> Calvin and Hobbes: Live and don't learn</p> <p>On December 1, I beat my previous PR with a 10 km averaging 11.37 km/h (5:17 min/km). Then I beat it again two days later with a 10 km at 11.4 km/h (5:16 min/km). My two 10 km runs the following week were both faster than 11 km/h, and the week after that I beat my PR yet again: on December 15, I ran a 10 km at a blazing (for me) average speed of 11.76 km/h (5:06 min/km).</p> <p>Over the next couple of days, I started to notice a nagging soreness on the outside middle of my left foot, in the general area of my fifth metatarsal bone. <p>At first I worried I might have a stress fracture (very bad news!), but my foot passed the "one-legged hop test" - if you have a stress fracture, it hurts too much to hop on it repeatedly. <p>The pain was fairly dull and intermittent, but as time went on I realized it wasn't going to go away quickly by itself. The joy of running in shorts and a t-shirt on Christmas Eve was tempered by the realization that I had definitely done something to my foot. <p>I really, *really* didn't want to take another break from running, especially with the 30 km Around the Bay Road Race just three months away. I absolutely did not want to have to go through a repeat of the previous year's desperate scramble to prepare, when just a week earlier I had been doing 25-26 km long runs back-and-forth along the hardest part of the Bay Race route.</p> <h4>Low Intensity Training</h4> <p>With nothing to lose, I decided to do some experimenting. I discovered that if I ran with really solid form, was careful not to over-pronate and maintained a speed below 9 km/h, my foot didn't feel pain. I decided to see whether I could *train below the threshold of aggravation* and maintain my progress. <p>Knowing that achieving this meant I was going to do most of my running at low speed to achieve this, I did some reading on low-intensity training. The news was encouraging: in fact, elite running coaches generally believe that *most* training should be low intensity. While there is some debate, the general consensus now seems to be that 80 percent of your running should be at low intensity and 20 percent should be at high intensity: tempo runs, intervals, fartleks and so on. <h4>Benefits of Low Intensity</h4> <p>Low intensity training comes with a slew of benefits, including better running form and fewer injuries: <ul> <li>It fosters the creation of new mitochondria, improved heart and cardiovascular efficiency, and faster damage recovery from harder runs. There's a lot of science behind this but your body undergoes some remarkable adaptations when you subject it to lots of slow miles.</li> <li>At lower intensity, you maintain better form, which improves running efficiency and reduces impact strain and the risk of injury. Runners' form inevitably goes to hell when they try to train at high intensity over long distances.</li> <li>Sheer volume of running is one of the most important ways to become a better runner, and low-intensity means you can put in more distance. I peaked at around 64 km a week in March before moving into my final taper.</li> <li>Your body becomes more effective at burning fat for fuel.</li> </ul> <h4>Changing Running Habit</h4> <p>Many coaches define low-intensity running as running below the *ventilatory threshold* - the level of intensity at which you have to start breathing a lot faster and deeper to get enough oxygen. I committed to adopting this approach with my own running. Of course, it takes time to change habits and I spent January mostly still running too fast, though I did cut my long run distance back to 22 km. However, when February began I finally committed to low-intensity running. <p>I forced myself to maintain low intensity by breathing through my nose (mouth closed), inhaling for five or six steps and exhaling for five or six steps. This was frustrating: it meant I could only run at a very slow 8.5 km/h! My foot completely stopped bugging me after I adopted this pace, and the low intensity meant I could increase my number of weekly runs from three to four. With four runs a week, I was running more total distance even though I was doing each run more slowly. <p>Even though I maintained an inhale-for-five-steps, exhale-for-five-steps breathing pattern, my speed at that breathing pattern shot up rapidly. I believe part of this is simply that my running form became more efficient: producing more forward momentum for the same expenditure of energy. By denying myself power, I forced my body to become more mechanically economical. <p>It's quite possible that I also became more efficient at inhaling air through my nose. Previously, I had always run with my mouth open so inhaling exclusively through my nose was new. And of course, there are the other metabolic changes - increased cellular mitochondria, and so on. <p>I was never sure whether I was actually running at the correct intensity. I don't have a heart rate monitor so I'm just guessing that my limited-air intake proxy was getting me into the right ballpark. Still, there is no question I saw a rapid and dramatic improvement in how fast I could run at a given level of intensity. <h4>No Sugar Challenge</h4> <p>Just I was reading this stuff, my son came home from school and announced that he was taking the Two-Week No Sugar Challenge, i.e. eat no processed sugar at all for two weeks. Inspired by his determination, I joined the challenge and eliminated processed sugar, avoided simple carbohydrates (like pasta) and even cut back on fruit. <p>I highly recommend this! Over the two weeks, the challenge reset my taste sensitivity to sugar. By the end, a banana was almost too sweet. To this day I eat less sugar than before. Perhaps more important, the challenge also seems to have reset my metabolism. I gradually stopped experiencing sugar highs and lows. My energy level no longer dips in midafternoon and I feel generally calmer and more balanced. <p>Of course, there were some training implications. I did two 23-25 km long runs during the challenge, and in both cases I set out on an empty stomach early in the morning and brought only mixed nuts to much on. I normally bring a date-and-nut bar, but dates are around 50 percent sugar so it seemed in keeping with the spirit of the challenge to leave them at home. <p>I was also curious about what would happen once I used up my stores of glycogen, which seemed to happen roughly two hours into the runs. Rather abruptly, I found that my energy level dropped, my pace faltered and my hunger turned ravenous. <p>I have a particularly strong memory of returning up Locke Street one Saturday morning and passing the Earth to Table Bread Bar as they were baking croissants. The whole block smelled like fresh buttery pastry and it drove me more insanely hungry than I ever remember feeling. I had to restrain myself from smashing through the front window to grab one! <h4>Intermittent Fasting</h4> <p>Another benefit of that reset was that I was finally successful in adopting intermittent fasting. On weekdays I now eat only between 1:00 PM and 7:00 PM and fast the other 18 hours. (On weekends I eat normally.) <p>There's some interesting science behind intermittent fasting. It: <ul> <li>Reduces blood insulin levels, triglycerides and dangerous LDL cholesterol;</li> <li>Lowers blood pressure, reducing the risk of heart disease and diabetes;</li> <li>Dramatically raises human growth hormone, which helps to build lean muscle mass;</li> <li>Switches cells to maintenance mode, repairing cell damage and potentially reducing the risk of some types of cancer.</li> </ul> <p>I have to say, intermittent fasting feels great - I have lots of energy, I don't get food cravings and I generally feel better than I have in years. I even make a point of doing my daily cardio exercise (running, cycling or brisk walking) during the last hour of the fast and following it with my first meal of the day. At no point have I felt weak, dizzy, light-headed or otherwise ill, even during tempo or interval runs. <p>I've been doing it for several months now and have no plans to give it up. Unless something changes, I definitely plan to continuing following this practice. <h4>High-Resistance Injury</h4> <p>So how did all of this affect my intermittent foot injury? The good news is that my theory of training below the threshold of aggravation seems to have worked. As long as I kept most of my training at a low intensity and focused on maintaining good form (i.e. not over-pronating too much), my foot felt fine and I didn't have any symptoms. <p>As time went on, I have been able to go progressively faster before I felt that twinge of pain start to come back. That idea of an intensity threshold of injury symptoms led me to a kind of fuzzy hypothesis. <p>Years ago I worked as a telephone repair technician. A telephone line is very simple, just two wires: one going from the switching office to the phone, and one returning from the phone to the switching office. A small current originates in the switching office along one wire, crosses the phone to provide dial tone, and returns to ground along the other wire. <p>A common fault is a short circuit: the current jumps directly from one wire to the other and never makes it to the telephone. A less-common variant is a <em>high-resistance</em> short circuit. The voltage of a standard phone line jumps from 48 volts to 120 volts to trigger the telephone's ringer when a phone call is coming in. That higher voltage is enough to cause the current to jump across the wires. The short circuit disconnects the call, causing the voltage to drop back to 48 volts. That, in turn, causes the short circuit to disappear again, at which point normal dial tone is restored. <p>This is the analogy that came to mind for my foot. It worked fine at a low intensity level, but pain manifested at higher intensity. In effect, it was a "high-resistance injury". But unlike a high-resistance short circuit, my foot was slowly repairing myself as I kept my training intensity down, and the intensity level at which symptoms reappeared got progressively higher. <p>Combined with the fact that I was becoming progressively more efficient at a given level of intensity, this meant I was able to continue increasing both my distance and speed throughout the period in which I was ostensibly recovering from an injury. <h3>Around the Bay</h3> <p>My winter running schedule may have been constrained by my high-resistance foot injury, but it was framed by my desire to compete in this year's Around the Bay Road Race. <h4>Long Runs</h4> My long run distance was steadily creeping back up after I had backed it off at the end of December. I was training along the hardest part of the Bay Race route - the hilly North Shore Boulevard section - by running it twice: once from my house out toward Joseph Brant Hospital, and again on the way back. <p class="image"> <img src="/static/images/runkeeper_map_bay_race_training_route.png" alt="Bay Race training route from southwest Hamilton along North Shore Boulevard and back" title="Bay Race training route from southwest Hamilton along North Shore Boulevard and back"><br> Bay Race training route from southwest Hamilton along North Shore Boulevard and back </p> <p>I also added in the very big, nasty hill on Spring Gardens Road, which has a steep switchback bridge on the west side and a long, punishing climb on the east side. I figured that training on a route harder than the route I would have to do on race day would put me in good shape. </p> <p>The route got to be fairly lonely. My schedule had me going out really early, so I ran alone and hardly encountered anyone else on the road. Also, the section along York from Dundurn to Plains is loaded with big infrastructure - wide lanes, highway overpasses and bridges - that makes a mere human feel especially puny and insignificant in the predawn gloom.</p> <p>My 28 km long run on Sunday, February 14 (Valentine's Day) was the coldest day of winter. The temperature was -20C when I headed out at quarter after six in the morning, and I wore two shirts, a winter shell, a wool hat and scarf, two pairs of gloves and a fleece hoodie on top of everything else.</p> <p>Icicles kept forming on my eyelashes and eyebrows, but otherwise I stayed toasty - a bit too hot, actually, once my body warmed up. I didn't bring any water, since my water bottle would have just frozen at that temperature, so I had to be careful not to sweat too much and get dehydrated.</p> <p>In addition to the warm glow I got from sticking to my running schedule despite the cold, I enjoyed some breathtaking views of Hamilton Harbour from North Shore Boulevard, particularly as the sun rose and steam started pouring off the water.</p> <p class="image"> <img src="/static/images/bay_and_skyway_bridge_from_bottom_of_francis_2016_02_14.jpg" alt="Hamilton Harbour and Skyway Bridge from the bottom of Francis Street, February 14, 2016" title="Hamilton Harbour and Skyway Bridge from the bottom of Francis Street, February 14, 2016"><br> Hamilton Harbour and Skyway Bridge from the bottom of Francis Street, February 14, 2016</p> <p>The next week I ran 28.4 km at a respectable average speed of 10.29 km/h (5:50 min/km). The week after that, I managed a full 30 km for the first time since I had run the previous Around the Bay a year earlier. My first time running 30 km was just to cover the distance, and I did it at a stately 9.79 km/h (6:08 min/km).</p> <p>I had enough time for two more 30 km training runs before beginning to taper for the big day. My long run on March 6 managed 10.17 km/h (5:54 min/km), but I really felt my energy fade over the last five km. That sense of petering out at the end was fairly discouraging.</p> <p>The following week I took it a bit easier through the run so I'd have some energy left over for the end. My average speed was the same - 10.17 km/h - but it felt a lot better to be able to maintain a pace right through to the end.</p> <p>At this time I picked up a new pair of shoes. I got them a couple of weeks before I really needed to, but I wanted them to be broken-in by the time I wore them on the Bay Race.</p> <p class="image"> <img src="/static/images/new_shoes_2016_03_15.jpg" alt="New shoes, March 15, 2016" title="New shoes, March 15, 2016"><br> New shoes, March 15, 2016</p> <p>Like the previous several pairs, they were Mizuno Wave Riders, but version 19 had come out since my previous purchase, and they had a new look with a silvery-grey upper and yellow and black soles.</p> <p class="image"> <img src="/static/images/new_shoes_2016_03_15_compared_to_old_shoes.jpg" alt="Wave Rider 19 sole, compared to worn-out Wave Rider 18" title="Wave Rider 19 sole, compared to worn-out Wave Rider 18"><br> Wave Rider 19 sole, compared to worn-out Wave Rider 18</p> <p>However, they were otherwise of a similar construction and were still extremely comfortable on my feet. Research conducted by the U.S. Military has <a href="http://well.blogs.nytimes.com/2015/08/05/choosing-the-right-running-shoes/">concluded</a> that the best way to choose the right pair of shoes is to try on a wide variety of brands and types and then pick the ones that feel the most comfortable.</p> <p>After my last 30 km long run, it was time to taper for the big day. My March 20 run was just 26.5 km at a brisker 10.41 km/h (5:46 min/km) and I meant for my final pre-race long run to be just 22-23 km. However, I ended up not able to do it.</p> <h4>Germophobia and the Final Week</h4> <p>As the race approached, I became increasingly paranoid that something would happen to knock me out of the race: an injury, illness or other disaster. As a result, I became increasingly careful about not getting hurt.</p> <p>I also became increasingly germophobic, a practice that caused some consternation with my family - especially when my son caught a cold a week and a half before the race and I insisted on comforting him from a prudent distance.</p> <p>Notwithstanding my best efforts, I woke up on Good Friday feeling sick with some kind of gastrointestinal upset. I managed to get in a low-intensity 10 km run that day, but I felt like garbage all weekend and when I woke up on Sunday, I felt too rotten to head out the door and away from the bathroom.</p> <p>I still felt under the weather on Monday, March 27, but could feel I was on the rebound, and I did a 10 km tempo run while managing to hold everything inside.</p> <p>On Tuesday, I did an easy 7 km jog with a friend who is getting back into running after Achilles tendinitis, and it was great to run with someone who kept me from going too hard. Wednesday was a 9 km at a moderate speed, and Friday was a slightly up-tempo 9.5 km, partially done out of lingering guilt over not having done my long run the previous Sunday.</p> <p>Aside from a few brisk walks on my non-running days, I was out of things to do to prepare.</p> <h4>The Race Morning</h4> <p>I spent the entire week before the race agonizing over what to wear. The weather forecast called for around -3C in the morning, rising to -1 or 0 by the end of the race. </p> <p>That's an awkward temperature for me, because I have a really warm winter shell for when it's -5 or below, and of course you can just wear shorts and a long-sleeve shirt or two if it's above +2 or 3. When it's in the range of -3 to +3, I have a floppy windbreaker I wear that suits the weather but isn't great for going fast in a race. </p> <p>"Luckily" the morning dawned really cold, -6C according to my local Wunderground station. That meant I could safely wear my winter shell, but I was still worried about it getting too warm later, since the thing is just too hot above -4. So I split the difference and wore the shell on top with shorts on bottom. I figured I could radiate excess heat through my legs if it got too warm.</p> <p>It turns out I was dressed more or less spot-on for the race itself. I was able to tune my warmth by zipping and unzipping the shell and rolling my sleeves up and down, and my legs were plenty warm from the exertion of running. However, the 2.2 km walk from home to FirstOntario Centre was quite chilly. </p> <p>I tend to get paranoid about showing up late or somehow having misread the start time, so I arrived an hour before the race started. That meant an hour of wandering around and killing time. I spent a lot of that outside, in part because being inside the arena made me nervous that I might miss the start of the race, and I got pretty cold. I was shivering quite a bit, and I started to tense up. </p> <p>Being cold like that produced one strange and unpleasant outcome: Not long before the race started, I was hopping over a small concrete bench in front of the federal government building on Bay Street and my back spasmed when I landed. I actually tumbled and rolled over, scraping my hands and right leg and landing on my back. </p> <p>After that, my back was tender, sore and twingy for the entire race and the next few days afterwards. (It actually continued to twinge intermittently for the next several weeks and even flared up again in subsequent months, which was pretty frustrating.)</p> <p>Fortunately, running didn't hurt any more than not running, so I was still able to complete the race. If anything, it forced me to maintain a straight posture because it would flare up when I slumped. </p> <h4>The Race Itself</h4> <p>That stumble was the only sour note in an otherwise excellent experience. When the race actually began, I was of course swept up in the enthusiasm of the starting line and poured down the street along with the almost 6,000 people running the full 30 km or the first part of a relay. </p> <p>My mobile running app is set to give me audio updates every five minutes (time, distance, average speed), but there was so much general noise that I didn't actually hear it until the 15-minute update. I was amazed so much time had already passed!</p> <p>I settled into a speed of around 10.5 km/h (5:43 min/km pace), which was a moderate level of intensity I felt I would be able to sustain for at least the first two-thirds of the race. I employed a relatively fast cadence of three steps per second or 180 steps per minute with a mid- to forefoot strike.</p> <p>My breathing pattern was: inhale five steps and exhale five steps for three repetitions, and then inhale five steps and exhale four steps for one repetition. (Dropping a step from every fourth exhalation means the foot I land on while starting to inhale regularly alternates, <a href="http://www.runnersworld.com/running-tips/running-on-air-breathing-technique">reducing the risk of imbalance injuries</a>.)</p> <p class="image"> <img src="/static/images/05_thumbs_up_near_high_level_bridge.jpg" alt="Thumbs up near the High Level Bridge (Image Credit: Marathonfoto)" title="Thumbs up near the High Level Bridge (Image Credit: Marathonfoto)"><br> Thumbs up near the High Level Bridge (Image Credit: Marathonfoto)</p> <p>I still felt good by the 19th km, where the rolling hills of North Shore Boulevard begin, so I decided to keep my pace up by switching to an inhale-four-steps, exhale-four-steps pattern (dropping to exhale three steps every four repetitions) to increase my rate of oxygen intake. </p> <p>That breathing pattern sustained me through the hills and up to Plains Road, but I definitely switched from operating reserves to capital expenditures and could feel my energy level start to drop. Between 15 and 23 km, I gradually munched on a peanut-and-date energy bar, so I was able to replenish some glycogen before bonking. However, my muscles were getting straight-up tired.</p> <p class="image"> <img src="/static/images/atb_2016_km_23_24_bruce_taylor.jpg" alt="More mugging for the camera in the 24th km (Image Credit: Bruce Taylor)" title="More mugging for the camera in the 24th km (Image Credit: Bruce Taylor)"><br> More mugging for the camera in the 24th km (Image Credit: Bruce Taylor)</p> <p>As an aside, this close-up shows just how dramatically I was pronating:</p> <p class="image"> <img src="/static/images/atb_2016_pronation_bruce_taylor.jpg" alt="Prontating on the Bay Race (Image Credit: Bruce Taylor)" title="Prontating on the Bay Race (Image Credit: Bruce Taylor)"><br> Prontating on the Bay Race (Image Credit: Bruce Taylor)</p> <p>For the last five km after Plains Road transitioned to York Boulevard, I switched to an inhale for four, exhale for three breathing pattern, and finally an inhale for three, exhale for three pattern down the home stretch. </p> <p>Again, that allowed me to maintain my pace despite increasing fatigue: my km-29 speed was 10.59 km/h and my km-30 speed was 10.79 km/h. I didn't want to leave anything out on the course.</p> <p>I don't know whether these made a significant difference to my overall speed, but as I had learned during my training runs, it feels much better psychologically to finish strong than to peter out.</p> <p class="image"> <img src="/static/images/08_crossing_the_finish_line.jpg" alt="Just about to cross the finish line (Image Credit: Marathonfoto)" title="Just about to cross the finish line (Image Credit: Marathonfoto)"><br> Just about to cross the finish line (Image Credit: Marathonfoto)</p> <h4>Results</h4> <p>According to Sportstats, my official time (from when the gun went off until I crossed the finish line) was 2:54:44.6. My chip time (from when I crossed the starting line until I crossed the finish line) was 2:52:31.5. Here is how I measured up against the other participants:</p> <table> <caption>Finishing Place by Comparator</caption> <thead> <tr> <th>Comparator</th> <th>Population</th> <th>Place</th> <th>Percentile</th> </tr> </thead> <tbody> <tr> <td>Males age 40-44</td> <td>443</td> <td>267</td> <td>40</td> </tr> <tr> <td>All males</td> <td>2,669</td> <td>1,508</td> <td>43</td> </tr> <tr> <td>All participants</td> <td>5,259</td> <td>2,253</td> <td>57</td> </tr> </tbody> </table> <p>Among the 443 males age 40-44 in the 30 km, I finished in 267th place, putting me in the 40th percentile (i.e. faster than 40 percent of the runners in this category). Among all 2,669 males, I finished in 1,508th place, putting me in the 43rd percentile (i.e. faster than 43 percent of all male runners). Among all 5,259 30 km participants, I finished in 2,253rd place, putting me in the 57th percentile (i.e. faster than 57 percent of all the runners).</p> <p>I can honestly say I'm completely satisfied with being roughly in the middle of the pack when the pack in question is people who ran a 30 km race!</p> <h3>My First Extended Fast</h3> <p>By this point I had been having really positive experiences with 18:6 intermittent fasting, but I found myself wanting to experiment with something more intensive. </p> <p>So on Sunday, April 24 at around 8:00 PM, I ate a piece of banana bread after dinner. That was the last thing I ate until Wednesday, April 27 at 9:00 PM, when I had a slice of toast to restart my digestive system.</p> <p>For the intervening 73 hours, I ate nothing and drank only water and clear tea.</p> <h4>Day One</h4> <p>The first day, Monday, was pretty easy. I was already accustomed to intermittent fasting on an 18:6 schedule so I didn't really start feeling hungry until mid-afternoon. Monday was a day off from my running schedule, but I took a brisk 7 km walk around lunchtime and felt fine.</p> <p>Monday evening was harder, because the division of labour in my household has me cooking dinner on weekdays and that night's scheduled dinner was latkes. The smell of frying potato, onion and egg was an intoxicating test of my resolve. My family said it felt weird and uncomfortable to have me sitting with them during dinner but not eating. It felt a bit weird for me, too.</p> <p>Mood-wise, I found myself getting crabby and irritable in the evening. I had to hold my tongue when I found myself wanting to get snappy with my family.</p> <p>A common piece of advice for fasting is to drink lots of water, but I think I may have overdone it a bit. On Monday night, I got up three times to pee, when I usually sleep through the night. I also slept rather poorly, but that's pretty common for me.</p> <h4>Day Two</h4> <p>I woke up on Tuesday morning without a feeling of hunger, which was nice. I got up and felt reasonably energetic. I didn't notice anything until I was walking to work, when my hunger level ramped up during the exertion of a moderately brisk walk.</p> <p>Tuesday is a running day for me, and I usually run 10 km during my lunch hour. People who go on extended fasts recommend taking the time to rest and let the body enjoy a break from day after day of exertion. This makes sense, but one of the reasons I wanted to fast in the first place was to learn more about my body, including how my physical performance relates to the food I eat. So I decided to follow my usual running schedule and see what happened.</p> <p>I noticed several things on this particular run, in which I only managed a little over 9 km in the time I usually run 10+ km:</p> <ol> <li><p>My energy level was severely depleted compared to how I usually feel. My normal easy cruising speed is in the 10.5 km/h range, but for this run I could barely maintain 10 km/h at a fairly hard exertion. I found that if I pushed beyond this, I started to feel light-headed, but if I maintained this speed, I felt okay (not good, just okay).</p></li> <li><p>I normally follow the breathing pattern: inhale for five steps and exhale for five steps (5:5), but with this run I almost immediately had to revert to 4:4 - I just wasn't getting enough air on 5:5. During parts of the hill, I had to go to 4:3 and even 3:3. </p></li> <li><p>I had been feeling just a dull, mild hunger that day until I started running, at which point it became an acute, roaring hunger. The intensity of hunger did gradually subside after I stopped running, but it seemed more present for the rest of the day.</p></li> <li><p>For the first time in as long as I can remember, I actually found myself wanting to cut the run short and bail. The whole thing felt like the last exhausted stretch of a long run that extends your distance limit - the part you push yourself through with sheer willpower.</p></li> </ol> <p>On Tuesday evening, I had to run the dinner gauntlet again, and it was even harder than on Monday to abstain from eating. Dinner was breaded chicken and quinoa with roasted root vegetables and toasted pecans, pepitas and sunflower seeds. The smell of roasting carrots, parsnips and beets almost drove me batty. (Interestingly, the chicken did nothing for me.) Instead of sitting with my family for dinner, I kept myself busy in the kitchen cleaning up, which everyone seemed to prefer.</p> <p>Tuesday night I only got up to pee twice, but I slept quite poorly again.</p> <h4>Day Three</h4> <p>Once again, I felt no hunger when I woke up, and once again, the hunger came back during my walk to work. By Wednesday I definitely noticed that I was walking more slowly than usual. I just didn't seem to have it in me to pick up the pace.</p> <p>I continued to work at my standing desk (I like to keep moving when I'm working, and I listen to music to have something to move to), and I didn't particularly feel weak while working, taking the stairs or doing my daily routine of planks, pushups and one-legged calf-raises. </p> <p>Instead, as the morning went on, I began to feel giddy. My energy level seemed to be fine, despite the ever-present gnaw of hunger, and I had no trouble concentrating. In fact, I found my mental clarity became sharper than usual. </p> <p>I was curious to see how my body would perform on my next scheduled run. As it turns out, it performed very much like it did on Tuesday, except that I eased off a bit further on my pace in order to make the experience less dire. I actually felt a bit of a second wind on the back half of the run, though I only managed to run 9 km and my average speed ended up being a stately 9.85 km/h. Once again, a hunger that had been mostly dull and low-intensity roared back into high alert once I started running, and it took a while after the run ended before it settled back to a dull grumble again.</p> <p>On Wednesday afternoon, I felt - there's no other way to put it: I felt <em>low</em>. It was a deep physical, emotional and spiritual low point for me. Walking up a flight of stairs left me feeling fatigued, and I felt more depressed and discouraged than I remember feeling in a while. Dinner was barbecued honey-garlic sausages and a big salad. This was easier to make and not eat, since the smell of cooking sausages was diffused in the outdoor breeze. However, that low, lethargic, depressed feeling continued all evening. My wife kept asking me if I was okay.</p> <p>By the time I went to bed, I felt downright terrible, and I seriously wondered if I might be doing myself harm. In particular, my heartbeat felt strange - a bit fast and heavy, and I could feel it beating throughout my body. I sort of felt the way I feel after a couple of days of illness. I had been intending to continue the fast for five days - unless I became seriously concerned about my health. So I decided with a heavy heart to break my fast on Wednesday night. </p> <p>I made myself a slice of whole-grain toast with a scrape of butter and nibbled on it slowly over 20 minutes, drinking lots of water along the way. My stomach gurgled happily for the next hour or so, and I eventually fell asleep. (And yes, I woke up twice to pee.)</p> <h4>Day Four</h4> <p>I woke up on Thursday morning feeling incredibly revitalized. That one piece of toast completely changed my mood and energy level! I thought I would wake up ravenous after re-engaging my stomach with food, but I didn't actually start to feel hungry until after my walk to work.</p> <p>I took this day to transition from fasting to normal eating again. There's a terrifying thing called <a href="http://www.ncbi.nlm.nih.gov/pmc/articles/PMC2440847/">refeeding syndrome</a>, and I don't know what the threshold is for triggering it but I was not going to take any chances. I started with a smallish tossed salad of arugula, walnuts and apple slices, which I nibbled very slowly over half an hour with a mug of tea. Then I let that sit for a few hours to see how it went down.</p> <p>Thursday is a cross-training day for me, so I went on a lunchtime bike ride as part of a project I'm working on to analyze GPX data from <a href="https://hamilton.socialbicycles.com/">Hamilton Bike Share</a> trips. My energy level felt great - in fact, I generally felt fantastic all day, from the moment I woke up. After my deep low on Wednesday, I was euphoric. I had a spring in my step again, and seemingly all the energy a person could ask for.</p> <p>For lunch, I ate some of the leftover quinoa and roasted vegetable salad from Tuesday night. Again, I ate very slowly and had it with lots of water.</p> <p>After work, I had a snack and then my wife and I went to an event where they were serving delicious bite-sized appetizers - perfect for someone adjusting back to eating after a multi-day fast.</p> <h4>General Observations</h4> <p>I'm disappointed I wasn't able to go the full five days. From what I've read, fasting usually becomes considerably easier after the third day, and I didn't continue long enough to experience this. On the other hand, I had decided at the outset that I would only stop if I became seriously worried about my health, and this is what I did. I didn't give up because of hunger - in fact, the hunger generally wasn't as bad as I expected - or because of a lack of willpower.</p> <p>I also made a point of not telling people I was fasting. The only people I told were my immediate family, who would otherwise have wondered why I wasn't eating with them, and one friend with whom I share an interest in "life hacking". </p> <p>I'm not religious but I was raised Catholic and have always been struck by the message in Matthew 6:16: "And when you fast, do not look dismal, like the hypocrites, for they disfigure their faces that their fasting may be seen by men. Truly, I say to you, they have their reward." So I tried my best not to "look dismal", mope around and allow myself to feel self-pity, as if I was making some kind of big sacrifice. </p> <p>After all, I was fasting on my own initiative, and I was doing it in order to widen my experience of the human condition, learn about my body and mind, and explore the potential health benefits. That's hardly a basis to feel sorry for oneself!</p> <p>I learned that food contains a lot of water. When you stop eating, you need to dramatically increase the amount of water you drink to avoid getting dehydrated. Even though I was drinking twice as much water as I usually do, my lips still tended to get dry and chapped. On the bright side, I didn't experience any of the headaches that plague lots of people who fast.</p> <p>Overall, I found I had enough energy to do day-to-day tasks, and I experienced a high level of mental clarity. I did get the occasional feeling of dizziness, and I started to feel light-headed a few times during exertion (running or climbing stairs), but my ability to function through day-to-day activities seemed to be unimpaired. </p> <p>But my ability to carry out physical activities of any real intensity - like running - was severely impaired. I went from running 12-14 km at 10.6-7 km/h on an easy pace the week before to being exhausted going 9 km at barely 10 km/h. This was extremely instructive. </p> <p>What really surprised me was the deep pit of depression and lethargy I sank into on Wednesday. Again, I wish I had been able to go an extra day to find out whether that would pass.</p> <h4>Variations</h4> <p>This experience has transformed my relationship with food. I have a new appreciation for what it means to be hungry - <em>really</em> hungry, not just peckish or snackish or cravingish. I don't know whether I will do another extended water-only fast - and if I do, I will commit fully to taking the time to be as restful as possible. But I'm also interested in exploring some variations on fasting, like the periodic fast-mimicking diet, which reduces food intake by two-thirds for five days instead of eliminating it entirely.</p> <p>I like this approach in part because I started to become concerned about not replenishing electrolytes: sodium, potassium, magnesium, calcium and so on. I was drinking and flushing a huge amount of water, and while I didn't sweat much, I still worried that I might be putting myself in danger. A fast-mimicking diet might provide for the benefits of fasting while avoiding the dangers of an electrolyte imbalance.</p> <h3>Unity Run</h3> <p>The <a href="http://www.unityrun.org/">Unity Run</a> (formerly the Blarney Run) is an annual fundraiser for PTSD support for emergency first responders. The first year, the run started at Bayfront Park. Last year it started at Coronation Area in Westdale. This year it was held on Saturday, May 14 and started at Confederation Park in the east end.</p> <p>I had signed up for the 10.4 km run (after 10-4, the radio ten-code for "okay/understood/affirmative") and didn't do any special preparation for it since that's how far I go on my regular weekday runs. </p> <p>Race day dawned cold and miserable. I woke up to steady rainfall and a single-digit temperature. I reluctantly biked the 15 km to Confederation Park and picked up my race kit. The rain had stopped by the time I got there and the temperature crept up a few degrees.</p> <p>The run itself was a lot of fun. I didn't see anyone I knew but there was a nice camaraderie. Not particularly concerned about my finish time, I started nice and easy - around 10.5 km/h - but the run felt good and I steadily ramped up my pace. I did the last two km or so at nearly 12 km/h and ended up finishing with an average speed of 11.45 km/h, which is the second-fastest I've run a 10 km.</p> <p class="image"> <img src="/static/images/ryan_mcgreal_unity_run_2016_finish_line.jpg" alt="Photo taken at the finish line for the Unity Run" title="Photo taken at the finish line for the Unity Run"><br> Photo taken at the finish line for the Unity Run</p> <p>I have to say, the bike ride home after the race was a bit slower than the bike ride there, but all in all I enjoyed book-ending the run with bike rides. The former was a nice warm-up and the latter was a nice way to stay moving and limber.</p> <h3>Sulphur Springs Trail Race</h3> <p>My next organized run after that was the <a href="http://www.burlingtonrunners.com/races/sulphur-springs-trail-race/">Sulphur Springs Trail Race</a>. I heard about this run from friends who had signed up for the 50 km. That seemed out of my range so I signed up for the 25 km. There's also a 10 km, a 100 km and a 100 mile (160 km) route.</p> <p>I <em>really</em> enjoy trail running. I like to run at an easy pace, take my time and keep relaxed when navigating the variable surface of roots, logs, rocks, mud, dirt, grass, streams and up-and-down hills. </p> <p class="image"> <img src="/static/images/deer_on_iroquoia_heights_side_trail_2016_04.jpg" alt="Deer on Iroquoia Heights Side Trail" title="Deer on Iroquoia Heights Side Trail"><br> Deer on Iroquoia Heights Side Trail</p> <p>Instead of focusing on speed, I put in as many hours of trail running as I could. For my weekend long runs, I started venturing farther outside the comfort of the Rail Trail, which is generally wide and flat.</p> <p class="image"> <img src="/static/images/long_run_trails_map_detail.png" alt="Map detail, long run on Saturday, April 30, 2016" title="Map detail, long run on Saturday, April 30, 2016"><br> Map detail, long run on Saturday, April 30, 2016</p> <p>One route I really enjoyed was: up the Radial Trail, the side trails between Scenic and the Highway 403 footbridge, turn right on Filman Road and take the Bruce Trail east of Tiffany Falls and across Wilson Street, past Sherman falls, across Lions Club Road, up Artaban Road to the Monarch Trail, west along the trail to the Main Loop, around the loop past the Hermitage, past the Sulphur Springs Trail Centre to the Spring Creek Trail, and then back to the Rail Trail via Sanctuary Park.</p> <p class="image"> <img src="/static/images/panorama_bruce_trail_near_tiffany_falls.jpg" alt="Bruce Trail between Filman Road and Wilson Street" title="Bruce Trail between Filman Road and Wilson Street"><br> Bruce Trail between Filman Road and Wilson Street</p> <p class="image"> <img src="/static/images/bruce_trail_bridge_near_sherman_falls.jpg" alt="Bruce Trail bridge near Sherman Falls" title="Bruce Trail bridge near Sherman Falls"><br> Bruce Trail bridge near Sherman Falls</p> <p class="image"> <img src="/static/images/deer_on_radial_trail_west_of_chedoke_parking_lot.jpg" alt="Deer crossing Radial Trail west of Chedoke Golf Course parking lot" title="Deer crossing Radial Trail west of Chedoke Golf Course parking lot"><br> Deer crossing Radial Trail west of Chedoke Golf Course parking lot</p> <p>Trail running is a fantastic way to encounter local wildlife. Species I've come across include beaver, chipmunk, coyote, deer, fox, garter snake, groundhog, mouse, otter, possum, rabbit, raccoon, skunk, squirrel, vole, and of course a wide variety of birds.</p> <p class="image"> <img src="/static/images/rabbit_on_rail_trail.jpg" alt="Rabbit on the Rail Trail" title="Rabbit on the Rail Trail"><br> Rabbit on the Rail Trail</p> <p>Through the month of May, it was wonderful watching the forest come back to life after winter's dormancy. It felt like all the trees, plants and ground cover burst into greenery in a matter of days. From one week to the next, the same place looked completely different. I even got lost a couple of times because I could no longer recognize landscape features.</p> <p class="image"> <img src="/static/images/trail_off_escarpment_trail_covered_in_greenery.jpg" alt="Pathway off Escarpment Trail between Wentworth Stairs and Kenilworth Overpass" title="Pathway off Escarpment Trail between Wentworth Stairs and Kenilworth Overpass"><br> Pathway off Escarpment Trail between Wentworth Stairs and Kenilworth Overpass</p> <h4>Feeling Unprepared</h4> <p>There were a couple of practice runs in the months before the Sulphur Springs Trail Race, but I wasn't able to make it to either of them, so I kind of went into the event blind without a clear sense of just how hard these trails were going to be. I had done some running in the Dundas Valley and had tackled the Main Loop, Heritage Trail and Monarch Trail, so I hoped that the other trails that were part of the 25 km route weren't much harder. </p> <p>The starting/finish line was behind the Ancaster Community Centre at Jerseyville Road and Martin Road, so I decided I would bike the 12 km to and from the event, as I had for the Unity Run. The ride there would make a nice warmup, and I reasoned that the ride home would be mostly downhill.</p> <p>I went to bed early the night before, woke up with lots of time before having to leave, and relaxed with a big glass of water, a few spoonfuls of rice, nuts and legumes and a banana. I brought two bottles of water with me - one slung into my water belt and the other left with my bike for afterwards. </p> <h4>Homemade Food Bars</h4> <p>I also brought a homemade cashew and date bar. I used to buy Larabars to munch on during my long run but at some point it occurred to me that it probably wouldn't be that hard to make an energy bar if it only has two ingredients. </p> <p>Sure enough, I found lots of recipes online, all of them pretty similar: mix roughly equal parts cashews and dates into a food processor, process until fairly smooth, press mixture into wax paper in a brick shape, cool thoroughly in the refrigerator, then slice into individual bars and wrap in a little cellophane. You can <a href="/recipes/41">see the recipe I am using after some trial and error</a>.</p> <p class="image"> <img src="/static/images/homemade_energy_bar_sliced.jpg" alt="Homemade energy bars" title="Homemade energy bars"><br> Homemade energy bars</p> <p>I switched to homemade bars after ATB and haven't looked back. They're cheaper, taste great, are easy to eat on the run (literally) and do a nice job of supplying energy and protein when I need it.</p> <h4>The Race</h4> <p>So I left in plenty of time and biked to the starting/finish line. Race day itself was extremely hot, well into the 30s and quite humid. It was already hot at 6:30 AM - and as it was early in the year, no one was acclimatized to it yet. </p> <p>I checked in, got my t-shirt (I joke that getting t-shirts is half the reason I sign up for these things), locked it up with my bike and then paced around nervously, worrying that I would be standing in the wrong spot when the race started. </p> <p>I came across my friends who had signed up for the 50 km route, so we started the run together until the point where the two routes diverged.</p> <p class="image"> <img src="/static/images/sulphur_springs_trail_race_route_map_from_runkeeper.jpg" alt="Sulphur Springs Trail Race 25K route (from Runkeeper)" title="Sulphur Springs Trail Race 25K route (from Runkeeper)"><br> Sulphur Springs Trail Race 25K route (from Runkeeper)</p> <p>The run was lots of fun. It was damned muggy and the hills were brutal, but I didn't feel pressure to race so I just took my time and enjoyed myself. If a hill was long and steep, I walked it and took the opportunity to have a swig of water.</p> <p>It felt very convivial. Aside from the leaders, most people were there to enjoy running in the forest, so there were lots of nice conversations along the way.</p> <p>The route encompassed the Headwaters Trail, Hilltop Trail, Spring Valley Trail, Main Loop, Monarch Trail, Sulphur Creek Trail, Lookout Trail, Reforestation Trail, Old Martin Road Trail, G Donald Trail, and a short segment along Mineral Springs Road. </p> <p>By the end, I was ready not to be running any more. After crossing the finish line and getting my medal and another water bottle, I walked off the run, did some stretches and then biked home, thankful indeed that it was mostly downhill.</p> <p>According to the <a href="http://georesults.racemine.com/Burlington-Runners/events/2016/Sulphur-Springs-Trail-Races/results">race results</a>, I finished in 2:28:52 for a pace of 5:57 min/km (10.08 km/h). That put me in 65th place among the 219 25 km participants and 48th place among the 109 male participants. Once again I was in the middle of the pack, and perfectly happy with that.</p> <h3>Summer Running</h3> <p>After a relatively mild winter, we had a long, dry, not-very-warm spring this year, with only a few hot days (including the day of the Sulphur Springs Trail Race). But by mid-June, temperatures were spiking into the 30s and I remembered how gnarly it is to run in hot, humid weather. </p> <p class="image"> <img src="/static/images/iroquoia_heights_side_trail_01.jpg" alt="Iroquoia Heights Side Trail" title="Iroquoia Heights Side Trail"><br> Iroquoia Heights Side Trail</p> <p>I tend to shift my running times earlier in the day during summer. Because I start work early, on really hot days I sometimes take my lunch hour as early as 9:00 AM so that I can avoid that blistering noon-hour sun. </p> <p>My long runs tend to be easier to manage because I'm already heading out between 5:00 and 6:00 AM, before things get too hot. For my Saturday run on June 18, for example, it was only 13C when I set out - on a day that would climb into the mid-30s by afternoon. </p> <p>At the end of that run, I reached an arbitrary but symbolically important milestone: I had completed a total of 5,000 km since July 27, 2013. On that inauspicious first outing almost three years ago, I managed just 2.71 km at an average speed of 7.78 km/h or a pace of 7:43 per km. I could not even conceive back then that by this summer, I would be averaging 50-60+ km a week.</p> <h4>Hydration</h4> <p>Since this year's Bay Race, when I avoided drinking before or during the race and managed to cover the full 30 km without having to stop to pee, I've been trying to do my runs less hydrated. Despite common fears, it is arguably <a href="https://runnersconnect.net/running-nutrition-articles/overhydration-dangers-drinking-too-much-water-while-running/">easier and more dangerous to get overhydrated</a> than dehydrated.</p> <p>Instead of trying to drink my way though a hot, humid run, I'd rather reduce intensity and listen to my body. If I'm thirsty, I'll take a drink. If I'm not thirty, I won't drink just because I'm "supposed to". I've learned that I routinely lose 2-3 lbs of sweat during a 10 km and even more during a 20-25 km long run. This is a normal part of exercise and nothing to worry about.</p> <p>I also try to pick my routes so that I spend as much time as possible in the shade. That means a lot of running on forest trails, since they're the most shady - and since I'm already going more slowly from the heat, I'm not as fussed about the slower trail pace. </p> <p>I think I'm finally at the point where my ego is in check enough that I can allow myself to go slowly when it's really hot so I don't end up feeling sick.</p> <h4>New Shoes Again</h4> <p>After the middle of June, my right knee started to feel a bit quirky when I was running. This is the normal way my body tells me it's time to replace my shoes. Likewise, the outsole treads were worn down and the soles themselves had become highly pliable. As usual, this happened once the shoes had reached a total distance of around 800 km. I picked up a new pair - Mizuno Wave Riders, same as usual - on June 27 when my old pair had 815 km in total.</p> <p class="image"> <img src="/static/images/new_shoes_2016_06_27_top.jpg" alt="Top view, old shoe (left) and new shoe (right) on July 27, 2016" title="Top view, old shoe (left) and new shoe (right) on July 27, 2016"><br> Top view, old shoe (left) and new shoe (right) on July 27, 2016</p> <p class="image"> <img src="/static/images/new_shoes_2016_06_27_bottom.jpg" alt="Bottom view, old shoe (left) and new shoe (right) on July 27, 2016" title="Bottom view, old shoe (left) and new shoe (right) on July 27, 2016"><br> Bottom view, old shoe (left) and new shoe (right) on July 27, 2016</p> <p>This is my second pair of 19s. My only complaint is that the silver-white colour doesn't age well. I've got a couple of old pairs of version 18s that I now use for walking, and they still look and feel fine despite having 800 km of running <em>plus</em> several hundred km of walking on them. In contrast, the 19s start to look very grimy after a few months, even with cleaning.</p> <h4>Road to Road2Hope</h4> <p>I'd like to try at least one marathon - the classic long-distance running event, 42.2 km in length, based on the fabled messenger run from Marathon to Athens by Pheidippides in ancient Greek literature. The obvious place to start is the <a href="http://hamiltonmarathon.ca/">Hamilton Road2Hope Marathon</a>, which takes place this year on Sunday, November 6, 2016. </p> <p class="image"> <img src="/static/images/road2hope_marathon_route.png" alt="Road2Hope Marathon route" title="Road2Hope Marathon route"><br> Road2Hope Marathon route</p> <p>Until now, the longest distance I've run has been 30 km. Since the Bay Race, I've been averaging around 25 km for my long runs. I reckon that gives me a pretty good base for marathon training, but I want to build my distance up gradually so that I don't push my body too hard and cause an injury. I'm not interested in a particular speed, at least for my first marathon. I'll be quite okay if I finish it at around 10 km/h, which would give me a finishing time of around 4 hours and 13 minutes. </p> <p>Most training plans I've reviewed are 16 weeks in duration, so the time to start thinking about a November marathon is in July. The first weekend of July, I ran around 24 km for my Saturday long run, taking it easy because I woke up feeling kind of crummy. I ran up the Radial Trail, then down the Filman Road trail to Wilson Street, back along the Rail Trail to McMaster and north to the RBG trails that connect to Princess Point and the Waterfront Trail to Bayfront Park.</p> <p class="image"> <img src="/static/images/cootes_paradise.jpg" alt="Cottage country, three hours north on the highway? Nope, it's Cootes Paradise in Hamilton" title="Cottage country, three hours north on the highway? Nope, it's Cootes Paradise in Hamilton"><br> Cottage country, three hours north on the highway? Nope, it's Cootes Paradise in Hamilton</p> <p>Later that day, the friends who had encouraged me to join the Sulphur Springs Trail Race asked me if I wanted to do the Sulphur Springs 20 km loop with them on Sunday morning, easy pace. I had not done back-to-back long runs before, but I thought it would be fun to go running with my friends. I was not wrong. It was a real joy - great weather, lovely conversation, and a nice relaxing pace that didn't leave me feeling spent. </p> <p>As a result, I ran a total of 44 km in a 28-hour period. As my one friend pointed out, this was actually a pretty good way to start building marathon capacity without doing too much all at once.</p> <p>On Monday morning I woke up a bit more tired than usual, but nothing serious. My ride into work, plus a 20 km lunch-hour bike ride, shook out the cobwebs and dispelled the aches. That week, I ran a total of 65 km - the 20 km on Sunday, 10 km each on Tuesday and Thursday, and 25 km on Saturday.</p> <h4>Bruce Peninsula</h4> <p>The following two weeks I was on holiday from work. We spent the first week in a cottage of Colpoy's Bay outside of Wiarton. It was fascinating that we drove for over three hours from our house near the bottom of the Niagara Escarpment, only to end up at a cottage near the bottom of the Niagara Escarpment.</p> <p class="image"> <img src="/static/images/niagara_escarpment_colpoys_bay.jpg" alt="Niagara Escarpment south of Colpoy's Bay" title="Niagara Escarpment south of Colpoy's Bay"><br> Niagara Escarpment south of Colpoy's Bay</p> <p class="image"> <img src="/static/images/looking_across_colpoys_bay_at_sunset.jpg" alt="Looking across Colpoy's Bay at sunset: the Niagara Escarpment also runs along the opposite shore" title="Looking across Colpoy's Bay at sunset: the Niagara Escarpment also runs along the opposite shore"><br> Looking across Colpoy's Bay at sunset: the Niagara Escarpment also runs along the opposite shore</p> <p>Of course, the Bruce Trail also runs along the Niagara Escarpment on its meandering course between Niagara Falls and Tobermory. I went for a few early-morning runs during our week there, and I got to experience the novelty of running along the Bruce Trail several hundred kilometres from the Bruce Trail sections I normally run.</p> <p class="image"> <img src="/static/images/bruce_trail_near_wiarton.jpg" alt="Bruce Trail around 15 km east of Wiarton" title="Bruce Trail around 15 km east of Wiarton"><br> Bruce Trail around 15 km east of Wiarton</p> <p>The trail was nice (notwithstanding the ravenous deerflies), but I have to say that a rural roadway is pretty much my least-favourite surface for running. You have to run on the road because there's no sidewalk or shoulder, and you have to stay on the left side so you can see oncoming traffic. However, the road is cambered (lower on the sides than the centre) for drainage, so your left foot has to come down just a bit lower than your right foot. </p> <p>Over a 12-15 km distance and 12,000-15,000 steps, that imbalance really starts to add up and can lead to injury. Paved paths are also cambered, but it's much safer to mix things up and run on different sides of the path.</p> <h4>Ramping Up, Carefully</h4> <p>The past three weeks I have run over 60 km a week. On the Friday of my second vacation week, my right knee was feeling tweaky, with tightness up and down the outside. (I also noticed a lot of tightness in this leg during the drive to and from the cottage the previous week. Yay middle age.) </p> <p>Not wanting to get caught with patellofemoral pain syndrome (runner's knee), I realized this was my body's way of telling me to back off a bit on the distance, spend more time massaging my legs with the foam roller, and get more proactive about strengthening and balancing my muscles so my kneecap stays where it's supposed to be. </p> <p>Like most running injuries, runner's knee is not a problem with the knee itself but rather a weakness in the kinetic chain that works together to produce running. The way to prevent and treat runner's knee is with exercises that strengthen hip abductors, glutes and quads - exercises I haven't really been doing up to now. </p> <p>I iced my knee and gave it a thorough massage on Friday night, and it felt fine on my long run the following morning. I've been massaging my legs every night since then, and aside from a very occasional twinge, it has not troubled me since. However, it's definitely something to keep an eye on. </p> <p class="image"> <img src="/static/images/small_ruin_filman_road_trail.jpg" alt="Small ruin on the side of the Filman Road trail" title="Small ruin on the side of the Filman Road trail"><br> Small ruin on the side of the Filman Road trail</p> <h3>Conclusion</h3> <p>The following table summarizes the total distance run and calories burned by year for my first three years of <a href="/running">running</a>:</p> <table> <caption>Total Distance and Calories by Year</caption> <thead> <tr> <th>Year</th> <th>Distance (km)</th> <th>Calories</th> </tr> </thead> <tbody> <tr> <td>1</td> <td>1,325.21</td> <td>155,468</td> </tr> <tr> <td>2</td> <td>1,463.20</td> <td>149,437</td> </tr> <tr> <td>3</td> <td>2,539.66</td> <td>244,302</td> </tr> <tr> <td>Total</td> <td>5,328.07</td> <td>549,207</td> </tr> </tbody> </table> <p>Year three is the first time I have managed to avoid getting sidelined by injury, and I've been able to ramp up my total distance in a sustainable manner, mainly by doing most of my running at a lower intensity. In fact, early in 2016 I increased the number of weekly runs from three to four.</p> <p>On the other hand, I'm <a href="/biking">biking</a> rather a lot less than I was last year. When I was injured in late 2014 and again in mid-2015, I switched to biking as an alternative aerobic exercise that would allow me to maintain fitness and keep burning calories while I was unable to run, or only able to run short distances. </p> <p>Last summer, I was averaging around 133 km a week on my bike, enjoying some long weekend rides of 50-65 km. This summer, in contrast, I'm putting most of my energy into running and only biking for an hour or so, two or three times a week. </p> <p>Still, it all adds up. In the past 12 months, I've biked 3,789 km and burned a total of 129,614 calories on rides that were long enough to bother tracking. (I don't bother tracking rides shorter than around five km.)</p> <p>Meanwhile, the <a href="/blog/161/a_year_of_walking">pedometer I received in October 2014</a> is still working, and I've been <a href="/stepcounts">recording my total steps each day</a> ever since. Between walking, running, pedalling a bike, marching in place and boogeying at my standing desk, I've logged a total of almost 14 million steps in the past 21 months, for an overall average of 21,500 steps a day and a rolling past-90-days average of 28,408 steps a day.</p> <p>This is an excellent case in the power of incremental growth over time: when I first started wearing the pedometer, I was averaging less than 10,000 steps a day, which means I have almost tripled my average number of daily steps over a period of less than two years.</p> <h4>Weighing Weight</h4> <p>One other thing I have recently started tracking is my weight. When I first started trying to get into shape, I decided not to get a scale because I didn't want to obsess about my weight. Instead, I wanted to focus on gradually and incrementally changing my daily habits of activity and to trust that changes to my weight and body shape would follow.</p> <p>I went into this knowing that most attempts to get in shape, lose weight, change habits and so on fail - but some succeed. I wanted to understand why that is, and what is different about the attempts that are successful. Some core principles emerged, and they became my touchstones:</p> <ul> <li><p>Most behaviour is habitual, not deliberate. Changing a particular behaviour entails establishing a new habit - and doing so in such a way that the old habit you want to stop is pre-empted.</p></li> <li><p>Attempts to change behaviour through willpower will fail. People just don't have a lot of willpower. Instead, create an environmental context that provides cues to do the new behaviour.</p></li> <li><p>Building a new habit requires lots of consistent repetition over a period of months before it becomes established.</p></li> <li><p>Implementing a small change is more likely to succeed than implementing a big change. But a small change, implemented consistently and then gradually increased, adds up to a big change.</p></li> <li><p>Making one change at a time is more likely to succeed than making several changes at once. Start a new habit, repeat it consistently until it is established, and <em>then</em> start on the next change. This is a long-term project!</p></li> </ul> <p>Over time, as you run up against the limits of a particular change, you have an opportunity to incorporate other, complementary changes in the same manner. In addition to running, I gradually added cross-training, stretching, strengthening exercises, more walking, standing at work, and a series of changes to my diet - both what I eat and when I eat it.</p> <p>In early 2013, I was in the vicinity of 260 lbs - dangerously obese. I believe regularly weighing myself at that time would have been more discouraging than anything else, since the small changes I was making early in the process of changing my lifestyle had only a small proximal impact on my weight, and I wanted to focus on the long term.</p> <p>Three-plus years later, I'm in a different situation. My lifestyle and diet are dramatically different than they were when I started, I'm burning 6-8,000 calories a week in exercise, and the accumulated effects of all these changes have had a major impact on my body shape. I believe that if you want to manage something, you need to measure it, and I'm at the point where the benefits of managing my weight outweigh (pun intended) the risk of discouragement.</p> <p>I've been weighing myself once or twice a week since late April, and aside from the days immediately following my fast, my weight has fluctuated in a range 3-4 pounds around 180 lb. </p> <p class="image"> <img src="/static/images/weight_2016_04_28_2016_07_25.png" alt="Chart: weight measurements between 2016-04-28 and 2016-07-25" title="Chart: weight measurements between 2016-04-28 and 2016-07-25"><br> Chart: weight measurements between 2016-04-28 and 2016-07-25</p> <p>For my height and gender, the Body-Mass Index (BMI) chart says my healthy weight range is between 140 and 189 lbs. I shudder to think of how emaciated I would look at 140 lbs, but I feel that a healthy weight for me is in the 170-180 lb range, so I'm on the high end of where I want to be. </p> <p>I've still got a bit of a paunch that I'd like to reduce over time, and I believe I can get there my maintaining a healthy diet (I ate a lot of junk during my two weeks' vacation) and incorporating more strength-building exercises. My next significant change is going to be adding a program of weight-lifting, and as usual I'm going to start small and gradually build up.</p> Ryan McGreal 2 http://quandyfactory.com/site/24/home 2016-05-11T12:00:00Z Home <p style="float: right; margin-left: 5px;"><img style="border: 1px solid black;" src="/static/images/ryan_mcgreal_headshot_2016_05_11_sm.jpg" alt="Ryan McGreal" title="Ryan McGreal"></p> <p>This is the personal website of Ryan McGreal in Hamilton, Ontario, Canada. </p> <p>I live with my family and work as a programmer and writer. I am the editor of <a href="http://raisethehammer.org">Raise the Hammer</a> and volunteer with <a href="http://hamiltonlightrail.ca/" target="_blank">Hamilton Light Rail</a>, a citizen group dedicated to bringing light rail transit to Hamilton. </p> <p>Several of my <a href="/essays/">essays</a> have been published in the <cite>Hamilton Spectator</cite>.</p> <p>This website serves mainly as a handy repository of <a href="/essays/">published essays</a>, <a href="/projects/">active projects</a>, <a href="/blog/">random musings</a> and <a href="/links/">links</a> that I work on on or use frequently. It's also an online playground where I can try out new ideas.</p> <p>For a much more detailed introduction to the site and its subject matter, check out the <a href="/about/">About</a> page.</p> <p>Otherwise, feel free to contact me via email: <a href="mailto:ryan@quandyfactory.com">ryan@quandyfactory.com</a>.</p> Ryan McGreal 2 http://quandyfactory.com/site/13/about 2016-05-11T12:00:00Z About <h3>Introduction</h3> <p>My name is Ryan McGreal, and I live in Hamilton, Ontario, Canada with my family. I work as a web programmer, consultant, writer, editor and troublemaker, though it's mostly the programming that pays the bills. </p> <h4>Raise the Hammer</h4> <p>My principal activity that <em>doesn't</em> pay the bills is my role as editor of <a href="http://raisethehammer.org">Raise the Hammer</a>, an online magazine dedicated to sustainable urban revitalization in Hamilton. </p> <h4>Hamilton Light Rail</h4> <p>I am also a proud founding member of <a href="http://hamiltonlightrail.ca">Hamilton Light Rail</a>, a community group dedicated to bringing light rail transit to Hamilton.</p> <h4>Published Essays</h4> <p>I have written several essays on urban issues that have been published in the <em>Hamilton Spectator</em> and elsewhere over the past five years.</p> <h4>Contact</h4> <p>You can reach me via email at <a href="mailto:ryan@quandyfactory.com">ryan@quandyfactory.com</a> or on twitter <a href="https://twitter.com/RyanMcGreal">@RyanMcGreal</a>.</p> <h3>This Site</h3> <p>This is my personal website, repository of essays and projects, and playground for new ideas. </p> <p><em>Quandy</em> is a portmanteau of "Quick and Dirty", which can be a useful method of approaching problems. "Quick and dirty" has the benefit of being, well, quick, as well as flexible for those cases when initial requirements end up changing (i.e. just about every nontrivial project). </p> <p>It suggests an iterative approach, on the reasoning that it's easier to build something simple and then make it better than it is to try and spring a fully-formed application from your forehead. </p> <p>As John Gall famously stated: </p> <blockquote> <p>A complex system that works is invariably found to have evolved from a simple system that worked. The inverse proposition also appears to be true: A complex system designed from scratch never works and cannot be made to work.</p> </blockquote> <h3>Eye Quandy</h3> <h4>Quandy Logo</h4> <p>The red Quandy logo in the top left corner is courtesy of <strong>Trevor Shaw</strong>, a great local graphics designer and the creative director of <a href="http://www.getjuice.ca/">Juice Creative</a>.</p> <h4>Footer Image</h4> <p>The awesome cityscape panorama in the footer was taken by the talented photographer and amateur urbanist <strong>Aaron Segaert</strong>, and is used with permission.</p> <h3>Interests</h3> <p>In recent years I have been particularly interested in: the nature of city economies and urban development; the role of public participation and community engagement in creating and sustaining a healthy society; and ways to increase the openness, transparency and responsiveness of organizational governance and policy making.</p> <h4>Conceptual Overlap</h4> <p>I admit that my ideas about openness in government and policy making reflect my experience using and developing software: an open, information-sharing approach with peer review results in better results than a closed, proprietary approach based on blind trust.</p> <h4>Jack of All Trades</h4> <p>My interests take me all over the place, figuratively, from land use patterns and transportation modes to the global energy situation, geopolitics, social policy, economics and political economy, democratic structures and traditions, broad-based community organizing, local politics and current affairs, architecture, city life, ecology, sustainability, cognitive psychology, and more.</p> <p>I don't claim expertise in any of these areas, but I am committed to studying the experts and following empirical best practices in these domains. </p> <h4>Benefit from Shared Expertise</h4> <p>The great thing about living in an open, knowledge-based culture is that you can benefit from the expertise of others. Once you establish the credibility of expertise, you can use it as a kind of knowledge <a href="http://en.wikipedia.org/wiki/Application_programming_interface">API</a> that allows you to take advantage of the expertise without necessarily knowing everything about the internals.</p> <p>If not for this ability for non-experts to access expertise, there would be no way for the benefits of that expertise to disseminate into the broader society and inform our policy decisions.</p> <h3>Programming</h3> <p>I enjoy programming and have benefited immensely from the vast, rich ecosystem of free and open source software available to programmers today (see "Technical Notes", below).</p> <h4>Great Time for OK Coders</h4> <p>I know enough about great programmers and their remarkable contributions to understand that I am not a great programmer. Nevertheless, the rich ecosystem of programming languages, libraries, frameworks and tools means even a duffer like me can be creative and productive - and that's a <a href="http://c2.com/cgi-bin/wiki?GoodThing">Good Thing</a>.</p> <h4>Productive Modern Languages</h4> <p>One of the great things about modern programming languages is how highly expressive they are. You can create working code very efficiently, with a minimum of boilerplate. </p> <p>That means it's easy to develop simple tools that do exactly what you want them to do and no more - and to do them quickly.</p> <h4>Shared Open Source Software</h4> <p>Recently I have begun releasing a few such handy tools under a free software / open source licence. You can find my shared resources hosted on <a href="http://github.com/quandyfactory">GitHub</a>. </p> <p>The code isn't beautiful, but I'm <a href="http://code.google.com/events/io/sessions/MythGeniusProgrammer.html">no genius</a>.</p> <h3>Website Development</h3> <p>I do a bit of freelance web application development. Feel free to contact me via email at <a href="mailto:ryan@quandyfactory.com">ryan@quandyfactory.com</a> to inquire about services and rates.</p> <h3>Technical Notes</h3> <p>There's no particularly good reason why I didn't simply use WordPress or Drupal or some other off-the-shelf blogging software for this site; except that I enjoy building things (also, PHP makes the baby Jesus cry). </p> <p>Anyway, it's not like I built the site from scratch.</p> <ul> <li><p>It runs on <a href="http://nginx.org/en/">nginx</a> and <a href="http://www.apache.org/">Apache</a> on a <a href="http://www.centos.org/">CentOS</a> <a href="http://www.linux.org/">Linux</a> machine hosted by the awesome admins at <a href="http://webfaction.com?affiliate=hammertime">WebFaction</a>. </p></li> <li><p>It is written in the <a href="http://python.org">Python programming language</a> and uses the lightweight <a href="http://webpy.org">web.py</a> application development framework. </p></li> <li><p>Web.py talks to Apache via the <a href="http://code.google.com/p/modwsgi/">mod_wsgi</a> server module, which implements the standard <a href="http://www.wsgi.org/wsgi/">Web Services Gateway Interface (WSGI)</a> specification for Python applications to communicate with web servers.</p></li> <li><p>The site stores its documents in a <a href="http://dev.mysql.com/">MySQL</a> database, to which it connects via the ingenious <a href="http://www.sqlalchemy.org/">SQLAlchemy</a> database toolkit and object-relational mapper (ORM).</p></li> <li><p>Documents are saved in <a href="http://daringfireball.net/projects/markdown/">Markdown</a> syntax and converted to HTML for display using the <a href="http://code.google.com/p/python-markdown2/">python-markdown2</a> library (which is itself a re-implementation of the original <a href="http://www.freewisdom.org/projects/python-markdown/">python-markdown</a> library).</p></li> <li><p>It also uses <a href="/projects/5/quandy">Quandy</a>, a library of handy classes and functions that I use frequently in writing web code. </p></li> </ul> <p>In other words, I'm sitting here on the shoulders of giants - and the view is grand!</p> Ryan McGreal 2 http://quandyfactory.com/blog/167/what_you_need_to_know_to_start_running 2016-04-06T12:00:00Z What You Need to Know to Start Running <p>A staggeringly large amount of information is available to runners and would-be runners today - possibly too much, given the potential to feel overwhelmed by it all. There is information you need to get started, and there is information you don't need until you encounter specific issues, and it's not always clear which is which.</p> <p>So without any claim whatsoever to expertise - I'm just a middle-aged duffer who started running two and a half years ago and has had to learn lots of things along the way - here's my take on what you need to get started running.</p> <h3>Equipment</h3> <p>There is an embarrassment of apparel, gear, equipment and assorted accoutrements available for running, but when you're just getting started you can safely ignore most of it. Given the short distances and low speeds you'll be running for at least the first two or three months, it really doesn't matter what clothes you wear. Regular clothes will be just fine at the beginning. </p> <p>(Later, when you've gotten established and are running longer distances, you can go to the running store and start your collection of synthetic, stretchy, moisture-wicking, water bottle-holding, fluorescent-glowing, heart rate-monitoring running stuff.)</p> <h4>Running Shoes</h4> <p><strong>On day one, the only equipment you really need is a good pair of running shoes.</strong> </p> <p>Here's the secret of how to pick a good pair of running shoes: go to a running shoe store and try on a variety of different pairs of shoes from various brands and types. Choose the pair that feels the most comfortable. <em>That's all there is to it.</em></p> <h4>Select for Comfort</h4> <p>The salesperson might try to do a gait analysis and tell you that you should be wearing this or that particular type of shoe (arch support! stability! motion control!), but <a href="http://well.blogs.nytimes.com/2015/08/05/choosing-the-right-running-shoes/">the evidence indicates</a> that comfort, not some set of technical criteria, should be the deciding factor.</p> <blockquote> <p>Perhaps most unexpected, running shoes designed to somehow "fix" someone's running form turned out often to be ineffective and even counter-productive. In a series of studies, when military recruits were assigned running shoes meant to control their particular level of pronation, those soldiers were as likely, or even more so, to sustain running-related injuries than soldiers given shoes at random. [...]</p> <p>What matters, the researchers conclude in their review, is comfort. In one study from 2001 (overseen by Dr. Nigg), researchers asked soldiers to try six shoe inserts, which varied in terms of cushioning, arch height, heel shape, thickness and other variables. The soldiers were asked to pick the one insert that felt the most comfortable to them and wear that insert inside their shoes during their subsequent military training. A separate group of soldiers wore standard footwear as controls.</p> <p>After four months, the soldiers wearing the shoes fitted with inserts that felt comfortable to them had a much lower incidence of injury than those wearing standard shoes.</p> <p>This finding makes scientific and common sense, Dr. Nigg said. Our bodies are actually "very good judges" of how each of us should move and run, he said. When we ignore or fight our bodies' natural movement pattern, he said, such as by trying to control pronation, the risk of injury rises.</p> </blockquote> <p>So don't overthink it and don't let someone pressure you into a particular type of shoe that doesn't feel comfortable.</p> <h3>Understand How Adaptation Works</h3> <p>Your body is capable of astonishing physical accomplishments, but it takes time and patience. It really helps to understand how your body gets from here to there. </p> <h4>Stress Response</h4> <p>When you begin a new program of exercise like running, what you are really doing is subjecting your various body systems to <em>physical stress</em>. </p> <p>That stress damages your muscles, connective tissues, bones and so on. Your body responds, not surprisingly, with the biological <em>stress response</em>: your hypothalamus signals your pituitary gland, which dispatches chemical messengers throughout your body. </p> <p>The result is increased heart rate, faster breathing, glucose released into bloodstream, elevated levels of cortisol and other stress markers, increased blood flow to stressed body systems, and so on.</p> <h4>Stronger, More Resilient</h4> <p>When your body repairs the damage of moderate exercise, the repaired body systems are left slightly stronger and more resilient than before they were exposed to stress. This is called <em>adaptation</em> - your body responds to moderate stress by adapting to it. </p> <p>Over a period of weeks and months, the following adaptive changes will progressively take place:</p> <ul> <li>Your lungs learn to draw in more air and to exchange oxygen and carbon dioxide more effectively.</li> <li>Your heart becomes stronger and more efficient at pumping blood.</li> <li>Your cardiovascular system gets better at delivering oxygen and nutrients to your muscles and dissipating heat through your skin.</li> <li>Your muscles learn to create more energy and provide more power for longer periods.</li> <li>Your tendons, ligaments, joints, fascia and other connective tissues learn to absorb and release energy more effectively.</li> <li>Your bones become stronger and more resilient.</li> </ul> <p>(Along the way, your body generally becomes more effective at responding to other stressors, an ancillary benefit that can really improve your quality of life when things go wrong.)</p> <h4>Moderation and Recovery</h4> <p>The key here is that the stress must be <em>moderate</em>. Too little stress and your body is not motivated to undergo adaptation. Too much stress and you get a more serious injury that requires several days, weeks or even months to heal. </p> <p><strong>You want a level of stress that your body can recover from in a day or two.</strong></p> <p>As a corollary to this, your <em>recovery time</em> is every bit as essential to increasing fitness as your exercise. </p> <blockquote> <p>Fitness = exercise + recovery</p> </blockquote> <p>If you skip the recovery time, your body just breaks down instead of building up.</p> <h4>Muscle vs. Connective Tissue</h4> <p>The other important thing to understand here is that some body systems adapt more quickly than others. Your respiratory and circulatory systems and muscles adapt very quickly - within a few weeks, you'll be amazed at how much farther you can go before getting out of breath - but your bones and connective tissues take a lot longer to adapt. </p> <p>All of the most common running injuries - shin splints, tendonitis, fasciitis, IT band syndrome, runner's knee, stress fractures (yikes!) - are injuries of connective tissues or bones that result from doing too much too soon instead of giving these slow-changing systems enough time to adapt. </p> <p>The good news is that these injuries are more or less preventable.</p> <h3>Ten Percent Rule</h3> <p>If Running has a Golden Rule, it's the Ten Percent Rule: <strong>never increase your total week-over-week distance by more than a <em>maximum</em> of ten percent</strong>. This is a universal, rock-solid principle of safe running proven by decades of research and experience. Ignore it at your peril!</p> <p>After a few weeks of progress, you <em>will</em> feel like you can go farther faster, because your heart, lungs and muscles are telling you they're up for it. This is a recipe for injury when your tendons, ligaments, fascia and bones can't keep up with the pace of change.</p> <p>Not only do those systems take longer to adapt, but if you do get injured, they also take longer - a <em>lot</em> longer - to recover. In this case, an ounce of prevention really is worth a pound of cure. Follow the Ten Percent Rule and avoid getting sidelined for weeks or even months.</p> <h4>Example Running Program</h4> <p>Here's how a running program that follows the Ten Percent Rule might look:</p> <ul> <li>Week 1: 3 runs at 2.5 km (7.5 km total distance)</li> <li>Week 2: 3 runs at 2.75 km (8.25 km total distance)</li> <li>Week 3: 3 runs at 3.0 km (9 km total distance)</li> <li>Week 4: 3 runs at 3.33 km (10 km total distance)</li> <li>Week 5: 3 runs at 3.66 km (11 km total distance)</li> <li>Week 6: 3 runs at 4.0 km (12 km total distance)</li> <li>Week 7: 3 runs at 4.4 km (13.2 km total distance)</li> <li>Week 8: 3 runs at 4.8 km (14.4 km total distance)</li> <li>Week 9: 3 runs at 5.2 km (15.6 km total distance)</li> </ul> <p>When you start out, don't expect to be able to run the whole distance. In fact, if you are new to running, I recommend against running the whole way even if you feel that you can. </p> <p>Instead, start with a brisk walk to warm up, then run for, say 30-60 seconds, followed by 30-60 seconds of walking. Alternate walking and running for the full distance so that your body gets the benefit of micro-rest between bouts of running.</p> <h4>Rest Days</h4> <p><strong>Avoid running on successive days.</strong> Instead, make sure to give your body a day off between runs. On your rest day, go for a nice walk instead - the motion helps reduce stiffness and soreness. </p> <p>In general, walking is almost magical in its ability to heal your body and make you feel better. Walking is the most fundamental human movement and it's probably not overstating the case to call it the foundation for all of the higher-intensity exercises that build strength and endurance. </p> <p>Never underestimate the physical, mental and emotional value of a good walk.</p> <h4>Ten Percent is a Maximum</h4> <p>And remember: the Ten Percent Rule is a <em>maximum</em> weekly increase. If your shins flare up, or you feel an unpleasant twinge in your heel or an ache in your knee or anything else other than the general muscle soreness that can be expected with a new physical activity, back off right away. </p> <p>Apply ice to the affected area, rest, stretch, give yourself an extra day off before the next run, reduce your distance and speed and reassess whether it still hurts.</p> <p>If you are running properly and your body is adapting well, <em>you will not feel pain</em> other than muscle soreness. The saying, "No Pain, No Gain" is dangerous nonsense. If you do feel pain, it means something is wrong! Listen to your body.</p> <h3>Exercise</h3> <p>While we're on the subject of injury prevention, it is not enough to just run. If you don't also do other exercises to support your running, your body will become unbalanced and you will get hurt. </p> <h4>General Strength</h4> <p>Here is a basic set of exercises you should do to keep your body balanced and fit and avoid injury:</p> <ul> <li><strong>Calf raises</strong> - indispensable for strengthening your calves and avoiding tendinitis</li> <li><strong>Squats</strong> - strengthen your glutes and thigh muscles and posture to maintain stability when running</li> <li><strong>Lunges</strong> - strength and flexibility through your legs and hips</li> <li><strong>Mountain Climbers</strong> - strengthen quads and calves, improve flexibility, increase core stability</li> <li><strong>Planks</strong> - a strong core makes for better posture and more stable running form</li> <li><strong>Push-ups</strong> - strong core and good form encourages more efficient arm swing</li> <li><strong>Static calf and hamstring stretches</strong> - do these after a run, not before</li> </ul> <h4>Focus on the Feet</h4> <p>There are also several great exercises that specifically strengthen the feet:</p> <ul> <li>Lay a towel on the floor and grab it with your toes, pulling it toward you.</li> <li>Place some marbles on the floor. Pick them up with your toes and place them in a bowl.</li> <li>If you're sitting around, take the opportunity to rotate your feet clockwise and counter-clockwise and wave them back and forth like windshield wipers.</li> </ul> <p>Here's a great exercise that only takes a minute, so try to do it every day: </p> <ul> <li>Stand on one foot and lift the other leg so that your thigh is horizontal to the floor. Balance for 30 seconds, then switch feet. (As you get better at it, try waving your arms around to try and throw yourself off-balance.)</li> </ul> <p>This exercise strengthens the stabilizing muscles in your feet and ankles and reduces your risk of injuries on uneven ground.</p> <h4>Cross-Training</h4> <p>I also strongly recommend that you incorporate some cross-training with another cardio exercise that works different muscle groups and is lower impact than running: cycling, swimming, rowing, stair climbing, etc. </p> <p>Doing this will reduce any development imbalances you have. It also provides a built-in way to maintain cardio fitness if you do get injured, so that you don't become discouraged and give up.</p> <h4>Get in Shape to Run</h4> <p>You may be groaning right now. I certainly did when I was advised to do these things by my running coach. <em>Ugh, I just want to run!</em> </p> <p>A couple of years ago, a friend told me: "I don't run to get in shape, I get in shape to run." I didn't understand this statement at the time, but I have come to understand it after dealing with a succession of foot injuries that resulted from a combination of violating the Ten Percent Rule and not doing enough ancillary strength exercises. </p> <p>The exercises you need to do to recover from the various -itises happen to be the same exercises you need to do to prevent them in the first place. Don't wait until you've already gotten injured to start doing them!</p> Ryan McGreal 2 http://quandyfactory.com/blog/161/a_year_of_walking 2016-01-20T12:00:00Z A Year of Walking <p>One year ago, at a health conference in Toronto, I received a pedometer as part of my attendee swag bag. Curious about how much I walked in a day, I strapped it onto my belt and decided to start tracking my daily step counts. </p> <h3>The Pedometer</h3> <p>The pedometer is a Piezo SC-StepRX model, which advertises a "medical grade piezoelectric mechanism" and seems like a pretty solid product. I haven't particularly done a lot of research to see how it measures up to other models, but at least one <a href="http://www.biomedcentral.com/1471-2458/14/519">published academic study</a> concludes, "This study demonstrates that the SC-StepRx pedometer is a valid tool for the measurement of moderate and vigorous physical activity in children and youth."</p> <p>One handy feature is that it keeps track of the past 34 days, so if you forget to record a day's results, you can always go back. I also like the fact that it clips on your belt and has an additional safety strap with an alligator clip, which has saved me from losing it on more than one occasion.</p> <p>It certainly seems to be quite accurate. I've taken walks where I counted my steps and when I compared the stepcounter, it was within a few steps of what I counted. </p> <p>At the same time, it doesn't seem inclined to register stray movements as steps. It appears to need up-and-down <em>and</em> back-and-forth movement to count a step. I don't drive much, but in any case the pedometer doesn't seem to register bumps in the road while driving, so I don't earn "phantom" points during the times I'm jostling around on Hamilton's streets.</p> <p>Very, very occasionally, it seems to get hung up and stops counting steps, but that has only happened a few times.</p> <h3>Why I Started</h3> <p>As for why I decided to start using it, aside from the obvious reason that I had nothing to lose by wearing a pedometer I had received for free, I'm a strong believer that if you want to manage something, you need to measure it. The mere act of tracking a given measurement tends to draw your attention to it and motivate you to take action to move the results.</p> <p>So I started wearing it every day and tracking how much I walked. At first, my stepcounts weren't all that impressive. Other than days when I went for a run, I was averaging less than 10,000 steps a day - sometimes <em>far</em> less.</p> <p>Then I injured my foot on November 11 and had to stop running altogether for a few weeks. I was walking slowly and deliberately to avoid limping, and I was managing just 6-7,000 steps a day. <a href="https://youtu.be/_rjmV-Rh130?t=15">Mediocre!</a></p> <p>Since I wasn't running (or running much, even when I started again), I committed myself to walking more. Having a daily recording of how I was doing allowed me to try out techniques for increasing my amount of walking and noting which ones worked well.</p> <p>I made a point of walking to work every day. That's a two-kilometre trip, so walking to work and back is 4,000 or so steps right off the top. Previously, I would tend to ride my bike to work because it meant I could sleep in an extra ten minutes.</p> <h3>Standing Desk</h3> <p>I also had a stand-up desk and hadn't really been making very effective use of it. I decided to set it permanently in standing mode and commit to being upright the entire day. This produced several changes, most of them positive.</p> <ul> <li><p>At first, I would be tired and sore at the end of the day. My legs and the small of my back would ache, and I felt exhausted. However, I had fully acclimatized to standing within a month.</p> </li> <li><p>Because I was already standing, I became more inclined to walk away from my desk, whether to get a drink of water, meet with a colleague, or walk around the block to clear my head.</p> </li> <li><p>I started taking the stairs. It's 94 stairs from the ground floor to my office, and when I first started taking the stairs I'd be fairly out of breath by the time I finished. It gradually became easier, and I've had to seek out taller staircases, like the various Escarpment Stairs in Hamilton, to wind me.</p> </li> <li><p>I could practice the <a href="http://www.huffingtonpost.com/2014/06/04/100-up-running_n_5406664.html">100-Up Drill</a>, which really helped both my injury recovery and my running form. I even taped a line in front of my desk so I could make sure I was landing in the right spot.</p> </li> <li><p>I often wear noise-cancelling headphones so I can concentrate. I've found that electronic music is great for focusing on writing code, but an ancillary benefit is that I find myself moving to the rhythm and dancing in place, which may prevent some of the problems that go with standing for long periods. </p> </li> <li><p>I also noticed that when my grooving became vigorous and incorporated steps and hip movement, my pedometer would register some of the movement as stepping. Since I was upright and moving actively, I decided to allow it to contribute toward my daily total.</p> </li> </ul> <p>One possible negative is that standing all day with plantar fasciitis may have delayed my recovery. However, over the longer term I have become so comfortable with a standing (and walking, and dancing, and so on) that I actually can't imagine sitting again. I don't know how I did it for so long, slouching for hours, taking shallow breaths with my spine curved and my chest sunken.</p> <h3>Upward Trend</h3> <p>As I introduced more and more of these activities into my routine, my daily stepcounts started trending upward, also boosted by my recovering running distance. Even when I was still running short distances, I tried to pad the workout by adding walking before and after the run.</p> <p>Early this year I also started incorporating bike rides into my routine, and I noticed that an hour of hard cycling would register as around 7,000 steps on my pedometer. It seems to register the pedaling action of my legs and hips as steps, which seems fair to count. In addition, 7,000 is around the same number of steps as an hour of brisk walking, so I decided to include these in the total as well.</p> <p>I've also become progressively more inclined to walk for as many errands as possible. Whereas I might have hopped on my bike or a <a href="https://hamilton.socialbicycles.com/">Hamilton Bike Share</a> to go to the grocery store after work, I started walking the full distance instead, adding a few kilometres to my daily commute.</p> <p>I also became a lot more willing to make trips instead of avoiding them. Even for something as simple as taking the food waste out to the green bin, I'll make three or four trips with various plates and bowls rather than dumping everything onto one plate in order to get out of extra walking. </p> <p>It became a game: the goal of increasing my stepcount for the day came to overrule my <em>default work-avoidance setting</em>. When getting ready to go to bed at night, if I was close to my target for the day I would literally walk around the room racking up steps until I hit the goal.</p> <h3>Steady Increase</h3> <p>Over the past twelve months, my average daily stepcount has steadily increased from less than 10,000 to more than 20,000. Here's a chart of every daily total with a linear trendline for the past year:</p> <p class="image"> <img src="//i.imgur.com/zX75bHo.png" alt="Steps per day with trendline, 2014-10-23 - 2015-10-22" title="Steps per day with trendline, 2014-10-23 - 2015-10-22"><br> Steps per day with trendline, 2014-10-23 - 2015-10-22</p> <p>A graph of weekly totals shows the same general upward trend through the expected variation from week to week. (Note: the two very low weeks around 2014-52 are an artifact of the weekly grouping function in the database I used, as it groups December 28-31 as a week and January 1-3 as a new week.)</p> <p class="image"> <img src="//i.imgur.com/fycQtkI.png" alt="Steps per week" title="Steps per week"><br> Steps per week</p> <p>For the past several weeks I seem to have plateaued around 170,000 steps a week, and to be honest that seems like a pretty reasonable peak. As the weather gets colder it might even decline slightly, especially as my weekly cycling distance goes down. </p> <p>On the other hand, I am signed up for the 30 km <a href="http://bayrace.com/">Around The Bay Road Race</a> next April and plan to continue running steadily longer distances through the winter. I also plan to continue commuting on foot and going for brisk walks on days when it's too lousy out to cycle.</p> <h3>One Year On</h3> <p>The pedometer, now a year old, still seems to be holding up nicely despite some visible wear and tear. I had the battery replaced in October, not because the old one died but because we were leaving <a href="https://raisethehammer.org/article/2707/bicycle-friendly_paris_refuses_to_stand_still">to go to Paris</a> for a week and I became paranoid that the battery would die when we were there. Paris is an exceptionally walkable city and I wanted to know just how much walking we actually did there.</p> <p>So over exactly a year of tracking how much I walk, I have taken a total of 6,142,895 steps for a year-long average of 16,830 steps a day. That total includes walking, running, vigorous dancing, aerobic exercise and cycling and, duh, I haven't been taking it to the paint store and attaching it to the paint can shaker.</p> <p class="image"> <img src="//i.imgur.com/GJspd5Y.jpg" alt="Pedometer count for October 16, 2015" title="Pedometer count for October 16, 2015"><br> Pedometer count for October 16, 2015</p> <p>Here's to another year of putting one foot in front of the other!</p> Ryan McGreal 2 http://quandyfactory.com/blog/155/a_second_year_of_running_plus_some_not-running_and_other_stuff 2015-07-30T12:00:00Z A Second Year of Running, Plus Some Not-Running and Other Stuff <h3>Introduction</h3> <p>A year ago today, I posted my first article <a href="/blog/135/a_year_of_running">reviewing a year of running</a>. I had a fantastic year and accordingly the article had a celebratory tone. I was going faster and farther week over week and had been doing so almost continuously for the entire year, notwithstanding a short early setback when I had shin splints.</p> <p>I was pushing the limits pretty hard on both distance and speed, chasing continued week-over-week increases along both axes. In January of 2014 I was running around 20 km a week. By April I was up to 35 km a week, and by June I was up to 40. That increased throughout the summer and by October I was doing 48-50 km a week.</p> <p>Likewise, I started 2014 with a running speed between 8.5 and 9.4 km/h (or a pace between 6:35 and 6:23 minutes per km), but by the time I wrote the article I was regularly exceeding 10 km/h (6:00 min/km) for my shorter runs and 9.5 km/h for my Saturday long runs, which were generally in the 25-28 km range.</p> <p>As the saying goes, pride goeth before a fall. </p> <p>Not only was I increasing my running load too quickly, but also I was neglecting all the ancillary exercises that you need to do in order to run well. I was warming up with my A-B-Cs before a run and doing some stretches after, but that was pretty much it. </p> <p>I was also neglecting to replace my shoes in a timely manner and was running on a pair of Mizuno Wave Riders that had more than a thousand kilometres of wear on them.</p> <h3>Injury Strikes</h3> <p class="initial">I finally pushed it too far on November 11, 2014, when I hit an average speed of 11:03 km/h (5:26 min/km) over 10 km - a personal speed record for me. I felt a funny sensation in my right heel during the run but thought nothing of it. </p> <p>When I woke up on Wednesday, November 12, my heel was killing me. </p> <p>My heel felt a bit better on Thursday but it still hurt, so I put off my scheduled run and picked up the new pair of shoes that I should have bought at least a month earlier. </p> <p class="image"> <img src="/static/images/old_running_shoe_vs_new_running_shoe.jpg" alt="Old shoe and new shoe" title="Old shoe and new shoe"><br> Old shoe and new shoe</p> <p>On Friday, my heel felt better so I heedlessly dove right back to a 10 km run. By the end of it, my heel was screaming again. On Saturday morning, I could barely walk.</p> <p>I had the dreaded <em>plantar fasciitis</em> - an inflammation of the plantar fascia, which is a thick band of connective tissue that stretches across the bottom of your foot from your calcaneous (heel bone) to your metatarsals (the bones between your toes and the ball of your foot).</p> <p>The plantar fascia acts as the bowstring to your foot's arch, tensing and absorbing energy when you step down and releasing that energy when you lift up.</p> <p>Plantar fasciitis is a condition in which you feel sharp pain in your heel due to an injury to the plantar fascia: trauma, inflammation, tearing or degeneration (or some combination).</p> <p>You use your plantar fascia all the time whenever you're standing, walking or running (when you're running, it absorbs up to 7 times your body weight during pushoff), so it's a challenge to treat once it gets injured.</p> <p>It is extremely frustrating to deal with, but like most running injuries it is entirely treatable. It is important to note here that the array of exercises and stretches you do to treat PF are suspiciously similar to the array of exercises and stretches you do to <em>prevent</em> PF. Hint hint.</p> <h3>Starting Recovery</h3> <p class="initial">I had to stop running altogether for around two and a half weeks and focus on walking slowly and smoothly without a limp. (Every day you spend hobbling extends your recovery time and increases the risk of subsequent injuries.) This was a surprisingly infantilizing experience - <em>I have to learn how to walk again!?</em> - but my walking form changed and has been smoother ever since.</p> <p>I also got started on a regimen of stretching and strengthening exercises that targeted the entire running system from my feet up through my calves, knees, thighs, hips and butt. </p> <p>I took a comprehensive approach to the injury, applying Advil, Tylenol, Voltaren, ice packs, frozen water bottle rolls, golf ball rolls, towel scrunches, massages, dynamic foot stretches, static foot stretches, 'windshield wipers', achilles stretches, calf raises, calf stretches, squats, lunges, hip hikes, one-foot balance, quad stretches, hamstring stretches, iliotibial stretches, leg lifts - you name it.</p> <p>While I wasn't running (or wasn't running much), I replaced some of the cardio I was missing with bike rides - which became challenging as the weather turned nasty - and long, brisk walks. I also started to incorporate some more resistance exercise, including pushups, planks and resistance band reps. </p> <p>On December 3, 2014, I did my first run in almost three weeks, and it was a sad affair. I went just 3.5 km, alternating walking and running, at an average speed of 7.58 km/h. It was like I was just starting from scratch again!</p> <p>However, I was determined to get back to speed as quickly as possible. Earlier in the year, I had signed up for the <a href="http://bayrace.com/">Around The Bay Road Race</a>, a challenging 30 km run that was to take place on March 29, 2015. That meant I had less than four months to get better!</p> <p class="image"> <img src="//i.imgur.com/qrnxByN.png" alt="Around The bay Road Race route map" title="Around The bay Road Race route map"><br> Around The bay Road Race route map</p> <p>My recovery seemed to be going well. My heel wasn't bothering me and my speed and distance jumped back up quickly - too quickly. A week later I was running 5 km at a speed of 9.5-10 km/h, but my right foot really started to hurt during my run on December 15. </p> <p>Just as my plantar fasciitis was receding, tendonitis came roaring in to take over. Bam - I was out of action for another two-plus weeks and had to start my recovery all over again.</p> <p>My next run was on December 30, and it was a paltry 3.5 km walk-jog at a stately average speed of 6.96 km/h. Now I had only three months to get ready for Around the Bay! If I was going to have any change to make it to the race, I basically had to split the difference between giving my foot enough recovery time to heal properly and also increasing my distance fast enough to reach 30 km.</p> <p>After two weeks of increasing my distance from 3.5 km to 6 km, I resumed my Saturday long run - with the "long" being entirely relative. But I learned at least one lesson from my first attempt at recovery: I optimized for increasing my distance but kept my speed down below 9 km/h. I also took a walk break every five minutes so as not to overtax my feet.</p> <p>The trails I usually enjoy were iced over so I started running along the route of the Bay Race.</p> <p class="image"> <img src="http://raisethehammer.org/static/images/escarpment_trail_in_winter.jpg" alt="Escarpment Trail in winter" title="Escarpment Trail in winter"><br> Escarpment Trail in winter</p> <p>The hardest part of the Bay Race is the stretch along North Shore Boulevard in Burlington, from the 18 km to 27 km mark. It's picturesque but includes some brutal hills, and hills are particularly hard on injured feet.</p> <p>For my Saturday long runs, I ran out along York and North Shore - running the hardest part of the Bay Race in reverse - as far as I could manage and then turned around and returned going forward along the direction of the route. </p> <p>By January 31, my long run reached 10 km - the average distance of my short run a few months earlier, but a lot slower at 8.8 km/h. Interestingly, the very first time I had cracked 10 km distance was almost exactly a year earlier, on February 8, 2014. at a speed of 8.48 km/h.</p> <p class="image"> <img src="http://raisethehammer.org/static/images/multi_modal_jigsaw_at_high_level_bridge.jpg" alt="York Boulevard High Level Bridge and stairs to Waterfront Trail" title="York Boulevard High Level Bridge and stairs to Waterfront Trail"><br> York Boulevard High Level Bridge and stairs to Waterfront Trail</p> <h3>More Problems</h3> <p class="initial">Meanwhile, my left foot started giving me trouble in mid-January. What it needed was for me to dial back the distance but there was no way I could do that and be ready for Around The Bay, and I had already determined that I was going to do everything in my power to try and make it.</p> <p>I ended up spending the next two months trying to compromise between running more to train for the Bay Race and running less to let my feet heal. Needless to say, I didn't really achieve either goal. My feet continued to grumble and twinge as I pushed them harder than they wanted to go, but I decided I'd rather half-ass the Bay Race than quit altogether.</p> <p>At the start of February I bought a new pair of shoes - I had been both walking and running on my old shoes, so they had accumulated a lot of mileage. I also picked up a night splint, which keeps your foot bent up in a long stretch during the night and really helps with plantar fascia. I highly recommend it.</p> <p class="image"> <img src="//i.imgur.com/yyoykKd.jpg" alt="New shoes: Mizuno Wave Rider 18" title="New shoes: Mizuno Wave Rider 18"><br> New shoes: Mizuno Wave Rider 18</p> <p>By mid- to late-February my weekday runs were up to 9 km and my Saturday runs were up to 15 km. I was experimenting fairly heavily with my form, playing around with more midfoot and more forefoot landings, adjusting my cadence up and down, trying to find a form that was easiest on my feet. I also discovered the 100-Up Drill, which is a fantastic way of practicing consistent good form.</p> <p>For my February 28 long run, I did a very slow 19 km and really got to experience some of the hills on North Shore, in addition to a particularly gruelling hill on Spring Gardens Road. That hill ended up not being in the Bay Race, so practicing on it was an added bonus.</p> <p>In the first week of March, I slightly sprained my left ankle while walking briskly to a meeting in sloppy weather. It was just one thing after another! For my next few runs, I slathered on some Voltaren, kept my feet really stiff and took short strides to minimize the load on my ankles.</p> <p>For my March 7 long run, I did 21 km at a slow 8.46 km/h and made it as far as the big hill near LaSalle Park. My left ankle was slightly swollen but I pre-emptively slathered some Voltaren on it and tried to keep my weight off it for the rest of the day, doing lots of stretches. As my physiatrist likes to say, "Motion is lotion."</p> <p>By mid-March the weather was getting better and I started incorporating more and longer bike rides, which was good timing because my ankle was too sore to run on until March 12, when I did a slow 6 km with my ankle complaining the entire time. </p> <p>I felt stuck in a quagmire of cascading injuries. This was my lowest point - I just didn't see how I would be able to complete the Bay Race a little over two weeks later! </p> <p>Then, amazingly and unaccountably, I woke up on March 14 with my foot feeling fine. I have no idea what changed in those two days, but whatever was going on with my foot receded to the point that I could baby it through a long run.</p> <p>I joined another aspiring Bay Race participant and we ran together, enjoying a great conversation. The pace was very slow - 8.45 km/h - but we covered more than 25 km and I barely noticed my feet. After the run, I spent the rest of the day moving - walking casually, doing lots of stretches - and felt okay on the next day. </p> <p>That was to be my longest post-injury, pre-race run. The following Saturday, March 21, I did a 19 km taper run, once again in the company of my fellow Bay Racer, and our conversation kept me buoyed and distracted from kvetching about my foot.</p> <p>I tapered down the week before the big day with an 8k on Monday and a 6.5k on Thursday, both focused entirely on locking down my form. After much experimenting, I had settled on a light-landing midfoot strike with a short, relatively fast stride, while keeping my back straight and my head up.</p> <h3>Around The Bay Road Race</h3> <p class="initial">Finally, the big day arrived. I really wasn't ready for it but as Donald Rumsfeld reminds us, you go into a running race with the body you have, not the body you wish you had. I found a 3:15 Pace Bunny and fell in behind him, which was really helpful because it's easy to come out of the gate way too hot when you're surrounded by so much enthusiasm.</p> <p class="image"> <img src="//i.imgur.com/iZPRzZm.png" alt="My Around The Bay route map (from Runkeeper)" title="My Around The Bay route map (from Runkeeper)"><br> My Around The Bay route map (from Runkeeper)</p> <p>The run itself was filled with delights. It was incredibly buoying to be surrounded by cheering spectators, calling out encouragement and banging drums and holding up inspirational (and occasionally hilarious) signs. One pair of kids standing under the Skyway Bridge held up a sign that read, "Hurry Up Mom, We're Hungry For Lunch!"</p> <p>My chip time, <a href="https://www.sportstats.ca/display-results.xhtml?raceid=25227&status=results&lastname=mcgreal">according to Sportstats</a>, was 3:17:10. That's pretty much exactly where I hoped to end up, all things considered. Given the number of times over the past four months that I seriously doubted whether I would even make it, I was rather delighted with the outcome.</p> <p class="image"> <img src="/static/images/ryan_at_round_the_bay_23_km.png" alt="Me at around kilometre 23 (image credit: Bruce Taylor)" title="Me at around kilometre 23 (image credit: Bruce Taylor)"><br> Me at around kilometre 23 (image credit: Bruce Taylor)</p> <p>My two goals for this run were a) to finish it and b) to finish it with a time between 3:15 and 3:30. I'm delighted to have met both goals! I started out strong and maintained a steady pace until the last 9-10 km or so, when I started to get intermittent cramps in my right calf. </p> <p>The research suggests that cramps are caused when really fatigued muscles flex and then don't respond to the nerve signal to unclench (and not the common belief that it's due to an electrolyte deficiency, for which there is no evidence). </p> <p>Given my lack of physical readiness for the 30k run, that explanation makes perfect sense for me. My hardest pre-race training run was 25 km two Saturdays previously, and I did that at a very slow 8.45 km/h. </p> <p>Reading about cramping after the run, I learned that the best thing to do when it starts happening is to stop and do some static stretches to force the muscle to relax.</p> <p>My final result was unimpressive by the standard of ATB participants - I was in the bottom 40th percentile - but it represented a real personal accomplishment for me after my long winter of discontented feet. It also meant, as one friend pointed out, that I set the bar nice and low so I can easily beat it when I do the run again next year.</p> <p>I took a couple of days off after the Bay Race, and then enjoyed a short-but-fast 5.8 km recovery run on April 1. I quickly bounced back and by April 18 I was doing a 21 km Saturday long run again. Unfortunately, my physiology was still not finished screwing with my plans.</p> <h3>Yet Another Foot Injury</h3> <p class="initial">On May 7, during a 12 km run up the Radial Trail, I did something to my left mid-foot and it blossomed with big, sharp pain. I had to stop running altogether and walk down the hill. (Thankfully there was a <a href="https://hamilton.socialbicycles.com/">Hamilton Bike Share</a> station at the Chedoke Golf Course parking lot so I could rent a bike and ride the rest of the way home.)</p> <p class="image"> <img src="http://raisethehammer.org/static/images/radial_trail_footbridge_over_highway_403.jpg" alt="Radial Trail footbridge over Highway 403" title="Radial Trail footbridge over Highway 403"><br> Radial Trail footbridge over Highway 403</p> <p>Based on the symptoms, I had either a severe midfoot sprain or a fractured metatarsal. I didn't bother going for an x-ray or bone scan to confirm which was the case, since both are treated more or less the same way.</p> <p>So a little over a month after the Bay Race and almost exactly six months after I first got plantar fasciitis in my right heel, I was back to square one <em>yet again</em>. Arrgh.</p> <p>By this time the weather was lovely and cycling didn't seem to bother my foot, so I really ramped up my weekly biking kilometres and re-started the regimen of rest, ice, compression, elevation, Advil, stretches, massages and so on.</p> <p>I took some very long (for me) bike rides, including a 54 km ride to Caledonia and back and a 65 km ride to the edge of Brantford and back. I started doing a 40-50 km long ride every Saturday morning, in addition to two or three 20 km lunchtime rides during the week.</p> <p class="image"> <img src="//i.imgur.com/PdLH7Gr.jpg" alt="Self-portrait, Hamilton to Brantford Rail Trail" title="Self-portrait, Hamilton to Brantford Rail Trail"><br> Self-portrait, Hamilton to Brantford Rail Trail</p> <p>When I resumed running again on May 23, it was once again a very short distance (2.67 km) and a very slow pace (8.0 km/h). But unlike the previous times I had re-started running, this time I was really determined to ramp up very slowly and gradually. </p> <p>I no longer had a big race to train for and I was getting in lots of cardio from cycling, so I finally felt I had a full licence to take the time to heal properly. </p> <p class="image"> <img src="http://raisethehammer.org/static/images/fearless_deer_on_radial_trail.jpg" alt="Fearless deer on Radial Trail" title="Fearless deer on Radial Trail"><br> Fearless deer on Radial Trail</p> <p>So far, my distance has been increasing almost as slowly as it did when I first started running. The first four runs were all less than 4 km total distance. The next week I was running just over 4 km. The third week I was running around 4.3 km. The fourth week I was running around 4.5 km. </p> <p>By the end of the fifth week I was running 5 km. By the end of the sixth week I was up to 5.5 km, and the seventh week got me up to 5.8 km.</p> <p>In early July, extra-conscious of wear and tear on my shoes, I bought another new pair and relegated the old ones for walking.</p> <p class="image"> <img src="//i.imgur.com/WUrNxAC.jpg" alt="Old soles (left) and new soles" title="Old soles (left) and new soles"><br> Old soles (left) and new soles</p> <p>As of this week, I'm finally back up to 10 km distance with a speed a little better than 10 km/h. That is with five minutes of running and 30 seconds of walking.</p> <p>Another way I snuck extra cardio into my short runs was to precede my lunchtime runs with a brisk walk. At first, I'd walk 4 km and then run 4 km, but gradually the walking portion has gotten shorter as the running portion has gotten longer.</p> <p>Amazingly, my brisk walking pace today is faster than my running pace was when I started running two years ago. For the first few weeks in the summer of 2013, my running speed was in the 7.16-7.74 km/h range. Now my brisk walk is in the 7.8 km/h range.</p> <h3>Lessons Learned</h3> <p class="initial">The first and most important lesson I have learned is that if I want to run, <strong>I have to do more than just run</strong>. Prior to my injury, my exercise program was highly unbalanced: it was basically just running! Surprisingly (to no one but me), it turns out that's not sustainable. As a friend of mine put it: "I don't run to get in shape, I get in shape to run." I think I understand that now.</p> <p>The next lesson is that <strong>recovery from an injury comes slowly and gradually</strong>, so you have to be patient - but it does come. It took me three injury-based interruptions from running to finally accept this and give my body the time it needs to heal.</p> <p>The third lesson I learned is that <strong>running is not the only enjoyable exercise</strong>. I love brisk walks, stints on the Escarpment Stairs and bike rides - especially relatively longer distance bike rides over a couple of hours. </p> <p>I have even come to enjoy pushups (sort of) - at least, I enjoy the feeling of being stronger than I was when I first started doing them and could literally only do a few at a time.</p> <p>Another lesson is that <strong>I really, really love my city</strong>. Over the past few months I have taken bike rides to Ancaster, Dundas, Jerseyville, Brantford, Waterdown, Stoney Creek, Binbrook and points all across the upper and lower city. I have discovered parts of the city I never really knew about, found some fantastic routes and seen some incredible natural and architectural beauty.</p> <p class="image"> <img src="http://raisethehammer.org/static/images/wooden_footbridge_over_sydenham_creek.jpg" alt="Wooden footbridge over Sydenham Creek" title="Wooden footbridge over Sydenham Creek"><br> Wooden footbridge over Sydenham Creek</p> <p class="image"> <img src="http://raisethehammer.org/static/images/trail_signs_near_albion_falls.jpg" alt="Trail signs near Albion Falls" title="Trail signs near Albion Falls"><br> Trail signs near Albion Falls</p> <p>It saddens me to think that there are people who never see and experience their own community other than through the windshield of a car.</p> <p>My biggest fear, after the dread that I would never be able to run again, was that I would lose the progress I had made and start to regain all the weight I had lost. It was that fear, as much as my desire to build my strength and prevent a relapse, which motivated me to take the goal of a broad fitness program more seriously.</p> <p>In many ways, I am in much better shape now than I was last November when I first got injured. </p> <p>My aerobic capacity is better, for one thing. When running, I always breathe in rhythm with my footstrike cadence, and I used to follow the pattern <em>inhale for three steps, exhale for three steps</em> or <em>inhale for three steps, exhale for two steps</em>. When I was feeling tired or on a steep hill, I would drop to <em>inhale for two steps, exhale for two steps</em>. That breathing pattern gave me enough air to run between 9.5 km/h and 11 km/h, depending on the distance.</p> <p>Now, my breathing pattern is <em>inhale for four steps, exhale for four steps</em> or <em>inhale for four steps, exhale for three steps</em>. (I tend to do three repetitions of the first pattern followed by one repetition of the second pattern, so that I don't always start inhaling on the same footstrike.) That gets me an average speed of 10 km/h to 10.8 km/h - including taking into account a short walk break every five minutes.</p> <p>We don't have a scale and I haven't weighed myself in some time, but my clothes continue to get looser and I have had to punch several more holes in my belt to keep my pants up. I estimate that I am 65-70 lbs down from my highest weight.</p> <p>My body isn't quite where I want it to be, but it is quite a lot closer to where I want it than it is to where it was two years ago.</p> <p>Another important lesson this experience of running has really reinforced is that <strong>if you want to change something, you need to measure it</strong>. </p> <p>Last October I was given a pedometer and so I started wearing it and <a href="/stepcounts">recording my daily step totals</a>. Over the past nine months, my daily average number of steps has increased from less than 10,000 to over 20,000. Over the entire period, I have taken a total of over <em>four million</em> steps.</p> <p class="image"> <img src="//i.imgur.com/xVwU3Kv.jpg" alt="Stepcounts since October 2014 with linear trendline" title="Stepcounts since October 2014 with linear trendline"><br> Stepcounts since October 2014 with linear trendline</p> <p>This spring I also started <a href="/biking">recording my longer bike rides</a> (I don't bother to record short rides of just a few kilometres to run errands), and of course I am still <a href="/running">recording my runs</a>. </p> <p class="image"> <img src="//i.imgur.com/JF8TgkL.png" alt="Running distance (blue bars) and pace (red line) since July 27, 2013" title="Running distance (blue bars) and pace (red line) since July 27, 2013"><br> Running distance (blue bars) and pace (red line) since July 27, 2013</p> <p>A few other running metrics for the past year:</p> <ul> <li>Total distance: 1,463 km</li> <li>Total calories burned: 149,437</li> </ul> <p>Ironically, these are pretty similar to my totals for my first year of running:</p> <ul> <li>Total distance: 1,325 km</li> <li>Total calories burned: 155,468</li> </ul> <p>It's interesting that the total distance is slightly longer but the total calories burned is slightly lower. That's because losing weight means I'm not doing as much work to run a given distance at a given speed.</p> <p>There is at least one more lesson worth mentioning. Running has changed my life in innumerable ways. It has given me improved fitness and coordination, better health, improved mood and improved mental discipline, of course, and these are all wonderful outcomes.</p> <p>But perhaps even more importantly, it has also powerfully reminded me that life is a work in progress - that we are not trapped by the status quo and that <strong>change and growth are possible</strong>. </p> <p>That lesson, learned deeply and viscerally in my own body, is finding profound application in all areas of life.</p> Ryan McGreal 2 http://quandyfactory.com/projects/150/tracking_movement 2015-06-14T12:00:00Z Tracking Movement <p>I've been tracking my daily/weekly running and stepcounts. You can see the results here:</p> <ul> <li><p><a href="/running">Running</a></p></li> <li><p><a href="/biking">Biking</a></p></li> <li><p><a href="/stepcounts">Stepcounts</a></p></li> </ul> Ryan McGreal 2 http://quandyfactory.com/projects/151/recipes 2015-04-17T12:00:00Z Recipes <p>I've got a new section on the site for recipes I often use. You can find it here:</p> <ul> <li><a href="/recipes">Recipes</a></li> </ul> Ryan McGreal 2 http://quandyfactory.com/essays/72/hamilton_next:_good_ideas_come_from_urban_focus 2015-03-23T12:00:00Z HAMILTON NEXT: Good ideas come from urban focus <p>Hamilton is a city, not a bedroom community - a real destination for commuters and an important engine of economic development. Seventy per cent of Hamiltonians work in Hamilton, not Toronto or Mississauga. Another 38,000 people commute into the city from a region spanning Niagara, Haldimand-Norfolk and Halton.</p> <p>A recent study by the Centre for Community Study found that 23,400 people work in the downtown core, earning salaries well above the city and provincial averages. Downtown is already the city's single biggest employment cluster and still has plenty of room to grow.</p> <p>While our decision makers pin their hopes on "shovel-ready" suburban greenfields, everything we have learned from the study of economic development points to downtown as the place we need to focus for a more prosperous future.</p> <p>Steven Johnson, author of Where Good Ideas Come From, explains that innovation emerges from a dense network of connections that provides a context for invention. He describes how new ideas are cobbled together using available parts and concludes, "Chance favours the connected mind."</p> <p>The environment Johnson is describing is an urban environment. Put simply, cities are the places where people cross paths and exchange ideas, and where "half-formed hunches" can combine into innovations that produce wealth.</p> <p>When we live and work in urban, mixed-use environments, two important things happen: the per-person cost of public infrastructure goes down, while the rate of innovation speeds up.</p> <p>It's a two-for-one productivity boost, and it's due to the distinctly urban economies of density, scale and association.</p> <p>Density brings destinations together, reducing travel costs and making activities more affordable. Scale gives us bigger markets so the fixed cost of production goes down per unit of output. Density and scale bring people into frequent contact, and that association gives us the networks of "connected minds" that result in an innovation boom.</p> <p>For these reasons, Hamilton must make urban revitalization its number one growth priority. The alternative of continued suburban development doesn't generate enough revenue to pay for the infrastructure that is needed to service it.</p> <p>Each new subdivision actually increases the city's net liabilities. And as the urban boundary expands, more distant suburbs are even more expensive to service.</p> <p>Council just voted to increase development charges by 2013, but the city will still charge only 60 per cent of what it is allowed to collect - even 100 per cent would not actually cover the full cost of development.</p> <p>We have been running this pyramid scheme for decades, paying for yesterday's expansion with tomorrow's. As a result, our existing infrastructure idles while we spend money we don't have to build more infrastructure that can't pay for itself.</p> <p>Our regulatory system reinforces this focus on sprawl at the expense of urban investment. The Zoning By-Law encourages low density, single-use development while actively obstructing adaptive reuse and intensification.</p> <p>Even a modest infill project can face hundreds of thousands of dollars in fees for building permits, setback variances, cash-in-lieu-of-parkland (that can only be used to build new parks in the suburbs), mandatory parking requirements, zoning variances for any use not explicitly listed in the zoning for that building, and development charges - even though the infrastructure the building will use is already built.</p> <p>The new Official Plan fixes some of these issues, but it will be mired in Ontario Municipal Board appeals for years. Meanwhile, the city continues to suffocate slowly under the current rules.</p> <p>We can move faster with an investment-friendly secondary plan (particularly along our east-west B-Line corridor) that establishes a dense urban form primed for mixed use. City staff are already working with businesses downtown on an intensification study that will address the major barriers to reinvestment.</p> <p>We must also commit to building the proposed east-west light rail transit line. The evidence is clear: LRT anchors new private investment and intensifies land use, increasing tax assessments and infrastructure productivity. It attracts residents and signals a city's long-term commitment to the area, which gives developers the confidence to invest.</p> <p>City staff have prepared a detailed inventory of development opportunities along the LRT corridor and the potential is staggering. If Hamilton's LRT performs similarly to other cities, we could see a billion dollars in new investments and tens of millions a year in new tax assessments.</p> <p>The province has said if it approves LRT, it will cover 100 per cent of the direct capital cost. The city will have to contribute some money - the amount is still being negotiated - but the cost of not building LRT is a steady erosion in our finances as the city's unfunded infrastructure liabilities get worse and worse.</p> <p>An urban focus doesn't mean an end to our suburbs. Rather, it means we need an economic engine that generates enough wealth to pay for those suburbs. As Indianapolis Mayor Bill Hudnut famously said, "You can't be a suburb of nothing."</p> <p><em>This essay was published in the Hamilton Spectator on <a href="http://www.thespec.com/opinion/columns/article/565673--hamilton-next-good-ideas-come-from-urban-focus">Wednesday, July 20, 2011</a>.</em></p> Ryan McGreal 2 http://quandyfactory.com/blog/65/designing_a_restful_web_application 2014-12-23T12:00:00Z Designing a RESTful Web Application <h3>Introduction</h3> <p>I'm working on a couple of projects that involve building a web service, and I decided early on that because of our business constraints - having to communicate with a variety of different systems of varying levels of sophistication - it made sense to keep the web service as simple and accessible as possible.</p> <p>That pointed me toward designing a RESTful web service that transmits data in a simple format over straight HTTP. After all, just about any programming language imaginable can make an HTTP request. I also decided to go with JSON for the data format, in part because I've been <a href="/blog/50/couchdb_working_notes">experimenting lately with CouchDB</a> and appreciate both the simplicity and flexibility of JSON and the fact that you can find a JSON parser for any language.</p> <p>This blog entry is my attempt to get all the concepts of RESTful web service design straight. There's a good chance that some of this information is wrong; and if you notice something, please <a href="mailto:ryan@quandyfactory.com">let me know about it</a>. I'll investigate your argument and update the essay as applicable.</p> <p>With that in mind, here we go.</p> <h3>Representational State Transfer</h3> <p>Representational State Transfer, or REST, is a model for designing networked software systems based around clients and servers. In a RESTful system, a client makes a <strong>request</strong> for a <strong>resource</strong> on a server, and the server issues a <strong>response</strong> that includes a representation of the resource.</p> <p>The concept was formalized in 2000 by Roy Fielding, one of the architects of Hypertext Transfer Protocol (HTTP), about more which below, in his doctoral dissertation. It is not surprising, then, that REST and HTTP mesh very smoothly.</p> <p>A RESTful client-server system is <strong>stateless</strong>, meaning each request against the server contains all the information the server needs to process it; and <strong>cacheable</strong>, in that the server can specify whether and for how long resource representations can be cached either locally on the client or on intermediate servers between the client and the server.</p> <h3>Hypertext Transfer Protocol</h3> <p>Hypertext Transfer Protocol (HTTP) is a stateless protocol based on a client requesting a resource across a network and the server providing a response. As such, an HTTP transaction entails a <strong>request</strong> and a <strong>response</strong>. The request goes from the client to the server, and the response goes from the server back to the client.</p> <h4>HTTP Requests</h4> <p>An HTTP request has three parts:</p> <ol> <li><p>The <strong>request</strong> line, which includes the HTTP method (or "verb"), the uniform resource identifier (URI), and the HTTP version. E.g.</p> <p><code>GET /articles/1/ HTTP/1.1</code></p></li> <li><p>One or more optional <a href="http://en.wikipedia.org/wiki/List_of_HTTP_headers">HTTP headers</a>, which are key/value pairs that characterize the data being requested and/or provided.</p></li> <li><p>An optional <strong>message body</strong>, which is data being sent from the client to the server as part of the request.</p></li> </ol> <h4>HTTP Responses</h4> <p>An HTTP response also has three parts:</p> <ol> <li><p>The <a href="http://en.wikipedia.org/wiki/List_of_HTTP_status_codes">HTTP status code</a>, indicating the status of the requested URI, e.g.</p> <p><code>HTTP/1.1 200 OK</code></p></li> <li><p>One or more optional <strong>HTTP headers</strong>, which are key/value pairs that characterize the data being provided.</p></li> <li><p>An optional <strong>message body</strong>, which is the data being returned to the client in response to the request.</p></li> </ol> <h3>Resources</h3> <p>HTTP deals in <strong>resources</strong>. Each URI points to a resource on the server. Think of URIs as nouns, not verbs, with one URI for each resource. </p> <p>For example, if you want to add the ability to create an article, it might be tempting to create a URI called <code>/create_article</code>. This is wrong, because it conflates the object (the resource) and the action (creation). Instead, it makes more sense to have a resource called <code>/articles</code> and a <strong>method</strong> that lets you create articles.</p> <h3>HTTP Methods</h3> <p>HTTP defines several methods, or "verbs", to execute on a resource: <code>HEAD</code>, <code>GET</code>, <code>POST</code>, <code>PUT</code>, <code>DELETE</code>, <code>TRACE</code>, <code>OPTIONS</code>, <code>CONNECT</code>, and <code>PATCH</code>. However, the following four are most commonly used in web services:</p> <h4>GET Method</h4> <p>To retrieve a resource, issue an HTTP <strong>GET</strong> request. GET requests are <em>idempotent</em> (see below), which means making a GET request multiple times does not cause any change in the resource that is requested. </p> <p>GET requests do not include a message body, but GET responses usually do.</p> <h4>POST Method</h4> <p>To submit data to be processed, issue an HTTP <strong>POST</strong> request. POST requests require a message body, i.e. the data to be processed. </p> <p>For example, if there is a resource called <code>/articles</code> and you want to add a new article, issue a POST request to <code>/articles</code> with the content. The server will create a new <em>subsidiary</em> URI under <code>/articles</code> - for example, <code>/articles/9001</code> - and assign that URI to the content you sent with your POST request.</p> <p>Important note: POST requests are <em>not</em> idempotent (see below), meaning multiple POST requests will create multiple resources with unique identifiers.</p> <h4>PUT Method</h4> <p>To place content at an existing resource, issue an HTTP <strong>PUT</strong> request. For example, if there is a URI <code>/articles/9001</code> and you want to replace the content served at that URI, issue a PUT request to that URI with the new content.</p> <p>Important note: PUT requests <em>are</em> idempotent, i.e. issuing 1 or 5 or 50 identical PUT requests will have the same effect on the resource. <strong>PUT</strong> requests must include a message body (the resource to be placed at the URL). </p> <h4>DELETE Method</h4> <p>To remove a resource (and remove its accompanying URI), issue an HTTP <strong>DELETE</strong> request. DELETE requests should be idempotent, i.e. issuing 1 or 5 or 50 identical DELETE requests will delete exactly one resource. DELETE requests do not require a message body.</p> <h4>Idempotence</h4> <p>This funny-looking word is crucial to designing an effective web service. A request is <strong>idempotent</strong> if issuing it more than once does not change the resource state beyond issuing it just once. Read that again if you have to.</p> <p>For example, a DELETE request is idempotent if the first request deletes a resource at a URI, and the second request does nothing because the resource at that URI is already deleted. </p> <p>For another example, a PUT request is idempotent if the first request updates a resource at a URI, and the second request updates the same resource in the same way at the same URI.</p> <p>A request is <em>not</em> idempotent if issuing it more than once <em>does</em> change the resource. For example, a POST request to add a comment to a document is not idempotent, if issuing the POST request twice adds the comment twice (so that the document contains two identical comments with separate URLs). </p> <h4>PUT vs. POST</h4> <p>My original understanding of HTTP methods was that you would use PUT to create a resource and POST to update it. This seems in keeping with common sense, but it breaks down when you apply the all-important filter of idempotence.</p> <p>An interesting discussion on Stack Overflow <a href="http://stackoverflow.com/questions/630453/put-vs-post-in-rest">tackles this issue</a>, but what convinced me to change my mental model was this observation:</p> <blockquote> <p>POST creates a child resource, so POST to <code>/items</code> creates a resources that lives under the <code>/items</code> resource. Eg. <code>/items/1</code>.</p> <p>PUT is for creating or updating something with a known URL. </p> </blockquote> <p>This collision between the inclination to regard PUT as creating and POST as updating is a significant source of confusion about how to well-design a RESTful system, and deserves more attention.</p> <p>Furthermore, it's tempting to assume that the HTTP verbs line up precisely with the SQL CRUD verbs, but while they're superficially similar, they're not identical. Treating them as such leads to this kind of gotcha. </p> <p>It's important to keep the logic of HTTP methods separate from the logic of SQL queries, and to develop specialized appropriate logic between the two domains that ensures the data processing on the server produces responses that satisfy the requirements of the HTTP methods (particularly in respect to idempotence).</p> <h3>Conceiving the Web Service: A Resource/Method Table</h3> <p>At a conceptual level, a RESTful web service API is a matrix of resources and methods that exposes the functionality of the service to third party applications. Below is an example of what that matrix might look like. </p> <p>Again, note well that actions are not mapped to URIs. A resource is an <em>object</em>, a <em>noun</em>, and the action inheres to the HTTP Verb, not to the URI. As a result, the same resource URI can serve different responses (corresponding with different actions) depending on the HTTP Verb.</p> <table> <caption>REST Resource/Action Matrix</caption> <thead> <tr> <th colspan="4">Request</th> <th rowspan="2">Server Action</th> <th rowspan="2">Response</th> <th rowspan="2">Idempotent</th> </tr> <tr> <th>Resource</th> <th>Parameters</th> <th>Method</th> <th>Data</th> </tr> </thead> <tbody> </tr> <tr> <td>/articles</td> <td></td> <td>GET</td> <td></td> <td>makes a list of articles</td> <td>returns a list of articles</td> <td class="green">Yes</td> </tr> <tr> <td>/articles</td> <td></td> <td>POST</td> <td>article details</td> <td>creates a new article</td> <td>returns confirmation and id</td> <td class="red">No</td> </tr> <tr> <td>/articles</td> <td>/id</td> <td>GET</td> <td></td> <td>gets article details</td> <td>returns article details</td> <td class="green">Yes</td> </tr> <tr> <td>/articles</td> <td>/id</td> <td>PUT</td> <td>new article details</td> <td>updates article details</td> <td>returns confirmation and updated article details</td> <td class="green">Yes</td> </tr> <tr> <td>/articles</td> <td>/id</td> <td>DELETE</td> <td></td> <td>deletes an article </td> <td>returns confirmation of deleted article</td> <td class="green">Yes</td> </tr> </tbody> </table> <p>This is the RESTful way to organize a web service: URIs are objects and HTTP Verbs are actions performed on those objects.</p> <h3>HTTP Response Data Formats</h3> <p>Every web server is also a RESTful web service, accepting GET and POST requests to particular resources, and then performing actions and serving data in response.</p> <p>A conventional web server delivers its data in HTML format (<code>text/html</code>), with related Javascript (<code>text/javascript</code>), CSS (<code>text/css</code>) and image files. HTML is an excellent format for marking up textual data for human use, but it has very limited expressive power for structuring data beyond simple documents.</p> <p>The most common formats used to transmit structured data across HTTP are <strong>XML</strong> and <strong>JSON</strong>, with an honourable mention for <strong>YAML</strong>.</p> <h4>XML</h4> <p><a href="http://www.w3.org/XML/">XML</a>, or eXtensible Markup Language, is a markup (i.e. tag) based syntax based on SGML for formatting structured, text-based data. XML is a format in which to create domain specific markup languages that define particular data structures. </p> <p>For example, <a href="http://en.wikipedia.org/wiki/RSS">RSS</a> and <a href="http://en.wikipedia.org/wiki/Atom_%28standard%29">Atom</a> are XML language standards defined to structure documents published to websites so that the documents can be 'syndicated' to feed readers and third party sites for display.</p> <p>Likewise, the default underlying structure of Microsoft Office documents since Office 2007 is an XML language called <a href="http://en.wikipedia.org/wiki/Office_Open_XML">OOXML</a>.</p> <p>XML structures data by defining elements, properties, data types and allowable nesting rules in an XML schema called a <a href="http://en.wikipedia.org/wiki/Document_Type_Definition">Document Type Definition</a>, or DTD. </p> <p>A given XML document specifies which DTD schema should define its structure with a <a href="http://en.wikipedia.org/wiki/Document_Type_Declaration">Document Type Declaration</a>, or DOCTYPE.</p> <p>A given XML document can reference multiple DTDs by using namespaces.</p> <p>Here is a sample XML file containing contact information about a person, taken from <a href="http://en.wikipedia.org/wiki/JSON">Wikipedia</a>.</p> <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt; &lt;Person&gt; &lt;firstName&gt;John&lt;/firstName&gt; &lt;lastName&gt;Smith&lt;/lastName&gt; &lt;age&gt;25&lt;/age&gt; &lt;address&gt; &lt;streetAddress&gt;21 2nd Street&lt;/streetAddress&gt; &lt;city&gt;New York&lt;/city&gt; &lt;state&gt;NY&lt;/state&gt; &lt;postalCode&gt;10021&lt;/postalCode&gt; &lt;/address&gt; &lt;phoneNumber type="home"&gt;212 555-1234&lt;/phoneNumber&gt; &lt;phoneNumber type="fax"&gt;646 555-4567&lt;/phoneNumber&gt; &lt;/Person&gt; </code></pre> <p>XML must be: </p> <ul> <li><p><strong>Well-formed</strong> - elements are properly nested, tags are properly closed and match case, special characters are escaped, and Unicode characters are encoded; and </p></li> <li><p><strong>Valid</strong> - its elements and attributes match the rules defined in the DTD.</p></li> </ul> <p>An XML Language called XSLT can be used to map XML documents into other markup languages, e.g. HTML.</p> <p>XML is in wide use in applications that transfer structured data over the internet.</p> <h4>JSON</h4> <p><a href="http://json.org/">JSON</a>, or "JavaScript Object Notation", is a lightweight data format introduced in 2001 by Douglas Crockford.</p> <p>Pronounced "Jason", JSON is based on JavaScript object literal notation, a syntax for creating objects in JavaScript by literally describing their properties and methods. Here is the JSON equivalent to the XML code in the previous section.</p> <pre><code>{ "firstName": "John", "lastName": "Smith", "age": 25, "address": { "streetAddress": "21 2nd Street", "city": "New York", "state": "NY", "postalCode": "10021" }, "phoneNumber": [ { "type": "home", "number": "212 555-1234" }, { "type": "fax", "number": "646 555-4567" } ] } </code></pre> <p>While the XML above contained 367 characters (not including indentation), the equivalent JSON contains only 272 characters - only three-quarters as large.</p> <p>JSON supports <strong>lists</strong> (ordered sets of values) and <strong>dictionaries</strong> (unordered collections of key/value pairs) with arbitrary nesting and various data types: <strong>number</strong>, <strong>string</strong>, <strong>boolean</strong>, <strong>list<em>, *</em>object</strong> and <strong>null</strong>. </p> <p>Like XML, JSON is also in wide use in applications that transfer structured data over the internet.</p> <p>A major advantage over XML is that the syntax is much simpler and less verbose, which makes it lighter across networks as well as more human-readable.</p> <p>Mature JSON parsers are available for a wide range of programming languages in addition to JavaScript. Python, for example, <a href="http://docs.python.org/library/json.html">includes a json parser</a> as part of its standard library (as of version 2.6; earlier versions can use the third-party <a href="http://pypi.python.org/pypi/simplejson/">simplejson</a> library). </p> <p>A decent JSON parser converts an object back and forth between the programming language's native data types and their JSON equivalents. That way, an application can receive a JSON object, convert it into a native object, process it natively, and then convert the final result back to JSON to be dispatched elsewhere.</p> <h4>YAML</h4> <p><a href="http://www.yaml.org/">YAML</a>, pronounced to rhyme with "camel", is a recursive acronym meaning "YAML Ain't Markup Language". Whereas JSON is a more minimal data format than XML, YAML takes minimalism to an extreme, eschewing quotation marks, brackets and curly braces altogether in favour of significant indentation and line breaks.</p> <p>The YAML equivalent to the XML and JSON contact examples above would be:</p> <pre><code>firstName: John lastName: Smith age: 25 address: streetAddress: 21 2nd Street city: New York state: NY postalCode: 10021 phoneNumber: - type: home number: 212 555-1234 - type: fax number: 646 555-4567 </code></pre> <p>That works out to just 239 characters - including the significant white space.</p> <h3>REST Best Practices</h3> <p>A RESTful web API ought to be <em>discoverable</em> by its users. One crucial way to do that is by making sure that each resource in your API includes URLs to subsidiary URLs.</p> <p>Here is an example, using JSON:</p> <pre><code>{ "articles": [ { "title": "My First Baguette", "description": "After a month of reading about how to make baguettes, I finally took the plunge today.", "date_published": "2011-07-11", "url": "http://quandyfactory.com/blog/81/my_first_baguette" }, { "title": "Tenn. Passes Controversial Lawnmower Theft Bill", "description": "The lawnmowing industry has successfully lobbied the Tennessee State Government to pass a groundbreaking law making it a criminal offence to loan your lawnmower to a neighbour.", "date_published": "2011-06-02", "url": "http://quandyfactory.com/blog/78/tenn_passes_controversial_lawnmower_theft_bill" } ] } </code></pre> <p>When you do this, you make it easy for API users to discover your API structure and functionality without having to keep referring to obscure documentation.</p> <hr /> <p><em>Special thanks to <a href="http://socialtech.ca/ade">Adrian Duyzer</a> for reading a draft of this essay and setting me straight on the respective roles of PUT and POST.</em></p> Ryan McGreal 2