Isomorphism between groups Suppose I have $2$ finite groups $G,H$ that have the same presentation. This means:
$$G = \langle a_1,a_2, ..., a_n \mid \text{several conditions on these elements} \rangle$$
$$H = \langle b_1,b_2, ..., b_n\mid \text{the same conditions on these elements} \rangle$$
I want to prove that $G \cong H$, and a mapping that comes to mind is the function that maps generators to equivalent generators. 
For me, it makes sense that we define such a mapping by demanding it is a homomorphism, but I'm not sure I can 'demand' this. I think it is possible because every element of G will be in the domain because of the homomorphism structure and the fact that we can write any element of G as product of generators. After this is done, it seems quite logical that the mapping is surjective, and therefore bijective. Thus the mapping will be an isomorphism.
So, can we always define the mapping I mentioned without trouble?
 A: Ok, so let's dive into formality. First of all, I will assume that you know the definition of the free group over a set $\mathbb{F}(X)$. The notion $<X|Y>$ is nothing else then $\mathbb{F}(X)/N(Y)$ where $N(Y)$ is the smallest normal subgroup of $\mathbb{F}(X)$ that contains $Y$.
So let's write these two presentation more explicitely. Put $A=\{a_1,\ldots, a_n\}$ and $B=\{b_1,\ldots, b_n\}$ and then
$$G=<A|R_A>$$
$$H=<B|R_B>$$
Let's stop for a while and let's talk about free groups. Free groups have this amazing property
Lemma. let $X$ be a set and $G$ a group. If
$$f:X\to G$$
is a function (any function) then there exists a unique homomorphism
$$F:\mathbb{F}(X)\to G$$
such that $F(x)=f(x)$ for $x\in X$. The homomorphism is given by
$$F(x_1\cdots x_n)=f(x_1)\cdots f(x_n)$$
$\Box$
Now the problem arises: what does

the same conditions on these elements

mean? One useful definition would be: there exists an isomorphism $f:\mathbb{F}(A)\to\mathbb{F}(B)$ such that $f(R_A)=R_B$. In your case this is probably stronger, by the same conditions on these elements you probably mean that this $f$ isomorphism I've mentioned is given by $f(a_i)=b_i$. Note that by lemma we can define homomorphism on free groups only by values on generators. It can be easily proved that in this case this is an isomorphism.
So now we are ready to prove the statement. Define
$$g:A\to\mathbb{F}(B)/N(R_B)$$
$$g(a_i)=f(a_i)N(R_B)$$
(it's a coset on the right side). By lemma this function has a unique extension to a homomorphism
$$G:\mathbb{F}(A)\to\mathbb{F}(B)/N(R_B)$$
$$G(a_i)=f(a_i)N(R_B)$$
Note that since $f$ was onto then so is $G$ and therefore by the first isomorphism theorem
$$\mathbb{F}(A)/\ker G\simeq \mathbb{F}(B)/N(R_B)$$
So all that is left is to prove that $\ker G=N(R_A)$. The inclusion $\supseteq$ is obvious because $f(R_A)=R_B$ and thus $f(r)=rN(R_B)=N(R_B)$ (which is the identity in $\mathbb{F}(B)/N(R_B)$) for $r\in R_A$.
We will prove $\subseteq$. Assume that $x\in\ker G$. Then
$$N(R_B)=F(x)=f(x)N(R_B)$$
so $f(x)\in N(R_B)$. Since $N(R_B)$ is a conjugate closure of $R_B$ and $f$ is an isomorphism then it follows that $x\in N(R_A)$ which completes the proof. $\Box$.
