I am having trouble finding an example of a function f:[0,1] onto Reals st f is not integrable on [0,1], but absolute value of f is integrable on [0,1]. Any suggestions?
$\displaystyle f(x) = \left\{ \begin{array}{cl} 1 & x \in \mathbb{Q} \\ -1 & x \in \text{Irrationals} \end{array}\right. \forall x \in [0,1] $
$\displaystyle \left|f(x)\right| = 1 \quad \forall x \in [0,1]$
I was thinking of that too, Jhevon although you beat me to posting it Haha.
I don't quite understand the implications of your edit though.
Cant we just tweak this a little bit and say:
$\displaystyle f(x) = \left \{ \begin{array}{lrr} 1 & \mbox{ if } x \in \mathbb{Q} & \\ & & \mbox{ for } x \in [0,1] \\ -1 & \mbox{ if } x \not \in \mathbb{Q} & \end{array} \right.$
(Tweak)
$\displaystyle \forall x \in \mathbb{R} - [0,1], f(x) = x\sin x$
Isnt this onto?
EDIT: Its wrong... misunderstood the question
You want a function from $\displaystyle [0,1]$ onto $\displaystyle \mathbb{R}.$
Note there is no qualification on integrable. Presumably the OP is interested in something like Riemann integrability rather than Lesbegue integrability. Which is just as well as all the functions presented are Lesbegue integrable (since $\displaystyle \mathbb{Q}$ is countable and hence of measure zero).
RonL
This problem just does not make any sense. The way the Riemann integral is defined we use the condition that $\displaystyle f$ is bounded on $\displaystyle [0,1]$ which certainly makes it impossible for it to be onto $\displaystyle \mathbb{R}$. Unless you have a different understanding of integration, maybe you are thinking about improper integration?