Game Programming and Development Tools

Math Formula for lawn bowling? – AmazingJas

AmazingJas

Member

Posts: 437
From: Sydney, NSW, AUSTRALIA
Registered: 04-03-2003
Hi guys, I'm thinking about making a lawn bowls sim, and I need a good formula for controlling the lawn bowl. For those of you who don't know what lawn bowls is, it's a bit like a cross between ten pin bowling, golf, and destruction derby. There is a target ball (called a Jack) and the aim is to have your bowl end up as close as possible to it, but other players can knock your bowl out of the way and get theirs closer to win, or knock the target bowl to a more advantageous position.

The bowls are weighted off-centre so that they curve and that's what I need a formula for. Probably something similar to a gravity curve, but on a horizontal plane, or perhaps similar to the gravity effect on a projectile (parabellum rings a bell?). Anyway, if you have some ideas, let me know. Thanks.

I just found a picture describing a typical curve:
http://www.bowlsengland.com/images/erink1.gif

[This message has been edited by AmazingJas (edited July 26, 2003).]

CobraA1

Member

Posts: 926
From: MN
Registered: 02-19-2001
I don't ever remember playing with any sets of balls with an off-center center of gravity :/.

I think my family calls it "Bocce ball," although real Bocce ball has courts, but we play it on a lawn.

If I remember my physics right, it won't actually curve until it hits the ground - the center of gravity should still follow a regular parabola.

In any case, the exact course will probably depend on the center of gravity on release, and which way the ball is spinning.

------------------
There are only 10 types of people - those who understand binary, and those who don't.

AmazingJas

Member

Posts: 437
From: Sydney, NSW, AUSTRALIA
Registered: 04-03-2003
I think Bocce has uniform balls, but in lawn bowls, they definitely curve, a lot. In lawn bowls, the ball is always on the ground, right from the bowlers hand and you can put spin on em. All you can do is adjust your aim, and power, that's it.
BKewl

Member

Posts: 144
From: St. Charles, MO, USA
Registered: 07-10-2002
You may want to check out various types of splines. The curves on that picture aren't quite parabolas, so splines might fit the bill better. There are a bunch of kinds, so you might want to shop around. Some popular ones are bezier curves and b-splines (i.e. NURBS, etc.)
CobraA1

Member

Posts: 926
From: MN
Registered: 02-19-2001
I would personally just calculate forces and calculate the movement on the fly instead of pre-calculating a path.

------------------
There are only 10 types of people - those who understand binary, and those who don't.

Gift
Member

Posts: 85
From: Palatine, IL, USA
Registered: 02-11-2001
I agree, the best bet though would be to aproximate the motion like BKewl said with a cubic spline the ending end would be not a not end condition and the throwing end would be zero slope. The length proportional to how hard its thrown the break proportional to the spin. Then the spline could be rotated to the angle its thrown at. So thats, with L being the length thrown and B being the distance the ball broke:
Y(X)=aX^3+bX^2+cX+d; and Y(0)=0, and Y(L)=B; starts at zero ends at break
with Y'(X)=3aX^2+2bX+c; and Y'(0)=0; start zero slope
with Y''(X)=6aX+2b; and Y''(L)=0; end not a not end contition

you might want to double check but I got:
d=0;
c=0;
b=3B/2L;
a=B/2L^2;

Y(X)=(B/2L^2)X^3+(3B/2L)X^2;
X is between 0 and L; 0<=X<=L;

Love in Christ,
Gift

AmazingJas

Member

Posts: 437
From: Sydney, NSW, AUSTRALIA
Registered: 04-03-2003
Wow! That looks really impressive, might take me a while to understand it (not a math major myself), but I'll give it a go. Thanks.