Are there any closed form solutions to $$ x \exp(x) = a x + b $$ for real-valued $x$, $a$, and $b$ (we wish to solve for $x$, and $a$ and $b$ are simple constants)? We can assume that everything is positive.
I know that the solution to $$ x \exp(x) = b $$ can be expressed via the Lambert $W$ function, and $$ x \exp(x) = a x $$ is a simple log, but I can't get anything out of there.
$$xe^x=ax+b$$
Your equation is an equation of elementary functions. It's an algebraic equation in dependence of $e^x$ and $x$. Because the terms $e^x,x$ are algebraically independent and the equation is irreducible, we don't know how to rearrange the equation for $x$ by only elementary operations (means elementary functions). A theorem of Lin (1983) proves, if Schanuel's conjecture is true, that irreducible algebraic equations involving both $e^x$ and $x$ don't have solutions in the elementary numbers.
$$\frac{x}{ax+b}e^x=1$$ $$\frac{x}{x+\frac{b}{a}}e^x=a$$ $$\frac{x}{x-(-\frac{b}{a})}e^x=a$$
We see, your equation cannot be solved in terms of Lambert W but in terms of Generalized Lambert W.
$$x=W\left(^{\pm 0}_{-\frac{b}{a}};a\right)$$
The inverse relation of your kind of equations is what Mezö et al. call $r$-Lambert function. They write: "Depending on the parameter $r$, the $r$-Lambert function has one, two or three real branches and so the above equations can have one, two or three solutions"
So we have a closed form for $x$, and the representations of Generalized Lambert W give some hints for calculating $x$.
[Mező 2017] Mező, I.: On the structure of the solution set of a generalized Euler-Lambert equation. J. Math. Anal. Appl. 455 (2017) (1) 538-553
[Mező/Baricz 2017] Mező, I.; Baricz, Á.: On the generalization of the Lambert W function. Transact. Amer. Math. Soc. 369 (2017) (11) 7917–7934 (On the generalization of the Lambert W function with applications in theoretical physics. 2015)
[Castle 2018] Castle, P.: Taylor series for generalized Lambert W functions. 2018