I need to measure a current from 1uA to 1A with a CM voltage up to 18v. I decide to go with a differential amplifier as per the following figure:
The expected Gain should be 50 V/V (=R5/R4) but at low currents it is much higher and not linear.
The gain reaches the expected value only starting from about 130mA and continuously decrease a bit all over the measurement range.
Since the Gain is not constant at all, I cannot calculate the current measuring Vout.
Is this unexpected behavior related to something wrong in the simulation (maybe because the opamp model) or am I missing something important in the circuit (I not able to test the circuit for a while)?
I have tried to buffer the differential amplifier input:
but I got fancy results: