If you can model the waveform as a series of straight line segments, you can do it.
Examine the tanh graph. You can DC offset it, amplitude scale it, x axis scale it , and x axis offset it.
You adjust these 4 parameters to make the ramping part of the graph line up with each straight line segment of the approximation.
If you can model the waveform as a series of straight line segments, you can do it.
Examine the tanh graph. You can DC offset it, amplitude scale it, x axis scale it , and x axis offset it.
You adjust these 4 parameters to make the ramping part of the graph line up with each straight line segment of the approximation.