% Function
x = [0:1023];
R = (x * 8171.88) ./ (2542.97 - x);

% my testet Resistors
O = [1.2 3.3 33 100 220 470 750 1000 2200 4700];

V = [16 16 20 40 80 144 216 288 536 932];

% hold plots
hold on

% draw functions
plot(R, 'r')
plot(V,O, 'g')


axis([0 500 0 1024])
xlabel("Value")
ylabel("Ohm")
text(90, 600, "Function (red)")
text(80, 180, "tested Values (green)")

pause
