edit: OK, I am making it simpler. Currently, the input varies from -1 to +1V, and the output is (obviously) -1 to +1V. I want the output to vary from 0 to +1V. Not just shifted up with a dc bias and gain halved. The negative half cycle should be folded up to the positive side... similar to what happens in full wave bridge rectifier. But that is floating, like my previous wrong circuit shows. I want the output (0-1V) to not be floating but ground referenced.
example:
input output
0 0
0.5 0.5
1 1
-0.5 +0.5 (sorry about previous typo in this line)
-1 1 (sorry about previous typo in this line)
hopefully this will explain
original post
Signal varies from 8 to 10V. I need the absolute value with 9V reference. i.e. 8V signal should give me 10V output, as well as 10V signal should give me 10V output. Is there a better way to do it?
i.e. any sway from 9V gives me the magnitude, disregarding whether it is up or down.
[edit: this circuit will not work. I need the output to be ground based.]
PS: I may have to put in a 1k feedback resistor, but ignoring it for the moment.
I want to actually build a 2 quadrant power supply, and having difficulty regulating the sink current. The rest is working fine.