I have a 10k rotary potentiometer which turns from 0° to 270°. I wire it to an Arduino with the middle pin (2) connected to an analog input (A0) and the other two pins (1 and 3) connected to 5V and GND.
simulate this circuit – Schematic created using CircuitLab
I know the potentiometer is a voltage divider between pin 1, 2 and 3 as above so as expected I get 5 volts on pin 2 when the potentiometer is turned left (0°), 0 volts when the potentiometer is turned right (270°) and something in between in the middle. The problem comes when I try to calculate the angle - voltage function. I expected that it would be a linear function that can be calculated from the two given points (0°, 5V) and (270°, 0V) but when I turn the potentiometer to 135° which is supposed to be the middle point I don't get 2.5 volts instead I get something around 1.5 volts. I also noticed that when close to 270° a single ° in rotation corresponds to a bigger voltage change than when closer to 0°. So is this normal or is my potentiometer busted? And if it is normal why is it so?
EDIT
I did some measurements and came up with the table below as Umar suggested
Degrees | Ohms | Delta
0° | 3 | -
45° | 480 | 480
90° | 972 | 492
135° | 1704 | 732
180° | 3423 | 1719
225° | 7280 | 3857
270° | 10300 | 3020
So Kevin White is correct it seems that I have a tapered audio potentiometer and the function is logarithmic (the blue curve in Kevin's answer). Thanks, everybody for your time and effort.