For an HVAC application I'm searching for a way to average two 0-10 V signals with the ability to give a "weight" to one or another.
Example:
I have input A at 10 V and input B at 5 V.
If I make a dumb average I get 7.5 V.
I want to be able to give more importance to one signal.
Let's say input A is set at 50% and B 100%. I want an output at 6.667V ([10x0,5+5x1]/[1+0,5]).
I tried simulations online with an op-amp but can't find a way to do it. I made an average circuit using a voltage follower as described here and was hoping that replacing the resistor with a potentiometer would do the job, but unfortunately it didn't.
The highest voltage seems to pass through the potentiometer of the other input if its resistance is lower.
I tried many other things next (diodes, more op-amps, etc.) but I'm a beginner so I didn't manage to find the way to go.