Confusion regarding the domain of a function Let $f(x)=x^2$ and $g(x)=x$. What is the domain of $\frac{f(x)}{g(x)}$?
Evaluating $\frac{f(x)}{g(x)}$ gives us $x$. Does that mean that its domain is all real numbers?
If we evaluate the function at $x=0$, $\frac{f(0)}{g(0)}$, then $g(0)$ will gives us zero. Does that mean zero is not in the domain of $\frac{f(x)}{g(x)}$?
From what I understand, the domain of $x$ is the set of all real numbers, but the domain of $\frac{f(x)}{g(x)}$ is the set of all real numbers except zero. Am I right?
Edit: $f(x)=2x^2$. Sorry. I forgot to add the two. To make it less confusing, I'm just gonna remove the "2" in $2x$
 A: If your function is $h(x)=\frac{ f(x) }{ g(x) }$, then the domain is all $x$ in the domain of both $g(x)$ and $f(x)$ provided that $g(x)\neq 0$.  The reason is that $h(x)=x$ only for values of $x$ in the domain of $x$ (all reals) and $h(x)$ (all reals except $x=0$).
The way to think about this, why the domain of $h(x)$ isn't all reals is to think about how $h(x)$ is evaluated.  In order to compute $h(x)=\frac{f(x)}{g(x)}$ first you compute $f(x)$ and then compute $g(x)$... so $x$ must be in the domain of both functions.  Then you divide the result of $f(x)$ by the result of $g(x)$--which isn't a problem unless $g(x)=0$.  The simplification that you've done, $h(x)=x$, hides the fact that this division is happening.  Yes, the values are the same everywhere both functions ($h(x)$ and $x$) are defined, but the domains are not the same.  If you were to graph $h(x)$, it would look like $x$ except that there would be a hole at $x=0$.
A: The answer to your question is: It depends. Namely on the domain specified for $f$ and the domain specified for $g$.

Attention: A function is not fully specified as long as the domain of the function is not given.

At first you have to check the domain of the function $f$ and the domain of the function $g$. Although it seems natural that the domain is the largest possible set for which a function gives reasonable values, this has always to be clarified before doing some calculation.

The domain of $f/g$ is the intersection of the domain of $f$ and $g$ minus all points where $g(x)=0$.
Example 1:
  \begin{align*}
&f:\mathbb{R}\rightarrow\mathbb{R}&\qquad &g:\mathbb{R}\rightarrow\mathbb{R}\\
&f(x)=2x^2&\qquad &g(x)=x\\
\\
&\frac{f(x)}{g(x)}=2x&\qquad &x\in\mathbb{R}\setminus\{0\}
\end{align*}
Example 2:
  \begin{align*}
&f:\mathbb{R^+}\rightarrow\mathbb{R}&\qquad &g:\mathbb{R^+}\rightarrow\mathbb{R}\\
&f(x)=2x^2&\qquad &g(x)=x\\
\\
&\frac{f(x)}{g(x)}=2x&\qquad &x\in\mathbb{R}^+
\end{align*}
Example 3:
  \begin{align*}
&f:\{0\}\rightarrow\mathbb{R}&\qquad &g:\mathbb{R}\rightarrow\mathbb{R}\\
&f(x)=2x^2&\qquad &g(x)=x\\
\\
&\frac{f(x)}{g(x)} &\qquad&\text{ is not defined}
\end{align*}

A: Evaluating $\frac{f(x)}{g(x)}$ gives $x$ whenever $x\neq0$. So, the domain of $\frac{f(x)}{g(x)}$ is $\mathbb{R}\setminus\{0\}$ (I am assuming that the domains of $f$ and $g$ are both equal to $\mathbb R$.)
In the case of polynomial functions, it is a common convention to extend the domain of $\frac{f(x)}{g(x)}$ to those points $a\in\mathbb R$ such that the limit $\lim_{x\to a}\frac{f(x)}{g(x)}$ exists, and to define $\frac{f(a)}{g(a)}$ as that limit. But that's a convention and it should be clearly stated.
