functions differing by a constant

• May 2nd 2010, 04:02 PM
serious331
functions differing by a constant
Let D be a set of nonzero real numbers. Suppose that the functions $\displaystyle g : D \rightarrow R$ and $\displaystyle h : D \rightarrow R$ are differentiable and that $\displaystyle g'(x) = h'(x)$ for all x in D. Do the functions differ by a constant???

so we can say that:

If D is an open interval then, we can define $\displaystyle f = g-h : D\rightarrow R$. then we have

$\displaystyle f'(x) = g'(x) -h'(x) = 0$ for all x in D

So, $\displaystyle f : D \rightarrow R$ is constant iff g and h differ by a constant.

however, what i wanted to know is how can we assure that D is an (open) interval?
• May 2nd 2010, 04:29 PM
The answer is no, as you have apprehended. Take $\displaystyle D:=(-2,-1)\cup(1,2)$ and set g to be the indicator on (-2,-1) and h to be zero. Then they're derivatives are equal but they do not differ by a constant. You will need to insist that D be connected if you want this to hold.
• May 2nd 2010, 05:29 PM
serious331
Quote:

The answer is no, as you have apprehended. Take $\displaystyle D:=(-2,-1)\cup(1,2)$ and set g to be the indicator on (-2,-1) and h to be zero. Then they're derivatives are equal but they do not differ by a constant. You will need to insist that D be connected if you want this to hold.

Maybe I misunderstood you. Let $\displaystyle D:=(-2,-1)\cup(1,2)$. Define
$\displaystyle g(x) = \begin{cases} 1, & \mbox{if } x \in (-2,-1) \\ 0, & \mbox{otherwise}. \end{cases}$