When you train a dog, there are two ways you can go: positive and negative reinforcement. This applies equally to humans, but it's easier to understand in our canine friends.
Negative reinforcement removes negative stimuli when your dog does what you want. An example of negative reinforcement would be using a training collar (some vibrate and beep, others shock). When your dog does something undesirable (e.g. excessive barking, lunging on leash) you introduce a negative stimuli. When your dog acts as you wish, you start to remove the negative stimuli, hence reinforcing the behavior.
Positive reinforcement is the obvious counterpart. When your dog does something desirable, you reinforce the behavior with something positive, like a treat.
There are environment factors which are causal to your dog's bad behavior. You can visualize these as a stack of causal triggers. The more triggers we put on (loud noises, strong smells, chaotic behavior), the more likely your dog's anxiety is triggered.
If we observe dogs with separation anxiety, we see that their anxiety is heightened with each causal trigger that indicates you are leaving. You put on your coat, grab your keys, put on your shoes and finally leave the house. By the time you've finished this routine, your dog has reached a fever pitch.
If we go back to our stack, we can imagine that positive reinforcement slowly removes blocks from this stack until the anxiety is no longer triggered. This is done by repeating the action in question (e.g. grabbing your keys) and giving the dog a positive trigger instead of the negative one. You grab your keys, walking outside and then immediately walking in. You then repeat this until taking your keys no longer induces anxiety in the dog and you've removed the causal trigger. Then you do this for each trigger block until the dog is as cool as a cucumber.
Negative reinforcement, instead of removing blocks, adds them. When you leave the apartment and the dog barks, you shock the dog. You've added another causal trigger to the stack. Now the dog gets penalized for their anxiety and hopefully remains quiet. But something doesn't feel right about piling new triggers onto an already fraught tower in order to obfuscate the "bad" ones.
Allow me to make a slightly detour, as this brings me to a subject of recent interest: Adlerian psychology. Alfred Adler was a contemporary of Freud, but he broke from Freud's thinking because he believed, unlike Freud, that external causes are not 100% responsible for our behavior. He believed that individuals have the final say, that there are important internal causal factors as well—that we have a choice. In a word, he believed that all problems are social and stem from a lack of courage. But external factors do have an effect, like our reinforcement above. To encourage, (v) give support, confidence, or hope to (someone), is like the positive reinforcement of removing causal bricks. To discourage, (v) cause (someone) to lose confidence or enthusiasm, is like the negative reinforcement of adding new bricks.
If this all seems like an oversimplification of reality to you, I'm with you. But I do believe that encouragement is a more powerful driver than discouragement. Taken to its logical extreme, is it possible to train your dog only with encouraging? Some people would have you believe so. What about raising a child? Or managing employees, or being a good friend?