From real to probability vectors in two steps — Consider a vector, for example (5, -0.5, 3, -2). We want to find a transformation such that the transformed vector represents a distribution: each component is between 0 and 1 and the components add up to 1 (so that they can be interpreted as probabilities). …