Subset of all real valued functions of a real variable is subring but not an ideal

abstract-algebraideals

$STATEMENT:$

Let $R$ be the ring of all real-valued functions of a real variable.
The subset $S$ of all differentiable functions is a subring of R but not an ideal of R.

$Question:$

I think subset $S$ is clearly subring of $R$. ($f$,$g$ $\in$ $S$ $\Rightarrow$ $f$$g$ $\in$ $S$, $fg$ $\in$ $S$)

But I cannot imagine $S$ is not an ideal of $R$.
Can you give some example?

Thanks for all answer.

Best Answer

It's not an ideal because it's not true that $rs \in S$ for every $r \in R$ and $s \in S$. In other words, if $s$ is a differentiable function, and $r$ is any general real-valued function, then $rs$ is not always differentiable. In general, it may not even be continuous!

For example, observe that $s = e^{x}$ is differentiable. Hence $s \in S$. However, let $$ r = \begin{cases} 1 & \text{if } x \in \mathbb{Q}\\ -1 & \text{if } x \not\in \mathbb{Q}. \end{cases} $$ Clearly $r \in R$ because it is a real-valued function. But note that $$ rs = \begin{cases} e^x & \text{if } x \in \mathbb{Q}\\ -e^x & \text{if } x \not\in \mathbb{Q}. \end{cases} $$ is not differentiable. In fact it's not even continuous. So $rs \not\in S$. Hence it is not true that $rs \in S$ for every $r \in R$, $s \in S$, so we see that $S$ is not an ideal of $R$.

However, it's clearly a subring since it's nonempty and the product and difference of differentiable functions is differentiable.

Related Question