Splitting a group into two subsets closed under multiplication Given a group $G$, find subsets $A,B$ such that $G=A\sqcup B$ and $A$ and $B$ are closed under multiplication: $x,y\in A$ (corr. $x,y\in B$) implies $xy\in A$ (corr. $xy\in B$).
For example, if $G$ is finite then all splitting are trivial: if $1\in A$ then $A=G$ and $B=\emptyset$.
If $G=\mathbb{Z}^d$ then any splitting is determined by a halfspace $\Pi^+$ in $\mathbb R^d\supset\mathbb Z^d$: $A=\Pi^+\cap\mathbb Z^d$. (More precisely, by a flag of halfspaces $\Pi^+\supset \Pi_1^+\supset\dots$, because we can distribute the points of the hyperplane $\partial\Pi^+$ between $A$ and $B$.)
What about the free group $G=F_d$? Are there splitting which are not induced by the projection $F_d\to\mathbb Z^d$?
 A: This is a way to rediscover a quite well-studied class of groups:
Proposition Let $G$ be a group. Equivalent statements: (a) $G$ admits a partition $G=A\sqcup B$ with $1\in A$, $B$ nonempty, and both $A,B$ subsemigroups. (b) $G$ admits a nontrivial order-preserving action on some totally ordered set [which can be chosen to be the real line, or $\mathbf{Q}$, if $G$ is countable] (c) $G$ has a nontrivial left-orderable quotient.
The equivalence between (b) and (c) is classical. If $G$ has a non-trivial orderable quotient $p:G\to Q$, there is (by definition) a submonoid $K$ of $Q$ such that $K\cap K^{-1}=\{1_Q\}$ and $K\cup K^{-1}=Q$; pulling back to $G$ yields the desired decomposition.
Conversely, suppose that $G=A\cup B$ as above (with $1\in A$). Define $H=A\cap A^{-1}$: this is a subgroup (call it "core" of the decomposition).
Observe that $HB=BH=B$: indeed if $h\in H$ and $b\in B$, suppose by contradiction $a:=hb\in A$: so $b=ah^{-1}\in AA\subset A$, contradiction, same contradiction if $bh\in A$.
On $G/H$ define a total order by $gH\le g'H$ if $g^{-1}g'\in A$. Note that this doesn't depend on the choices of $g,g'$ modulo $H$ on the right. This relation is $G$-invariant, and is easily seen to be a total order. It is not reduced to a singleton (since $H=A$ would force $B$ empty, since the complement of a subgroup can't be closed under multiplication, unless empty).
Edit: this argument shows something more precise, not only describing the class of groups, but describing these decompositions:
Proposition 2: Let $G$ be a group. (1) If $G$ acts on a totally ordered set $X$ in a order-preserving and $x\in X$, define $A=\{g\in G:gx\le x$ and $B=\{g\in G:gx>x\}$. Then $G=A\sqcup B$ is a decomposition with the given axioms (and $1\in A$). (2) Conversely, any such decomposition of $G$ occurs in this way (for some such action and $x$, where we can assume in addition the action to be transitive).
Note that $B$ is empty iff $G$ fixes $x$.

Note that this shows that if $G$ has such a decomposition, it has one for which the core is a normal subgroup (while in general the core need not be normal).

Also, since non-abelian free groups are themselves left-orderable, they admit such decomposition that are not of the prescribed form (namely have such a decomposition with trivial core).
