REM THIS IS A BICYCLE AND MOTORCYCLE DESIGN AID
REM THIS PROGRAM IS MEANT TO ACCOMPANY THE TEXT
REM " THE CHRONICLES OF THE LORDS OF THE CHAINRING"
REM THIS IS SPECIFICALLY BUILT TO INCLUDE
REM THE ANGULAR MOMENTUM OF THE WHEELS AND THE EFFECT OF TILLER.
DIM vel(6, 200)
DECLARE SUB graph (vel!(), n!, count!, konst!)
' INPUT ALL DISTANCE VALUES IN METERS, MASS IS KG
' INPUT ALL ANGLES IN DEGREES
SCREEN 12
PI = 3.141592654#
'we are metric
deg = PI / 180
REM .O254 CONVERTS INCHES TO METERS
REM ENTER YOUR GEOMETRY DATA HERE (CHANGE THE VALUE OF A, B ETC TO MATCH YOUR DESIGN)
'A =wheelbase ;
A = 1.18
'B = dist from rear axle to cg "riders belly button";
B = .55
'beta1 = head tube angle ;
beta1 = 60
'H =distance from the gnd to cg "riders belly button" ;
h = .67
REM mass 1 KG IS 2.2 LBS ;
M = 180 / 2.2
's= fork offset normal to headtube PLUS MEANS THE AXLE IS FORWARD OF THE STEERING AXIS;
s = .03
' Rh IS HANDLEBAR RADIUS
Rh = .3
' Til is the TILLER the position of the hands aft of the steering axis
Til = 4 * .0254
' Fha is the constant force of each hand hanging from the handlebars
' this is only an estimate. It is possible to pull harder to aid high
' speed riding.
Fha = 1
' Rt is the tire caseing radius
Rt = .5 * .0254
'KX = radius of gyration of the bike and rider about cg X axis
' estimate .26 for supine rider to .44 for vertical seat back
' more for a fully faired vehicle
KX = .35
'beta = complement of beta1
BETA = (90.01 - beta1) * PI / 180
'the program divideds by zero for a beta1 of zero
'r= radius of front wheel ;
r = .254
'rr = radius of the rear wheel
rr = 13 * .0254
'++++++++++++++++++++++++++++++++++++++++++++++++++++++++
' INCLUDING ANGULAR MOMENTUM OF THE WHEELS.
'RHO IS A REASONABLE ESTIMATE FOR THE MASS PER METER OF A LIGHT BIKE WHEEL/TIRE
RHO = .5
RF = r
rr = rr
'MASS MOMENTS OF INERTIA OF THE FRONT AND REAR WHEEL
IIF = 2 * PI * RHO * RF * RF * RF
IIR = 2 * PI * RHO * rr * rr * rr
'FOR MOTORCYCLE WHEELS, MEASURE MASS MOMENTS
CB = COS(BETA)
SB = SIN(BETA)
IFUN = (IIF / RF + IIR / rr) * CB / A
DELF = IFUN * (B / (A * h)) * KX * KX / (KX * KX + h * h)
OM = (IIF * CB / (RF * A)) * (SB + B * CB / h)
REM ADD ESTIMATES OF TILLER ON THE CONTROL SPRING K1
K1Til = -2 * Fha * Til
REM ===============================================
' WARNING ============
REM CHANGE NO DATA PAST THIS POINT
' del = trail
DEL = r * TAN(BETA) - s / COS(BETA)
DELK2 = DELF * (DEL * (CB) + Rt) + OM
G = 9.81
'v = velocity at start of plot ;
v = .1
' INPUTTING HANDLING QUALITY CONSTANTS
kc = (B * COS(BETA)) / (A * h)
kkkc = kc / Rh
kc1 = M * G * B * DEL * COS(BETA) * SIN(BETA) / A
KC2 = (DEL * COS(BETA) + Rt * SIN(BETA)) * M * B * COS(BETA) * (KX * KX / (KX * KX + h * h)) / (A * A)
KA = 1 / 1500
REM ADD THE EFFECT OF WHEEL MOMENTUM
KC2 = KC2 + DELK2
REM ADD THE EFFECT OF TILLER
kc1 = kc1 + K1Til
REM FIND FORK FLOP
FLOP = M * 9.81 * (B / A) * DEL * COS(BETA) / Rh
REM NOW FIND THE MINIMUM SPEED WHERE THE BIKE STOPS WOBBLING
mmmin = (kc1 / KC2)
IF (kc1 / KC2) < 0! THEN mmmin = .01
VVMIN = 3.6 * SQR(mmmin)
'FIND THE MAXIMUM SENSITIVITY
velmaxis = 0
maxes = 0
count = 1
nn = -1
77 vel(1, count) = 18
'1 is control MAX RECOMMENDED SENSTIVITY LINE
vel(2, count) = (kc1 - KC2 * v * v) / Rh
'2 is control spring rate
44 vel(5, count) = kc * v / (Rh + (KA / Rh) * (-kc1 + KC2 * v * v))
'5 is sensitivity
IF maxes < vel(5, count) THEN velmaxis = v
IF maxes < vel(5, count) THEN maxes = vel(5, count)
count = count + 1
v = v + .2
IF v < 15 THEN GOTO 77
velmaxis = velmaxis * 3.6
CLS
konst = 18
66
CLS
PRINT
PRINT " LOW SPEED HANDLING VALUES "
PRINT "for a headtube angle of "; beta1
PRINT "for a fork offset of "; s
PRINT "trail = "; DEL
PRINT "or = "; DEL / .0254; "INCHES"
PRINT
PRINT "FORK FLOP IS "; FLOP; "newtons/radian"
PRINT
PRINT
PRINT "Fork flop is an indicator of the bike to turn towards a lean"
PRINT " it aids us as a sort of auto pilot and should be between "
PRINT " 50 and 150 newtons per radian. If it is too much, the handlebars"
PRINT " will jerk too hard. If it is too little, the bike will require too"
PRINT "much attention."
PRINT
PRINT " WOBBLE SPEED IS "; VVMIN; "Km/Hr"
PRINT
PRINT "below this speed, your handlebars tend to deviate. "
PRINT "this is why new riders wobble at low speed when"
PRINT "the control spring is backward which makes the bike hard to control"
PRINT
PRINT
PRINT " hit enter to see a plot of the control spring, hit enter again to contiue. "
INPUT ll
CLS
konstd = 10
PRINT
PRINT " CONTROL SPRING VS VELOCITY"
PRINT
PRINT "stable values up"
konstd = -.1
CALL graph(vel(), 2, count, konstd)
LOCATE 26, 44
PRINT "VELOCITY -->"
INPUT ll
CLS
'
PRINT
PRINT
PRINT " HIGH SPEED HANDLING VALUES "
PRINT " At high speed, the bike reacts more to control inputs "
PRINT " this is termed sensitivity. the model used here is highly simplified"
PRINT " but, has been validated up to 40 miles per hour. Higher speeds might need "
PRINT " analysis that include angular accelerations and control damping "
PRINT " that have been ignored in this model."
PRINT
PRINT
PRINT " MAX SENSITIVITY IS "; maxes; " radians/meter"
PRINT
PRINT " at a speed of "; velmaxis; "km/hour"
PRINT
PRINT
PRINT " High speed plots may be in error above 40 mph. Control sensitivity "
PRINT " may be higher than predicted. "
PRINT " Maximum senstivity has been found to be 18 radians/meter for normal folks"
PRINT " higher values may be used by experienced riders."
PRINT
PRINT
PRINT
PRINT " hit enter to see the sensitivy plot"
INPUT ll
CLS
CLS
PRINT
PRINT " Roll Sensitivity "
konstd = 18
CALL graph(vel(), 5, count, konstd)
CALL graph(vel(), 1, count, konstd)
LOCATE 5, 44
PRINT "overcontrol line"
LOCATE 24, 44
PRINT "VELOCITY -->"
INPUT ll
CLS
PRINT
PRINT
PRINT " This computer modesl is incomplete, other derivatives change bike handling. "
PRINT " For more information and hints as to how to change handling "
PRINT " qualities, get the Lords of the chainring. "
PRINT
PRINT " email at wpatters@calpoly.edu"
SUB graph (vel(), n, count, konst)
KX = 630 / count
PI = 3.141592654#
FOR k = 1 TO count - 2
YY = -konst * vel(n, k) + 390
YYY = -konst * vel(n, k + 1) + 390
XX = KX * k + 10
XXX = KX * (k + 1) + 10
' PRINT YY; XX; XXX; YYY
' INPUT ll
LINE (XX, YY)-(XXX, YYY)
NEXT k
LINE (10, 390)-(630, 390)
END SUB