I have an integral of this form:
$$v = \int_{x=-\infty}^\infty g(x) \delta \big(f(x, y_1) - f(x, y_2)\big) dx.$$
I know that if $y_1 \neq y_2$, a closed form solution can be found, namely $$ v = \frac{g(\hat{x})}{\left|\frac{\partial f }{\partial x}(\hat{x}, y_1) - \frac{\partial f }{\partial x}(\hat{x}, y_2) \right|},$$ with $\hat{x}$ the solution of $f(x, y_1) - f(x, y_2)=0$ (supposed unique).
My question may seem weird, but I am wondering what happen when $y_1=y_2$ ? The integral diverges, I know, but can we actually still say something on its solution? For example, is there a way to "normalize" the solution by infinity ? I don't know if it even makes sense and, if it does, I don't know how to formalize this idea. Any help would be appreciated, thank you.
Edit: thank you for the comments/answers, it cleared things up. I had a specific case where the first equation is actually used to define a linear operator, and I realize now that the question cannot be separated from this context. After further investigations, things actually check out without an infinity term appearing.