I'll leave the quoted text intact below, but so many people get this wrong so often, I want everyone to understand this.
Imagine two engines. Both produce exactly the same peak torque and exactly the same peak horsepower, but one has an absolutely flat torque curve and one has an absolutely flat horspower curve; are you with me so far? To make it easier talk about let's put a few numbers into place. Power is equal to torque (rotational force) multiplied by rate or rotation, and in our case, horsepower is equal to torque in foot-pounds multiplied by RPM divided by 5252.
So if both engines have a redline of 5252, then if engine 1 (with a flat torque curve) has 200 ft-lb torque, it has horsepower curve that is an straight line from 0 at 0 RPM to 200 hp at 5252 RPM. Engine 2 (with a flat horsepower curve) has 200 ft-lb of torque, rising to 400 at 2626 RPM, 800 ft-lb at 1313, and (for the sake of argument) the curve stops at that speed (a little fast for idle, but close enough for government work)
Now, if both engines are connected to a continuously variable transmission that will let them operate at typical road car speeds, what can we discover.
First, engine 1. If -- as some people insist -- all you need to do is maximize average torque (another way of expressing maximize the area under the torque curve), then at what RPM should you operate the engine? Any RPM delivers the same torque, so according to this argument, any RPM should produce the same acceleration. But, of course, for any road speed, the transmission will deliver the greatest torque multiplication at its numerically highest ratio. IOW, operate the engine at peak horsepower.
Now let's look at engine 2 with the flat horsepower curve. Now it really doesn't matter at what RPM you operate the engine. At redline, the transmission will be at ratio x when the road speed is n, but at half redline, you'll get twice as much torque, but it will be multiplied by a ratio of x/2, giving you precisely the same output torque.
Does every get it yet?
Horsepower encompasses both engine torque and how much ratio you can multiply it by due to RPM. If peak horsepower is twice horsepower at peak torque then it means that even if you have one *tenth* the engine torque, you must therefore have 20 times the RPM and thus will deliver twice the output torque because your gear ratio will be 20 times what it is at peak torque.
Maximize average *engine* torque and you will always be operating at less than a maximum *output* torque. Maximize average horsepower (maximize the area under the horsepower curve) and you will get the best combination of available engine torque multiplied by gear ratio.
Always.