It is relatively standard to prove $f\in BV([a,b])$ iff $f$ can be written as a difference of two monotone increasing functions.
QUESTION: I have two functions, and I am trying to compute the total variation and actually find the explicit monotone functions.
My first function is $f:[-10,10]\rightarrow \mathbb{R}$, $f(x)=|x+1|-2|x-2|$ My second function is: $g:[-4\pi, 2\pi]\rightarrow \mathbb{R}$, $g(x)=sin(x)+cos(x)$.
I am using the Jordan decomposition for functions so I want to write $f$ as $f=f^{+}-f^{-}$. I also know the variation $V(f)=f^{+}(b)-f^{+}(b)+f^{-}(b)-f^{-}(a)$
Note $\forall x\in \mathbb{R}$, we have $x^{+}=max\{0,x\}$ and $x^{-}=-min\{x,0\}$.
let $P(f)=\{x_0=-10<x_1<...<x_{n-1}<x_n=10\}$ be a partition for $f$. let $P(g)=\{x_0=-4\pi< x_1<...<x_{n-1}<x_n={2\pi}\}$ be a partition for $g$
Define $S_{P}(f)^{+}=\sum_{i=1}^{n}[f(x_i)-f(x_{i-1})]^{+}$ (positive terms of the function $f$)
and $S_{P}(f)^{-}=\sum_{i=1}^{n}[f(x_i)-f(x_{i-1})]^{-}$ (negative terms of the function)
similarly, we let the positive and negative variation of the function be defined as
$V(f)^{+}=sup\{S_P\}^{+}$, $V(f)^{-}=sup\{S_P\}^{-}$ respectively and the total variation is $V(f)=V(f)^{+}+V(f)^{-}$.
I have an issue going from these definitions to the explicit computations I need. I know for $g$ I could argue it's Lipschitz (since derivative is bounded), hence absolutely continuous, hence BV, but I want to use the definition directly. For $f$, I am stuck.
Finally, when you compute the variation of a function, can we use finite partitions (such as $n=4$), or do we need to compute the variation for an infinite sum? It seems that proving a function is NOT of bounded variation always involves considering an infinite sum for the partition.
Your functions $f$ and $g$ here are quite tame. Break up your interval $[a,b]$ into finitely many intervals $[a_0,a_1]$, $[a_1,a_2]\ldots,[a_{n-1},a_n]$ on which $f$ is monotone. Then the total variation of $f$ on each $[a_{j-1},a_j]$ is $|f(a_j)-f(a_{j-1})|$ and the total variation of $f$ is $\sum_{j=1}^n|f(a_j)-f(a_{j-1})|$.