I'm a little confused unless you are trying to figure out the ideal gear for a single or fixed gear bike setup?
The variations in gears are meant so you basically shift up or down so you can maintain a constant and loose cadence consistently as the terrain changes.
Your speed will vary as a result, but your effort remains fairly constant is the idea. It's to give you endurance over the ride.
I shift freely and fairly frequently even on relatively flat terrain, keeps the legs loose and adds to endurance over the ride time. If your cadence is slowing and effort going up, just drop a gear or so to lighten the load...all there is to it.