Is my proof that the square root of all imperfect squares are irrational correct? I was answering a Quora question about whether $\sqrt{13}$ is irrational or not (link if needed), and I tried to prove that, in fact, the square root of all imperfect squares are irrational.
This is the first proof I have ever attempted, not knowing anything about them before-hand, and I barely know the mathematical symbols, never-mind how to properly set out a proof. So, keeping in mind that I am a complete newbie, can you tell me whether my proof is in fact correct or not, and if it isn't, where I went wrong and how I could improve it next time.
Also, if I chose the wrong symbol, please point out the where the mistake was and what the correct symbol would have been.
Start of Proof
Let's suppose that $n \in \mathbb{N} = \mathbb{Z}^{+}$ is not a perfect square.
This is going to be a proof by contradiction, so we are going to start out by assuming that $\sqrt{n}$ is indeed a rational number, that can be expressed in the irreducible fraction $\frac{A}{B}$ where $A, B \in \mathbb{Z}^{+}$ and $B \neq 1 \because \iff B = 1, \sqrt{n} = A$ which means $n = A^{2}$ which means $n$ is a perfect square.
$\sqrt{n} = \frac{A}{B}$
We can then square both sides to get:
$n = \frac{A^{2}}{B^{2}}$
Since $\frac{A}{B}$ is an irreducible fraction, $A$ and $B$ must not share any factors. When we square a number, we merely repeat its factors, therefore $A^{2}$ and $B^{2}$ must also not share any factors except $1$, making the fraction $\frac{A^{2}}{B^{2}}$ also irreducible.
Bacause it is irreducible, this means $\frac{A^{2}}{B^{2}} \notin \mathbb{Z}^{+} \because B^{2} > B \forall B > 1$ and $ B \in \mathbb{Z}^{+}$ and $B \neq 1$.
Since $n =  \frac{A^{2}}{B^{2}}$, this means that $n \notin \mathbb{Z}^{+}$ also.
$\because n \notin \mathbb{Z}^{+}, \sqrt{n} \notin \mathbb{Z}^{+}, \sqrt{n} \neq \frac{A}{B}$
As we had previously defined $n$ to be a positive integer, this is a contradiction. Therefore, our assumption that $\sqrt{n}$ could be expressed as the ratio of two integers was incorrect. Hence $\sqrt{n}$ is irrational $\forall n \in \mathbb{N} = \mathbb{Z}^{+}$ where $n$ is not a perfect square.
$\mathbb{Q.E.D.}$
End of Proof
Thanks for taking the time to read my proof. I would appreciate any and all feedback. As said, I am completely new at this so please show me where I went wrong and how to improve if I did in fact go wrong.
~Edits~:


*

*Changed the penultimate statement $\because n \notin \mathbb{Z}^{+}, \sqrt{n} \notin \mathbb{Z}^{+}, n \neq \frac{A}{B}$ by adding a radical to the last $n$ that was previously missing: $\because n \notin \mathbb{Z}^{+}, \sqrt{n} \notin \mathbb{Z}^{+}, \sqrt{n} \neq \frac{A}{B}$

*Added a concise contradiction as opposed to ending the proof by simply stating that $\because n \notin \mathbb{Z}^{+}, \sqrt{n} \notin \mathbb{Z}^{+}, \sqrt{n} \neq \frac{A}{B}$ without looping back to the opening when we defined $n$ as an integer.

*Further reinstated why $\frac{A}{B} \notin \mathbb{Z}^{+}$ by adding reasoning that $\because B^{2} > B \forall B > 1$ and $ B \in \mathbb{Z}^{+}$ and $B \neq 1$, along with the fact that $\frac{A^{2}}{B^{2}}$ is irreducible.
Credit to Mathew Daly for helping me improve the summary.
 A: I will mention one (easily corrected) logical error and one stylistic piece of advice that could make the proof more readable.  But the upshot is that this is a well-argued proof by any standard, and especially impressive for a first effort.
When you said that $A^2$ and $B^2$ share no factors aside from 1, that does not imply that $\frac{A^2}{B^2}$ is not an integer.  You merely showed that it is a simplified rational number.  That is an important step, but ultimately, you need to add that $B^2\neq 1$.  As I said earlier, this is nearly trivial to address, since $B^2>B$ for all $B>1$.  But it is worth addressing key points in proofs even if they are trivial.
Stylistically, I felt a bit let down when you hit the contradiction.  It's kind of a climax of the proof, so you should feel free to emphasize it.  More importantly, you want to specifically point out the contradiction and the original assumption that you now know to be false (as this is a proof that's long enough that we've likely forgotten the beginning by now).  If I had written this, I might have ended it like this:

As we had previously defined $n$ to be a positive integer, this is a contradiction.  Therefore, our assumption that $\sqrt n$ could be expressed as the ratio of two integers was incorrect.  Hence $\sqrt n$  is irrational.

A: You may have the right idea, but for the proof to be complete and rigorous you need to more clearly justify the following crucial inference:

When we square a number, we merely repeat its factors, therefore $A^2$ and $B^2$ must also not share any factors". 

As it stands, your justification "when we square a number, we merely repeat its factors" could be interpreted in a way that it is true in any number system (ring). But the result is not true that generally. Likely you have in mind an argument that uses more specific divisibility properties that hold true for integers,  e.g. the fundamental theorem of arithmetic (existence and uniqueness of prime factorizations) or closely related properties such as Euclid's Lemma, gcd laws, etc. It is essential to explicitly mention such properties in order to obtain a well-founded argument.
But so little is said (e.g. not even any mention of primes) that there is no way for the reader to accurately judge the intent and correctness of the argument. It is quite common for beginners to wrongly believe that such properties are trivially true for all number systems, or to believe that a proof is (intuitively) "obvious" but then not know how to rigorously prove it when the gap is revealed.
Let's consider a simple counterexample - the Hilbert naturals $\,\Bbb H = 1+4\,\Bbb N = 1,5,9,13,\ldots$ Here $\,3\not\in\Bbb H\,\Rightarrow\,\gcd(9,21)=1\,$ but $\,\gcd(9^2,21^2) = 9\gcd(9,49)=9\,$ by $\,9,49\in\Bbb H.\,$
 So your quoted claim fails here. You may find it instructive to study why it fails. Also unique prime factorization fails, e.g. two distinct $\Bbb H\text{--prime}$ factorizatioms$\ 9\cdot 49 = 21^2$ [arising from $\,3^2 7^2 = (3\cdot 7)^2$ in $\Bbb N$].
The level of detail that should be required in arguments like this is subjective and context dependent. In a first course in proofs an instructor may be most concerned with teaching general proof strategies so may gloss over tangents on number-theoretical intricacies. But in a course in number theory or algebra these intricacies are the heart of the matter. If one doesn't master them then one will soon be led astray in more general number systems (e.g. quadratic algebraic  numbers) where some of the familiar properties of integers (like those above) no longer hold true. There empirical  inference based upon integer arithmetical intuition may fail miserably. Instead we must rely on deductive inference based on fundamental divisibility properties and their logical relationships. One of the main goals of a course in elementary number theory is to abstract out these essential arithmetical properties so they can be applied correctly in more general number systems (e.g. the basic results thats for integral domains we have Euclidean $\Rightarrow$ PID $\Rightarrow$ UFD $\Rightarrow$ GCD $\Rightarrow$ Schreier, and no arrow reverses).
At first glance this may seem overkill for integers. But the need for such rigor and abstraction becomes clear when we leave the familiar domain of integers and enter arithmetical domains where intuition fails miserably. Indeed, lacking such rigorous foundations even eminent mathematicians made major mistakes in the past (e.g. some attempted proofs of FLT wrongly assumed without proof that some rings of algebraic integers had divisibility properties similar to integers). 
These matters have been discussed here in the past, with varying degrees of success. You may find it of interest to read some prior discussions on such matters, e.g. here (beware that one mathematician deemed the thread to be terrifying!) But it does cover the essential points, and illustrates the innate difficulties involved in such subjective pedagogical discussions with a very diverse audience.
