The definitions of an ideal of an algebraic structure $A$ (as a substructure $I$ such that the product of $A$ and $I$ is a subset of $I$) do not involve associativity.


However, the definitions of a principal ideal I know (for a semigroup or a ring) assume associativity.  

For example, the left principal ideal $S^1a$ of a semigroup $S$ is an ideal because $S^1(S^1a) = (S^1S^1)a$.  

The two-sided principal ideal of a semigroup is the set $S^1aS^1$ which is defined due to associativity.
<https://en.wikipedia.org/wiki/Green%27s_relations>


I am trying to generalize the definition of a principal ideal to non-associative structures.


Would it be a correct generalization to say that a principal ideal is an ideal that can be obtained by taking a single element and all finite products with the element as one of the oprands?


The left (right) principal ideal of a non-associative magma $M$ generated by an element $a$ is the set that includes $a$ and all finite products of elements of $M$ where $a$ is the rightmost (resp. leftmost) operand.


The two-sided principal ideal of $M$ generated by $a$ is the set that includes $a$ and all finite products of elements of $M$ that contain $a$ as an operand.


I am wondering if there is a notation for the sets of finite products for a non-associative structure.  

Instead of $S^1a$ or $S^1aS^1$ it must include all possible combinations of $...S^1S^1a$ or $...S^1S^1aS^1S^1...$.


Are there better approaches or formulations of a principal ideal of a non-associative magma?  

Are there generalizations of a principal ideal for non-associative rings, algebras, etc.?



Principal ideal of a non-associative magma
In a magma $M$, one can describe the 2-sided ideal generated by a subset $Y$ as follows: define by induction
$$M\_1=M,\;Y\_1=Y,\; M\_n=\bigcup\_{p,q\ge 1,p+q=n}M\_pM\_q,\;Y\_n=\bigcup\_{p,q\ge 1,p+q=n}(M\_pY\_q\cup Y\_pM\_q).$$
Then the 2-sided ideal generated by $Y$ is $Y\_\infty=\bigcup\_{n\ge 1} Y\_n$.


An alternative definition, is to define $Y'\_1=1$, $Y'\_{n+1}=Y'\_nM\cup MY'\_n\cup Y'\_nY'\_n$; then $\bigcup\_{n\ge 1} Y'\_n=Y\_\infty$. 


If $R$ is a scalar ring (=commutative associative unital) and $A$ is an $R$-algebra (not assumed associative), if $Y$ is a subset of $A$, one can define $Y\_\infty$ as previously (using only multiplication). Then the $R$-submodule generated by $Y\_\infty$ equals the 2-sided ideal generated by $Y$. In case $A$ is unital, this is also the additive subgroup generated by $Y\_\infty$. 


