define an infinitely differentiable function that maps different sizes interval in same size intervals.

18 Views Asked by At

I have an interval split in two parts $I =[0, 1] = [0, th] \cup (th, 1] = I_1 \cup I_2$.

I need to map the interval to a larger interval as: $f: [0,1] -> [0, 100]$ where:

1) $f(0)=0, f(1)=100, f(th)=50$

2) $f$ is defined by two functions $f_1, f_2$ such that:

$f(x)=f_1(x)$ if $x\in I_1 $ and $f(x)=f_2(x)$ if $x\in I_2$

3) $f$ is monotone

4) $f_1$ or $f_2$ is linear

5) $f\in C^{\infty}$

Here some context related to the practical application of the problem:

I have an anomaly detection system that assigns to each event an anomaly score $s\in [0,1]$. An anomaly is raised if $s>th$.

The final results needs to be a score $\hat s \in [0, 100]$ where an anomaly is raised if $\hat s > 50$.

Currently $f_1$ and $f_2$ are linear functions. This makes $f$ not derivable at $th$ (only the first 4 conditions above are respected). The current situation is very undesirable. This is because it is interesting to visually evaluate new anomalies and compare them with their historical anomaly score. A new anomaly that has a score $s(t): ~~s(t- \delta) < th < s(t) $ but $s(t-\delta) \sim s(d)$ is less worrying than an anomaly where $s(t) >> s(t-\delta)$. Unfortunately due to the irregularity of $f$ in $th$ this can not be evaluated from $\hat s$.

In other words I am trying to move the irregularity away from the $th$ point.