You are making a few wrong assumptions:
As of now, the death penalty does not satisfy the first two qualifications. Inmates sit on death row for far too long. However, if the appeal process was expedited and improved it could actually serve as a great deterrent.
The best-publicized program built on this set of principles is the HOPE program in Honolulu, which requires random drug tests of probationers and, for those who fail, an immediate short stint (typically two days) in jail, with no exceptions. The SWIFT program in Texas, the WISP program in Seattle, the Swift and Sure program in Michigan, and Sobriety 24/7 in South Dakota all work the same way, and all have the same results: drastic reduction in illicit-drug use (or, in the case of 24/7, alcohol abuse), reoffending, revocation, and time behind bars.
In Hawaii, HOPE clients are mostly longtime criminally active drug users with a mean of seventeen prior arrests. A drug treatment program would be delighted if it could get 20 percent of such a population into recovery—and most would quickly drop out and go back to drug use. But in a carefully done randomized controlled trial with 500 subjects, eight out of ten assigned to the HOPE program finished the first year of the program in compliance and drug free for at least three months, with no rearrest. Most of them either never had a missed or dirty test (which would have led to a forty-eight-hour jail stay) or had only one such incident. That suggests that more than mere deterrence is at work; HOPE clients seem to be gaining the ability to control their own behavior.
As far as the death sentence being a deterrence for capital murder and other severe capital offenses, the same logic applies to the varying fines being applied to deter shoplifting. More serious punishments deter more serious crimes. Less serious punishments deter less serious crimes. If you looked into the swift, certain, and severe research you would find that severity of punishment has a big hand in deterrence. It should outweigh the benefit of committing the crime without being too severe. We can not sentence someone to death for stealing a candy bar. Similarly, we can not sentence someone to fifty lashing, castration, and death for murdering a child because it would cross over the cruel and unusual boundary.
Because we fear death. We avoid death in so many ways each and every day. Being ordered to die is scarier than being ordered to live in sequester. Again, this is subjective and opinions vary. However, so many prisoners appeal and plea bargain so that they get life in prison instead of death. They sit on death row for years because they want to push their death sentence off.
This is a fundamental concept of Cesare Beccaria, the Father of criminology.
Capital punishment is the highest level of punishment for the highest level of crimes. In terms of severity, it is considered the most severe. There is nothing cruel and unusual about a fairly painless state-sanctioned death. This is how we gauge crimes. Stealing a candy bar = a fine. Stealing a car = a brief prison sentence. Smothering your ailing wife with a pillow = life in prison. Shooting 4 school children = death. There are long trials, appeals, and processes that give the person a fair shot to defend him/herself.