Here is the definition of a subgroup that I found in a book:
If $H$ is a subgroup of $G$ then $H$ is a subset of $G$ such that it contains the unit element $e$ as well as satisfying the following condition:
$$x,y\in H\quad \text{iff} \quad x*y, x^{-1}\in H$$
Now one property of a group is that: $$\forall x\in G \quad \exists y\in G \quad \text{such that}\quad x*y=y*x=e $$
So what is the inverse of $y$ in the subgroup $H$?
Here is my attempt at understanding this definition:
$$y = y*e = y * (x*x^{-1}) = (x*y)*x^{-1}$$
So I'm not sure about this, but is this somehow a recursive definition?
Because $(x*y) \in H \implies (x*y)^{-1} \in H$ right? Because you can think of $(x*y) \in H$ as $(x*y),e \in H $
So then
$$y * (x*y)^{-1} = x^{-1}$$
So $y^{-1} = (x*y)^{-1} *x$
I guess you can also think of $y\in H$ as $y,e \in H$ as well.
Does this make sense at all?
Given a set $G$ which is a group under operation $\star$, a subgroup is a nonempty subset $H\subset G$ that is also a group under operation $\star$. It suffices to show that
Associativity is inherited from the operation $\star$.
Now, there is a "one-step subgroup test," which states that a nonempty subset $H\subset G$ is a subgroup if and only if $$a,b\in H\implies a\star b^{-1}\in H.\tag 0$$ To see that $(0)$ implies 1, 2, and 3, there must be some element $a\in H$, from which $a\star a^{-1}=e\in H$. Then as $e, a\in H$, it follows that $e\star a^{-1}=a^{-1}\in H$. Therefore given $a,b\in H$, we have $a\star(b^{-1})^{-1}=a\star b\in H$, so that $H$ is a subgroup of $G$.