Does $\frac{x}{x}=1$ when $x=\infty$? This may be a dumb question:

Does $\frac{x}{x}=1$ when $x=\infty$?


I understand why $\frac{x}{x}$ is undefined when $x=0$:  This can cause errors if an equation is divided by $x$ without restrictions.
Also, $\frac{\infty}{\infty}$ is undefined.  So when I use $\frac{x}{x}=1$ to simplify an equation, can it also lead to errors because $x$ can equal infinity?
Or is $x=\infty$ meaningless?

In calculus, it is convenient to use the extended real numbers: these are the real numbers along with two extra numbers we call $+\infty$ and $-\infty$.
We can define arithmetic with extended real numbers. While I could just say that we've defined the arithmetic so that $(+\infty) / (+\infty)$ is undefined (e.g. just as $0/0$ and $1/0$ are undefined), it may help if I point out the motivation behind the arithmetic of the extended real numbers.
The extended real numbers are introduced for the purposes of making calculus and analysis more convenient, and to do so it is important that arithmetic be continuous: While most arithmetic operations with $+\infty$ and $-\infty$ can be defined -- e.g. $(+\infty) + 7 = +\infty$ and $(-\infty) \cdot (-47) = +\infty$ -- the following limits show that $(+\infty)/(+\infty)$ can't be defined by continuous extension:
$$ \lim_{x \to +\infty} x = +\infty
\qquad \qquad \lim_{x \to +\infty} x^2 = +\infty $$
$$\lim_{x \to +\infty} \frac{x}{x} = 1
\qquad \qquad \lim_{x \to +\infty} \frac{x}{x^2} = 0 $$
If we could extend division continuously, then both of the limits on the second line should be the value of $(+\infty)/(+\infty)$. But they are different numbers. So we can't do it! Thus we opt to leave $(+\infty)/(+\infty)$ undefined.

Arithmetic with other systems of numbers you may know (integers, rationals, reals, complexes) were constructed so that they would obey the "familiar" laws of arithmetic. You're probably used to automatically assuming old laws of arithmetic continue to hold when you learn about new sorts of numbers.
The extended real numbers, however, were constructed for a different reason as I described above, and because of this, many familiar laws of arithmetic have been allowed to fail, so you should be wary about doing arithmetic with them until you've really gotten used to how they work. (it is impossible to fully satisfy both desires at once)
