To me the neat bit isn't that it got the exponential decay right - that's pretty standard, its that it realised there were two different timescales for the decay and got ball-park numbers for them pretty well. This is…
While this is a great article, I feels it buries the lede. For me, the key insight was from the last paragraph of the article: C++23 introduces "deducing this", which is a way to avoid the performance cost of dynamic…
My mind was exploded by this somewhat similar technique https://en.wikipedia.org/wiki/Tanh-sinh_quadrature - it uses a similar transformation of domain, but uses some properties of optimal quadrature for infinite…
You can view this result as the convolution of the signal with an exponentially decaying sine and cosine. That is, `y(t') = integral e^kt x(t' - t) dt`, with k complex and negative real part. If you discretize that…
IMO the reason the compiler doesn't add special cases for the simplest version is that it doesn't know which of its _many_ special cases to use. If you actually use the unoptimised version of the code like void…
To me the neat bit isn't that it got the exponential decay right - that's pretty standard, its that it realised there were two different timescales for the decay and got ball-park numbers for them pretty well. This is…
While this is a great article, I feels it buries the lede. For me, the key insight was from the last paragraph of the article: C++23 introduces "deducing this", which is a way to avoid the performance cost of dynamic…
My mind was exploded by this somewhat similar technique https://en.wikipedia.org/wiki/Tanh-sinh_quadrature - it uses a similar transformation of domain, but uses some properties of optimal quadrature for infinite…
You can view this result as the convolution of the signal with an exponentially decaying sine and cosine. That is, `y(t') = integral e^kt x(t' - t) dt`, with k complex and negative real part. If you discretize that…
IMO the reason the compiler doesn't add special cases for the simplest version is that it doesn't know which of its _many_ special cases to use. If you actually use the unoptimised version of the code like void…