me said:
That is sort of like cheating.
I was trying to get you to figure it out.
You already guessed that it was proportional when you said it was 1/2 Vcc when both were equal.
With R1 between gnd and the output and R2 from output to Vcc the voltage is Vcc times the fraction of the resistance that is R1.
Vout = Vcc(R1/(R1+R2))
-------------------------------
another approach
-------------------------------
we know this from ohms law.
V=IR
The current is the same in R1 and R2 if the
current drawn by the output is insignificant. In most cases we use a divider to create a reference voltage so that is the case.
We can find the current from gnd to Vcc because we know the total resistance Rt = R1 + R2.
V=IR or I = Vcc/Rt
now that you know the current you can solve for the voltage across R1.
V = I * R1
at this point just plug in the numbers for I and R1.
I hope I did not screw this up
3v0