Description Usage Arguments Value
Compute log(exp(x1) + exp(x2) + ... + exp(xn)) in a numerically stable manner by relying on the identity log(exp(x1) + exp(x2) + ... + exp(xn)) = c + log(exp(x1 - c) + exp(x2 - c) + ... + exp(xn - c)) for any real c. We here work with c = (min(x) + max(x)) / 2, which minimizes max_i |x_i - c|
1 | log_sum_exp(x)
|
x |
a vector of numbers |
log(exp(x[1]) + exp(x[2]) + ... + exp(x[n]))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.