Consider the step function: $$ S(x)=\begin{cases} m_1 & \ \ x<a \\ m_2 & \ \ x\ge a \end{cases} $$
I've recently come across an integral of the form $$\int_x^\infty \frac{S'(t)}{S(t)}f(t)dt$$ for arbitrary function $f$
My first thought was that the derivative $S'$ will act as a delta function spike at $t=a$ making the integral just be $f(a)/S(a)$ for $x<a$ and $0$ otherwise. However, this isn't the case as the value of $S(a)$ is up to my chosen definition. Since this problem arose from physics where a definite answer is needed, I did some more digging.
Upon making continuous approximations for $S(x)$ as smooth sigmoid functions with a parameter that allows them to asymptotically approach the sharp step function above and numerically evaluating the above, I did not get anything like $f(a)/S(a)$, even when $S(a)=\frac{m_1+m_2}{2}$. With some more numerical calculations, I've found that $$ \int_x^\infty \frac{S'(t)}{S(t)}f(t)dt=f(a)\int_x^\infty \frac{S'(t)}{S(t)}dt=f(a)\ln(S(t))|_x^\infty $$ Finally, this gives for $x<a$: $$ \int_x^\infty \frac{S'(t)}{S(t)}f(t)dt=f(a)\ln\frac{m_2}{m_1} $$ and $0$ otherwise. I am getting this regardless of the choice of $f$ or the sigmoid function used (I have used both hyperbolic tangent and the error function). I am just struggling to prove this analytically. Any help is very much appreciated!