Post by tsh73 on Mar 7, 2021 19:03:35 GMT
I happen to get this thing
It was out of order (knobs removed from right places) but after watchmen refused to fiddle with it I managed to fix it myself.
"KL" is obviosly "Krugovaya Lineika" that is Round Ruler. It went with manual, and stamp on it reads Feb 9 1968.
It has two faces - one log scale and other is Sine/Tan.
English manual available at
www.sliderulemuseum.com/Manuals/KL-1_RussianCircularSlideRule.pdf
at SlideRule museum, Soviet Era Slide Rules section.
www.sliderulemuseum.com/Soviet.htm
Log part I implement (not really interested in Sine/Tan part), here's what I got.
It has inner scale C (0..10) and outer scale A (1..100, squares)
Rotating dial (whole face), upper fixed indicator, and moving arrow.
There is a Pi mark (I got rather weird "П" mark instead of Pi) and C mark (sqr(4/pi), for calculation of circle area from diameter)
I tried rotate dial with drag'n'drop, but it is actually too clunky to use with a mouse.
So now it works like this:
* LMB inside circle rotates dial, setting number you click on against fixed indicator (upper mark, blue line)
* LMB out of circle rotates arrow (movable pointer, red one), set it to point where your mouse clicked.
* RMB inside circle rotates dial so that number you click sets against arrow (movable pointer, red one).
If you clicked off a bit - you can rotate arrow or dial (thing you clicked last) with left/right cursor key, one pixel a time.
Of cource since it is all digital inside it shows readings numbers at fixed indicator and movable pointer, both C and A scales.
Some examples (my Russian manual differs from English instructions I linked, but they both work)
Remember:
* Log scale ruler dives you digits - magnitude should be kept in mind!
* There is only so much info you can get per pixel. Digital reading will always show 3 digits, but you better watch how much precison could actually be seen.
1) 3*2
LMB 3 inner scale - rotate dial to set first factor to fixed indicator
LMB 1 moving pointer - set moving pointer to 1
RMB 2 inner scale - rotate dial so second factor goes on moving pointer
---
fixed indicator should read "6"
(you can continue multiplications)
2) 48/8
LMB 4.8 inner scale - rotate dial to set dividend to fixed indicator
LMB 8 moving pointer - set moving pointer to divider
RMB 1 - rotate dial so 1 goes on moving pointer
---
fixed indicator should read "6"
(you can continue divisions)
3) combined
2*12/6
LMB 2 inner scale - rotate dial to set first factor to fixed indicator
LMB 6 moving pointer - set moving pointer to divider
RMB 1.2 - rotate dial so second factor goes on moving pointer
---
fixed indicator should read "4"
4) square
pick a number on inner scale, read square on outer scale (5->25)
5) square root
pick a number on outer scale, read square on inner scale (25->5)
but bevare that sqr(4) is 2 but sqr(40) is 6.33 (or it says me so)
6) cube
say 6^3
LMB 6 inner scale - rotate dial to set number to fixed indicator
LMB 1 moving pointer - set moving pointer to 1
RMB sqr(6) - rotate dial so number (6) on outer scale goes on moving pointer
---
fixed indicator should read near "2.16" (after some nudging with arrow buttons I got just that)
7) area of circle
Say D=5. Formula is S=(Pi/4)*(D^2)
LMB 5 inner scale - rotate dial to set radius to fixed indicator
LMB C mark moving pointer - set moving pointer to C (about 1.128)
RMB 1 - rotate dial so 1 goes on moving pointer
---
fixed indicator on outer scale looks like 19.7
(JB says pi/4*5^2 is 19.6349541)
Have fun.
Of cource it full of cludges but it does work for me.
It was out of order (knobs removed from right places) but after watchmen refused to fiddle with it I managed to fix it myself.
"KL" is obviosly "Krugovaya Lineika" that is Round Ruler. It went with manual, and stamp on it reads Feb 9 1968.
It has two faces - one log scale and other is Sine/Tan.
English manual available at
www.sliderulemuseum.com/Manuals/KL-1_RussianCircularSlideRule.pdf
at SlideRule museum, Soviet Era Slide Rules section.
www.sliderulemuseum.com/Soviet.htm
Log part I implement (not really interested in Sine/Tan part), here's what I got.
It has inner scale C (0..10) and outer scale A (1..100, squares)
Rotating dial (whole face), upper fixed indicator, and moving arrow.
There is a Pi mark (I got rather weird "П" mark instead of Pi) and C mark (sqr(4/pi), for calculation of circle area from diameter)
I tried rotate dial with drag'n'drop, but it is actually too clunky to use with a mouse.
So now it works like this:
* LMB inside circle rotates dial, setting number you click on against fixed indicator (upper mark, blue line)
* LMB out of circle rotates arrow (movable pointer, red one), set it to point where your mouse clicked.
* RMB inside circle rotates dial so that number you click sets against arrow (movable pointer, red one).
If you clicked off a bit - you can rotate arrow or dial (thing you clicked last) with left/right cursor key, one pixel a time.
Of cource since it is all digital inside it shows readings numbers at fixed indicator and movable pointer, both C and A scales.
Some examples (my Russian manual differs from English instructions I linked, but they both work)
Remember:
* Log scale ruler dives you digits - magnitude should be kept in mind!
* There is only so much info you can get per pixel. Digital reading will always show 3 digits, but you better watch how much precison could actually be seen.
1) 3*2
LMB 3 inner scale - rotate dial to set first factor to fixed indicator
LMB 1 moving pointer - set moving pointer to 1
RMB 2 inner scale - rotate dial so second factor goes on moving pointer
---
fixed indicator should read "6"
(you can continue multiplications)
2) 48/8
LMB 4.8 inner scale - rotate dial to set dividend to fixed indicator
LMB 8 moving pointer - set moving pointer to divider
RMB 1 - rotate dial so 1 goes on moving pointer
---
fixed indicator should read "6"
(you can continue divisions)
3) combined
2*12/6
LMB 2 inner scale - rotate dial to set first factor to fixed indicator
LMB 6 moving pointer - set moving pointer to divider
RMB 1.2 - rotate dial so second factor goes on moving pointer
---
fixed indicator should read "4"
4) square
pick a number on inner scale, read square on outer scale (5->25)
5) square root
pick a number on outer scale, read square on inner scale (25->5)
but bevare that sqr(4) is 2 but sqr(40) is 6.33 (or it says me so)
6) cube
say 6^3
LMB 6 inner scale - rotate dial to set number to fixed indicator
LMB 1 moving pointer - set moving pointer to 1
RMB sqr(6) - rotate dial so number (6) on outer scale goes on moving pointer
---
fixed indicator should read near "2.16" (after some nudging with arrow buttons I got just that)
7) area of circle
Say D=5. Formula is S=(Pi/4)*(D^2)
LMB 5 inner scale - rotate dial to set radius to fixed indicator
LMB C mark moving pointer - set moving pointer to C (about 1.128)
RMB 1 - rotate dial so 1 goes on moving pointer
---
fixed indicator on outer scale looks like 19.7
(JB says pi/4*5^2 is 19.6349541)
Have fun.
Of cource it full of cludges but it does work for me.
'gonna be Round Log Scale Ruler
'tsh73 March 2021
pi=acs(-1)
e=exp(1)
nomainwin
desiredWidth = 500
desiredHeight = 500
gosub [ajustWindow]
'now, center window
UpperLeftX = (DisplayWidth - WindowWidth)/2
UpperLeftY = (DisplayHeight - WindowHeight)/2
open "Circular slide rule" for graphics_nsb_nf as #gr
#gr "trapclose [quit]"
#gr "down"
'#gr "fill white; flush"
#gr "home; posxy cx cy"
'#gr "when leftButtonDown [start]"
'#gr "when leftButtonMove [moving]"
'#gr "when leftButtonUp [end]"
#gr "when leftButtonUp [endLMB]"
#gr "when rightButtonUp [endRMB]"
#gr "when characterInput [letter]"
#gr "setfocus"
R=0.9*min(cx,cy)
RR=0.85*R
R3=0.97*R
R2=0.92*R
R1=0.84*R
r=0.8*R
r0=0.5*R 'extra big tick (1 - start)
r1=0.6*R 'big tick
r2=0.65*R 'med tick
r3=0.75*R 'small tick
'r2=0.95*R -outer
a0=0-pi/2
aArrow=0
moveDial=1
goto [draw]
wait
[letter]
keyCode=asc(right$(Inkey$,1))
'print keyCode
if keyCode<>_VK_LEFT and keyCode<>_VK_Right then wait
da = 1/r
if keyCode<>_VK_LEFT then da=0-da
if moveDial then
a0=(2*pi+a0-da) mod (2*pi)
else
aArrow=(2*pi+aArrow-da) mod (2*pi)
end if
'print a0
goto [draw]
[endLMB]
rq=sqr((MouseY-cy)^2+(MouseX-cx)^2)
moveDial=rq<r 'else move arrow
if moveDial then #gr "color black" else #gr "color red"
a00=atan2(MouseY-cy,MouseX-cx)
if moveDial then
a0=(2*pi+a0-pi/2-a00) mod (2*pi)
else
aArrow=(2*pi+a00) mod (2*pi)
end if
'notice a00*180/pi;" ";da*180/pi;" ";a0*180/pi
goto [draw]
[endRMB]
rq=sqr((MouseY-cy)^2+(MouseX-cx)^2)
moveDial=rq<r 'else move arrow
if not(moveDial) then wait
#gr "color black"
a00=atan2(MouseY-cy,MouseX-cx)
'print a0+pi/2, aArrow+pi/2, a00+pi/2,
if moveDial then
'a0=a0-pi/2-a00
'a0=a0+aArrow+a00+pi
a0=(2*pi-pi/2+(a0+pi/2)+(aArrow+pi/2)-(a00+pi/2)) mod (2*pi)
'print a0+pi/2
end if
'notice a00*180/pi;" ";da*180/pi;" ";a0*180/pi
goto [draw]
[start]
rq=sqr((MouseY-cy)^2+(MouseX-cx)^2)
moveDial=rq<r 'else move arrow
if moveDial then #gr "color black" else #gr "color red"
a00=atan2(MouseY-cy,MouseX-cx)
'first line
#gr "rule xor"
a000=a00
x1=r*cos(a000)+cx
y1=r*sin(a000)+cy
#gr "home; goto ";x1; " ";y1
wait
[moving]
'clear old line
x1=r*cos(a000)+cx
y1=r*sin(a000)+cy
#gr "home; goto ";x1; " ";y1
'draw new one
a000=atan2(MouseY-cy,MouseX-cx)
x1=r*cos(a000)+cx
y1=r*sin(a000)+cy
#gr "home; goto ";x1; " ";y1
wait
[end]
#gr "rule over"
a01=atan2(MouseY-cy,MouseX-cx)
da=a01-a00
if moveDial then
a0=a0+da
else
aArrow=aArrow+da
end if
'notice a00*180/pi;" ";da*180/pi;" ";a0*180/pi
[draw]
#gr "cls"
#gr "home; color red; circle 5; color black"
#gr "home; circle ";R
if moveDial then #gr "size 2"
#gr "home; circle ";r
#gr "size 1"
a=0
x1=r*cos(a0+a)+cx
y1=r*sin(a0+a)+cy
x2=r0*cos(a0+a)+cx
y2=r0*sin(a0+a)+cy
#gr "line ";x1;" ";y1;" ";x2;" ";y2
sz=5
daa=4/180*pi
x1=0.6*r2*cos(a0+a-daa)+cx
y1=0.6*r2*sin(a0+a-daa)+cy
#gr "place ";x1;" ";y1
#gr Rotext$((a0+a)/pi*180+90,sz,"1")
#gr "down"
n=1
dn=1
while n < 10
a=log10(n)*2*pi
x1=r*cos(a0+a)+cx
y1=r*sin(a0+a)+cy
x2=r1*cos(a0+a)+cx
y2=r1*sin(a0+a)+cy
#gr "line ";x1;" ";y1;" ";x2;" ";y2
'#gr "\";n
if int(n)=n and n>1 then
sz=5
daa=4/180*pi
x1=0.7*r2*cos(a0+a-daa)+cx
y1=0.7*r2*sin(a0+a-daa)+cy
#gr "place ";x1;" ";y1
#gr Rotext$((a0+a)/pi*180+90,sz,str$(n))
#gr "down"
end if
if n >=1 then dn=0.5
n=n+dn
wend
n=1
dn=0.1
while n < 10
a=log10(n)*2*pi
x1=r*cos(a0+a)+cx
y1=r*sin(a0+a)+cy
x2=r2*cos(a0+a)+cx
y2=r2*sin(a0+a)+cy
#gr "line ";x1;" ";y1;" ";x2;" ";y2
if n>1 and n<2 then
sz=4
daa=4/180*pi
x1=0.8*r2*cos(a0+a-daa)+cx
y1=0.8*r2*sin(a0+a-daa)+cy
#gr "place ";x1;" ";y1
#gr Rotext$((a0+a)/pi*180+90,sz,str$(int(n*10-10)))
#gr "down"
end if
n=n+dn
if n >=6 and dn=0.1 then n=6:dn=0.5
wend
n=1
dn=0.02
while n < 10
a=log10(n)*2*pi
x1=r*cos(a0+a)+cx
y1=r*sin(a0+a)+cy
x2=r3*cos(a0+a)+cx
y2=r3*sin(a0+a)+cy
#gr "line ";x1;" ";y1;" ";x2;" ";y2
n=n+dn
if n >=2 and dn=0.02 then n=2:dn=0.05
if n >=2 and dn=0.02 then n=2:dn=0.05
if n >=6 and dn=0.05 then n=6:dn=0.1
wend
'pi
a=log10(pi)*2*pi
x1=r2*cos(a0+a)+cx
y1=r2*sin(a0+a)+cy
x2=r0*cos(a0+a)+cx
y2=r0*sin(a0+a)+cy
#gr "line ";x1;" ";y1;" ";x2;" ";y2
sz=5
daa=4/180*pi
x1=0.6*r2*cos(a0+a-daa)+cx
y1=0.6*r2*sin(a0+a-daa)+cy
#gr "place ";x1;" ";y1
#gr Rotext$((a0+a)/pi*180+90,sz,"p")
#gr "down"
'C = sqr(4/pi) for area of circle from diameter
a=log10(sqr(4/pi))*2*pi
x1=r*cos(a0+a)+cx
y1=r*sin(a0+a)+cy
x2=r1*cos(a0+a)+cx
y2=r1*sin(a0+a)+cy
#gr "line ";x1;" ";y1;" ";x2;" ";y2
sz=5
daa=4/180*pi
x1=0.7*r2*cos(a0+a-daa)+cx
y1=0.7*r2*sin(a0+a-daa)+cy
#gr "place ";x1;" ";y1
#gr Rotext$((a0+a)/pi*180+90,sz,"C")
#gr "down"
'square dial
n=1
while n < 100
a=log10(n)*2*pi/2
x1=r*cos(a0+a)+cx
y1=r*sin(a0+a)+cy
x2=R3*cos(a0+a)+cx
y2=R3*sin(a0+a)+cy
#gr "line ";x1;" ";y1;" ";x2;" ";y2
if int(n)=n and n<10 then
sz=5
daa=1/180*pi
x1=0.87*R*cos(a0+a+daa)+cx
y1=0.87*R*sin(a0+a+daa)+cy
#gr "place ";x1;" ";y1
#gr Rotext$((a0+a)/pi*180+90,sz,str$(n))
#gr "down"
end if
if int(n/10)=n/10 then
sz=5
daa=4/180*pi
x1=0.87*R*cos(a0+a-daa)+cx
y1=0.87*R*sin(a0+a-daa)+cy
#gr "place ";x1;" ";y1
#gr Rotext$((a0+a)/pi*180+90,sz,str$(n))
#gr "down"
end if
select case
case n<10
dn = 0.5
case n<100
dn=5
'case else
' h = 10
end select
n=n+dn
wend
n=1
while n < 100
a=log10(n)*2*pi/2
x1=r*cos(a0+a)+cx
y1=r*sin(a0+a)+cy
x2=R1*cos(a0+a)+cx
y2=R1*sin(a0+a)+cy
#gr "line ";x1;" ";y1;" ";x2;" ";y2
select case
case n<2
dn = 0.05
case n+0.000001<6
dn=0.1
case n+0.000001<10
dn=0.25
case n+0.000001<20
dn=0.5
case n+0.000001<60
dn=1
case else
dn=2.5
end select
n=n+dn
wend
n=1
dn=0.1
while n < 2
a=log10(n)*2*pi/2
x1=r*cos(a0+a)+cx
y1=r*sin(a0+a)+cy
x2=R2*cos(a0+a)+cx
y2=R2*sin(a0+a)+cy
#gr "line ";x1;" ";y1;" ";x2;" ";y2
n=n+dn
wend
n=10
dn=1
while n < 20
a=log10(n)*2*pi/2
x1=r*cos(a0+a)+cx
y1=r*sin(a0+a)+cy
x2=R2*cos(a0+a)+cx
y2=R2*sin(a0+a)+cy
#gr "line ";x1;" ";y1;" ";x2;" ";y2
n=n+dn
wend
'pi-on squared scale
a=log10(pi)*2*pi/2
x1=0.84*R*cos(a0+a)+cx
y1=0.84*R*sin(a0+a)+cy
x2=0.9*R*cos(a0+a)+cx
y2=0.9*R*sin(a0+a)+cy
#gr "line ";x1;" ";y1;" ";x2;" ";y2
sz=5
daa=1/180*pi
x1=0.87*R*cos(a0+a+daa)+cx
y1=0.87*R*sin(a0+a+daa)+cy
#gr "place ";x1;" ";y1
#gr Rotext$((a0+a)/pi*180+90,sz,"p")
#gr "down"
' up tick - unmoving
a=0-pi/2
x1=R*cos(a)+cx
y1=R*sin(a)+cy
x2=r3*cos(a)+cx
y2=r3*sin(a)+cy
#gr "color blue"
#gr "line ";x1;" ";y1;" ";x2;" ";y2
#gr "place ";10;" ";20
pow=(((4*pi-(a0+pi/2)) mod (2*pi))/(2*pi))
#gr "\";using("##.###",10^pow)
#gr "\";using("##.###",(10^pow)^2)
'pointer arrow
#gr "color red"
x1=RR*cos(aArrow)+cx
y1=RR*sin(aArrow)+cy
x2=r0*cos(aArrow+pi)+cx
y2=r0*sin(aArrow+pi)+cy
#gr "line ";x1;" ";y1;" ";x2;" ";y2
if moveDial then
x2=r0*cos(aArrow+pi+1/r0)+cx
y2=r0*sin(aArrow+pi+1/r0)+cy
#gr "line ";cx;" ";cy;" ";x2;" ";y2
x2=r0*cos(aArrow+pi-1/r0)+cx
y2=r0*sin(aArrow+pi-1/r0)+cy
#gr "line ";cx;" ";cy;" ";x2;" ";y2
else
#gr "size 2"
x1=r0*cos(aArrow)+cx
y1=r0*sin(aArrow)+cy
#gr "line ";x1;" ";y1;" ";x2;" ";y2
#gr "size 1"
end if
#gr "place ";2*cx-100;" ";20
'#gr "\";aArrow
pow=(((2*pi-(a0+pi/2)+(aArrow+pi/2)) mod (2*pi))/(2*pi))
#gr "\";using("##.###",10^pow)
#gr "\";using("##.###",(10^pow)^2)
#gr "flush"
wait
[quit]
timer 0
close #gr
end
function log10(x)
log10=log(x)/log(10)
end function
'-------------------------------------------------
[ajustWindow]
UpperLeftX = 20
UpperLeftY = 20
WindowWidth = 200 '100 seems to be too small - works different
WindowHeight = 100
' MENU #gr, "dummy"
open "Ajusting..." for graphics_nsb_nf as #gr
' graphics
' graphics_nsb
' graphics_nsb_nf
#gr, "home ; down ; posxy x y"
'x, y give us width, height
width = 2*x : height = 2*y
close #gr
slackX = 200-width
slackY = 100-height
WindowWidth = desiredWidth + slackX
WindowHeight = desiredHeight + slackY
return
'---------------------------
function atan2(y,x)
pi = acs(-1) 'could be made global to save some ticks
if x <> 0 then arctan = atn(y/x)
select case
case x > 0
atan2 = arctan
case y>=0 and x<0
atan2 = pi + arctan
case y<0 and x<0
atan2 = arctan - pi
case y>0 and x=0
atan2 = pi / 2
case y<0 and x=0
atan2 = pi / -2
end select
end function
'--------------------------------
function Rotext$(ang,size,txt$)
ang = int(ang)
diagonal=int(sqr(2*(size^2)))
size = int(size)
text$=""
'NnEeSsWwUDC, small letter +45 degrees
dim stroke$(11)
stroke$(1)="north;turn "; ang;";go ";size; ";" 'North
stroke$(2)="north;turn "; 45+ang;";go ";diagonal;";" 'North East
stroke$(3)="north;turn "; 90+ang;";go ";size; ";" 'East
stroke$(4)="north;turn ";135+ang;";go ";diagonal;";" 'South East
stroke$(5)="north;turn ";180+ang;";go ";size; ";" 'South
stroke$(6)="north;turn ";225+ang;";go ";diagonal;";" 'South West
stroke$(7)="north;turn ";-90+ang;";go ";size; ";" 'West
stroke$(8)="north;turn ";-45+ang;";go ";diagonal;";" 'North West
stroke$(9)="up;"
stroke$(10)="down;"
minSz=int(size/4): if minSz<1 then minSz=1
stroke$(11)="circle ";minSz;";"
for i=1 to len(txt$)
letter$=mid$(txt$,i,1)
select case letter$
case " ":t$= "UEEE"
case "A":t$= "DNNNneSWWEESSUE"
case "B":t$= "DEENNWWEnNWWSSSSUEEE"
case "C":t$= "UEDEWwNNnEUSSSSE"
case "D":t$= "DEnNNwWSSSSUEEE"
case "E":t$= "DEEWWNNEEWWNNEEUSSSe"
case "F":t$= "DNNEEWWNNEEUSSSe"
case "G":t$= "DNNNnEUsSDESsWUEEE"
case "H":t$= "DNNNNSSEENNSSSSUE"
case "I":t$= "DENNNNWEEWSSSSEUE"
case "J":t$= "NDenNNNWUSSSSEUE"
case "K":t$= "UEEDNNWWEnNUWWDSSSSUEEE"
case "L":t$= "NNNNDSSSSEEUE"
case "M":t$= "DNNNNeSNnSSSSUE"
case "N":t$= "DNNNNeeNNSSSSUE"
case chr$(209):t$= "DNNNeeNNUnWDWWEEUSDSSSUE"
case "O":t$= "DNNNnESSSsWUEEE"
case "P":t$= "DNNNNEESSWWSSUEEE"
case "Q":t$= "DNNNnESSSsWUnDeUE"
case "R":t$= "UEEDNNWWEnNWWSSSSUEEE"
case "S":t$= "DEnNWWNnEUSSSe"
case "T":t$= "UNNNNDEEWSSSSUEE"
case "U":t$= "UNDNNNSSSSEENNNNUSSSSE"
case "V":t$= "UNDNNNSSSenNNNUSSSSE"
case "W":t$= "UNNNNDSSSSneNNNNSSSUe"
case "X":t$= "DNnnNUWWDSeeSUE"
case "Y":t$= "UEDNNwNUEEDSsUee"
case "Z":t$= "UNNNNDEESssSEEUE"
case "0":t$= "UEDnNNwsSSeUEE"
case "1":t$= "UNNNDnSSSSUEE"
case "2":t$= "UNNNDnESSssEEUE"
case "3":t$= "UNNNDnESsesWUEEE"
case "4":t$= "UnnDWWnnSSSSUE"
case "5":t$= "DEnNWWNNEEUeSSS"
case "6":t$= "UNNNnEDWsSSSEENNWWUeeE"
case "7":t$= "DNnnNWWUeeSSE"
case "8":t$= "DNnwneseSWWUEEE"
case "9":t$= "DEnNNNWsSEEUeS"
case "e":t$= "UEEDWwNneSWWUeEE"
case "p":t$= "DNNNEESSSUE"
case ".":t$= "UEDCUEE"
case ",":t$= "UEDCsUnEE"
case "!":t$= "UEDCUNDNNNUeeSS"
case "?":t$= "UEDCUNDNnNWsUeee"
case else: t$= "UnDNNESSWUeE"
end select
'process t$
r$=""
for j = 1 to len(t$)
r$=r$+stroke$(instr("NnEeSsWwUDC", mid$(t$,j,1)))
next
text$ = text$+r$
next
Rotext$=text$
end function