This question is imported from MSE. It is linked to this one in the case of semi-direct products.

My questionLet us consider a Lie $R$-algebra ($R$ is a commutative ring) written as a (module) direct sum of two of its subalgebras $$ \mathfrak{g}=\mathfrak{g}_1\oplus\mathfrak{g}_2\ (\oplus=\oplus_{R-mod}) $$ and the natural mapping $$ \alpha : \mathcal{U}(\mathfrak{g}_1)\otimes_R\mathcal{U}(\mathfrak{g}_2)\to\mathcal{U}(\mathfrak{g}) $$ ($\mathfrak{g}_i$ are not necessarily ideals).

On can check, using generators, that $\alpha$ is onto (and, in some usual cases - see below - one-to-one).

What is true/known in the general case ?

I put here the explicit construction in case one of the $\mathfrak{g}_i$ is an ideal. The proof goes as follows :

Take it that $\mathfrak{g}_1$ is such.

- Consider the action $\delta : \mathfrak{g}_2\to \mathfrak{Der} (\mathfrak{g}_1)$ by derivations (adjoint representation)
- Extend $\delta$ to $\mathfrak{Der}(\mathcal{U}(\mathfrak{g}_1))$ as in Bourbaki Lie ch 1 paragraph 2.8 prop 7.
- Extend $\delta$ as a morphism of $R$-algebras $\mathcal{U}(\mathfrak{g}_2)\to\mathrm{End}(\mathcal{U}(\mathfrak{g}_1))$ by universal property
- Set a law of $R$-unital associative algebra on $\mathcal{U}(\mathfrak{g}_1)\otimes_R\mathcal{U}(\mathfrak{g}_2)$ by $$ (u_1\otimes u_2).(v_1\otimes v_2)=(u_1\otimes 1)\Big((\delta\otimes\gamma_2)\circ\Delta(u_2)\Big)[v_1\otimes v_2] $$ where $\gamma_2(m)$ is the multiplication by $m$ on the left within $\mathcal{U}(\mathfrak{g}_2)$.

**Late edit**For those who know the smash product, formula of point 4 says that $$ \mathcal{U}(\mathfrak{g})=\mathcal{U}(\mathfrak{g}_1)\,\sharp\, \mathcal{U}(\mathfrak{g}_2) $$ where $\sharp$ stands for the smash product defined by the action of $\mathfrak{g}_2$ by derivations on $\mathcal{U}(\mathfrak{g}_1)$.

8more comments