[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference noted::bicycle

Title: Bicycling
Notice:Bicycling for Fun
Moderator:JAMIN::WASSER
Created:Mon Apr 14 1986
Last Modified:Fri Jun 06 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:3214
Total number of notes:31946

346.0. "Gear ratio calculator" by BAEDEV::RECKARD () Tue Jun 16 1987 16:28

    Here's a little program to calculate gear ratios.  You enter the number
    of cogs on your front chainwheel(s), and the number of cogs in the rear
    freewheel cluster, and out comes this nifty chart.  It's in DIBOL!!
    No apologies, just an explanation - I threw it together years ago (before
    DIBOL-83) and monkeyed around with it today to get it to compile.  I'm
    sure it can be done better.
    Just extract this, edit out the Notes stuff, then
         $ DIBOL filename
         $ LINK filename
         $ RUN filename
    Or, COPY BAEDEV::DUA0:[RECKARD]GEARS.EXE

RECORD
    ANS    ,A2
    CHAN   ,D1,1
    CNT    ,D1
    CNT2   ,D1
    CNTA   ,A1
    FRONT  ,3D2
    NUM    ,D5
    REAR   ,7D2
    RMASK  ,A5,'ZZX.X'
    TMASK  ,A2,'ZZ'
RECORD LINE
    A      ,A2
           ,A4
    B      ,A5
           ,A4
    C      ,A5
           ,A4
    D      ,A5
RECORD HEAD
           ,A8
    E      ,A2
           ,A7
    F      ,A2
           ,A7
    G      ,A2
PROC
    OPEN(1,I,'TT:')
    DISPLAY(1,<POS:(1,1),ERASE:1>)
    CLEAR FRONT, REAR
TOP,
    CLEAR LINE, HEAD, CNT
    DISPLAY(1,'Enter chainring sizes',10,13)
FRONTA,
    INCR CNT
FRONTB,
    CNTA=CNT
    IF (CNT.EQ.1) DISPLAY(1,9,'<Return> to exit: "XX" for "same"',13)
    DISPLAY(1,CNTA,'. ')
    READS(1,ANS)
    IF (CNT.EQ.1. AND .ANS.EQ.'XX') GOTO SAME1
    ONERROR FRONTB
    FRONT(CNT) = ANS
    IF (FRONT(CNT).EQ.0)
    THEN
        IF (CNT.GT.1)
            THEN FOR CNT2 FROM CNT THRU 3 FRONT(CNT2) = 0
        ELSE GOTO ENDOFF
    ELSE
        IF (CNT.LT.3) GOTO FRONTA
SAME1,
    CNT=0
    DISPLAY(1,10,13,'Enter freewheel sizes',10,13)
REARA,
    INCR CNT
REARB,
    CNTA=CNT
    IF (CNT.EQ.1) DISPLAY(1,9,'"XX" for "same"',13)
    DISPLAY(1,CNTA,'. ')
    READS(1,ANS)
    IF (CNT.EQ.1. AND .ANS.EQ.'XX') GOTO HEAD
    ONERROR REARB
    REAR(CNT) = ANS
    IF (CNT.LT.7)
        BEGIN
            IF (REAR(CNT).EQ.0)
                THEN FOR CNT2 FROM CNT THRU 7 REAR(CNT2) = 0
            ELSE GOTO REARA
        END
HEAD,
    E=FRONT(1),TMASK
    F=FRONT(2),TMASK
    G=FRONT(3),TMASK
    DISPLAY(CHAN,10,13,HEAD,10,13,'-----------')
    IF (FRONT(2).NE.0) DISPLAY(CHAN,'----------')
    IF (FRONT(3).NE.0) DISPLAY(CHAN,'----------')
    CNT=0
LOOP,
    INCR CNT
    IF (CNT.GT.7. OR .REAR(CNT).EQ.0) GOTO END
    A=REAR(CNT),TMASK
    NUM=(FRONT(1)*1000/REAR(CNT)*27)#2
    B=NUM,RMASK
    IF (FRONT(2).EQ.0) GOTO PRINT
    NUM=(FRONT(2)*1000/REAR(CNT)*27)#2
    C=NUM,RMASK
    IF (FRONT(3).EQ.0) GOTO PRINT
    NUM=(FRONT(3)*1000/REAR(CNT)*27)#2
    D=NUM,RMASK
PRINT,
    DISPLAY(CHAN,10,13,LINE)
    GOTO LOOP
END,
    DISPLAY(CHAN,13,10,10,10,10)
    GOTO TOP
ENDOFF,
    DISPLAY(1,<POS:(1,1),ERASE:1>)
    CLOSE 1
    CLOSE 2
    STOP
T.RTitleUserPersonal
Name
DateLines
346.1The .EXE is hereBAEDEV::RECKARDMon Jun 22 1987 08:333
    BAEDEV::DUA0:[RECKARD]GEARS.EXE.

    But BAEDEV may not be here (on the net at all, or by that name) for long.
346.2XANADU::RECKARDJon Reckard, 381-0878, ZKO3-2/T63Thu May 23 1991 11:3114
For anyone interested, here's an updated pointer (only four years late!).

MRFLEX::SYS$PUBLIC:GEARS.EXE

Inexplicably, it compiled and ran on DIBOL V4.0 (DIBOL85).

From .0 ...

>   Here's a little program to calculate gear ratios.  You enter the number
>   of cogs on your front chainwheel(s), and the number of cogs in the rear
>   freewheel cluster, and out comes this nifty chart.  It's in DIBOL!!
>   No apologies, just an explanation - I threw it together years ago (before
>   DIBOL-83) and monkeyed around with it today to get it to compile.  I'm
>   sure it can be done better.
346.3some explanation pleaseIJSAPL::JMULDERFri May 24 1991 05:557
    Hello,
    I copied your program and it works. But could you add some
    clarification as to the output: in what kind of unit is the relation
    between front and rear chainwheel given?
    
					Jan Mulder
    
346.4Some explanationXANADU::RECKARDJon Reckard, 381-0878, ZKO3-2/T63Fri May 24 1991 10:5346
Fair question.  Here's a sample run I just did, with some hypothetical
chainrings and freewheels.  (Oh yes, "sizes" means teeth):

$ run gears
Enter chainring sizes
1. 30   <Return> to exit: "XX" for "same"
2. 40
3. 50

Enter freewheel sizes
1. 12   "XX" for "same"
2. 14
3. 17
4. 20
5. 24
6. 28
7. 32

        30       40       50
-------------------------------
12     67.5     90.0    112.5
14     57.8     77.1     96.4
17     47.6     63.5     79.4
20     40.5     54.0     67.5
24     33.8     45.0     56.2
28     28.9     38.6     48.2
32     25.3     33.8     42.2


I think someone else may be able to explain ratios better, but it's something
like:  how many inches a 27" wheel travels in one pedal revolution.  The formula
I use is:  front teeth / rear teeth * 27.  Yes, this program only does 27".

The idea of it all (as I remember from way back) is to put together chainrings
and freewheels in such a combination that you get the least amount of duplicated
ratios, providing the most "speeds" from your 10-speed or 12-speed or whatever.
For example, my 30/24 combination is identical to my 40/32 combination.  So my
21-speed becomes (effectively) a 20-speed.

Of course proper shifting technique dictates that you'd never use the largest
chainring with the smallest on the freewheel, etc.

Thanks for trying it.

P.S.  My "same" prompt in the program lets you, for example, change one of the
chainrings, then type "xx" at the freewheel prompt, to leave that alone.
346.5Miscellaneous rubbishFILMS::WIDDOWSONLe soleil au z�nith me surexciteFri May 24 1991 11:3914
    The inches is a marvellous British (US as well) concept of  how large
    the driving wheel would be (diameter) if it was a direct drive (ie what
    I refer to as a Penny-farthing) - fancy rdiding a bike with rear
    steering and a 112 inch front wheel with peddles ?
    
    In France (when they care to do the sums) they give the distance the
    bike travels for each peddle turn.  Mostly tho' they just say the teeth
    count on the rings.
    
    rod
    
    (of course if you had bought a december version of cycling reekly you
    would have a neat plastic card with a ratio tavble on one side and the
    dates of the classics on the other...)
346.6FILMS::WIDDOWSONLe soleil au z�nith me surexciteFri May 24 1991 11:493
    >The inches is a marvellous British (US as well) concept of  how large
    
    I should have said "(US as well ?)"
346.7to get there from here...SUSHI::KMACDONALDsushi: not just for breakfast!Fri May 24 1991 12:446
>    >The inches is a marvellous British (US as well) concept of  how large
    
And, of course, the gear inches number can be turned into "how far you 
travel with each pedal rev" by multiplying it by your favorite 
approximation of pi.....
                             ken
346.8A gear ratio calculator for IBM PCsDRIFT::WOODLaughter is the best medicineSat May 25 1991 15:1354
    I've uploaded another gear ratio calculator, but this one only runs on
    IBM PC's.  It has quite a few features including plotting the gear
    inches for all gear combinations.  It also produces tables showing mph
    for given gear ratios and cadence.
    
    I've placed the file temporarily in SOJU""::GEAR.ZOO and you can copy
    it from there.  Download it to your PC using your favorite method.
    
    This came orginally from comp.binaries.ibm.pc and is probably on SIMTEL
    somewhere.
    
    I've attached the doc file below.
    
    Enjoy!
    
    John
    
                               Gear.doc

       Calculates custom charts and/or graphs of bicycle gear ratios.
       "Gear" sorts from 1 to 27 ratios so that the shift pattern is
       implied by the text output on "F4".  (From 1 to 3 chain rings
       in the front and from 1 to 9 cogs on the rear cluster.)
       "Gear" also produces custom charts or files relating peddling
       cadence to the bikes speed and its gear ratios.  The ratios and
       speed tables may be printed out or sent to a file and may be
       used for later reference.

       Select your particular combination of gears on "F5" and display
       the results.  Show the relation to speed from "F8".  Or use
       the other menu picks to customize the program to your liking.
       "Gear" is fast, friendly and easy to use with menus, save/
       restore files and the ability to customize it with an initialization
       file.  It is not copy protected and you are encouraged to
       distribute it as widely as possible: "shareware".  However
       it is copyrighted and you are encouraged to register it.  Please
       see the "Gear.hlp" file for more information and hardware
       requirements and licensing information or press "F9" once
       the program is loaded.

       Installation:
       "Gear" is not copy protected so the DOS "copy" command may
       be used to install it on any disk.  To get everything
       copy "G*.*" from your source to your target.  The minimal
       you need is "gear.exe" but you might like to get the "*.hlp"
       files or "g*.hlp".  "Gear" may be run from a 360KB floppy or from
       a hard disk or a sub-directory.  "Gear.ini" and "gear.dat" are
       easily re-generated by the program itself from "F6" and "F5".
       Every menu pick has some explanation in one of the help files.
       If you use this product please support it.

       Thank you for your support!
                  R. Angstadt
    
346.9nit?NOVA::FISHERIt&#039;s SpringWed May 29 1991 08:523
    The penny farthing that I road had steering on the front (big) wheel.
    
    ed
346.10GEAR.ZOO homeUKAOS::OVERMEYERThu Aug 01 1991 10:049

 regarding .8 does anybody know where I can get a copy of gear.zoo?
I looked at SOJU""::GEAR.ZOO and it was not there.

thanks


Bob