Good beginner workouts on stationary bike After many years of programming, I have found that I can no longer avoid the fact that I spend most of my day sitting, which is absolutely horrible for my health. I started swimming a few months ago and am enjoying getting back into better shape, so I'd like to start adding in some workouts on a stationary bike. I have one long bike tour under my belt, but that was many years ago at this point, so though I'm not new to cycling I haven't ever really focused on cycling for physical fitness.

I have ready access to a boring bike at the gym. It just has flat pedals, but it does have a computer and controllable difficulty levels, along with a built-in pulse monitor. My question is, what sorts of workouts would be good to try for starters ? Should I just get on and pedal for half an hour ? What cadence should I aim for (in my mind I'm shooting for somewhere near 100) ?

I have two goals in adding a stationary bike workout: I'd like to increase my cardiovascular fitness (currently I can barely swim 100m in one go, because my lungs feel like they're going to explode), and I'd like to make my quads stronger. Hopefully these aren't at odds with each other.
How long do you have?  How strong is your motivation?  How good are the bikes?

Unfortunately, most exercise bikes have a very poor "simulated feel", and a real cyclist tires of them pretty quickly.  This is especially true of the old friction bikes and many of the wind and magnetic trainers.  A few (Expresso bikes, and some of the newer Le Monde bikes that I've tried) do have a halfway passable "feel", though, since they have a modicum of momentum (which is the main thing missing in the others).

You can use the bike for several things -- short bursts, to raise your HR and short-term aerobic capacity, long sessions (at LEAST 30 minutes, preferably longer) to tax your glucagon storage just a hair and build endurance, and brief "climbs" to strengthen your muscles.

But, given access to a reasonably well-equipped gym, you probably should throw in some strength training as well, with leg presses, extensions, and curls.  And, believe it or not, simply being conscious to doing more squats through the day (eg, when reaching down to open a file drawer) can produce significant improvement.

And you really need longer sessions -- at least two hours at a crack -- to build your long-term endurance.  These are probably best done on a real bike, though, if at all possible.

I'm not convinced cadence is that important, but as a rough guide I'd say about 110 minus 65% of your age should be the upper limit, and 75% of that number would be the lower limit.  (Unfortunately, many exercise bikes only work smoothly at high cadence.)  My general rule for cadence lower limit is to never pedal slower than you're breathing, and that covers virtually all situations other than a brief climb.

Heart rate is also a guide, but there is much individual variation in rate, so it's hard to give numbers.