# Find a continuous differential function

Find a continuous differential function $f$ on $\mathbb{R}$ sastisfies the following conditions

1. $f(\mathbb{Q}) \subset \mathbb{Q}$

2. $f(\mathbb{R} \backslash \mathbb{Q}) \subset \mathbb{R} \backslash \mathbb{Q}$;

3. $f'$ isn't constant.

-

This seems like a homework question, and I assume that you meant to say "differentiable" function instead of "differential" function. $f(x)=\frac{1}{x}$ is close to what you need. A suitable modification of this function should provide you with the necessary example. Think "cut and paste." If this is not a homework question, please say so and I would be happy to provide more details.
I got it! $f(x)=\frac{x}{|x|+1}$