Physics of Bad Piggies Friction

Physicist Rhett Allain analyzes the frictional forces in BadPiggies.
Image may contain Text Business Card and Paper

Really, this is the experiment I wanted to start on. How does friction work in Bad Piggies? Let me start with a quick summary of my experiments so far.

  • Scale. For the size of stuff in Bad Piggies, I am going to say that the length of a wooden box is 1 meter.
  • Mass. I have a list of some objects with their masses in units of "wb" where 1 wb is the mass of a wooden box.
  • Balloon Force. I have a fairly good value for the force one balloon lifts on a box.
  • Air Resistance. It seems that the sandbags (at least) have some type of air resistance on them as they move.
  • TNT. I have a lower limit on the energy stored in a box of TNT.

Now for more physics.

Real World Friction

Friction is actually a pretty complicated interaction between two materials. However, the friction force can be calculated using a simple model for both static friction (where the two surfaces do not move relative to each other) and kinetic friction (where the surfaces do move).

Twofrictions

For both of these models, N is the normal force. This is the force that one surfaces pushes on the other surface. The warning I always give with this force is that it is NOT always the same magnitude as the gravitational force. What about the coefficients of friction (μ)? With this model, there are some important points regarding the coefficients.

  • In general, the coefficient of static friction is higher than the coefficient of kinetic friction (for the same materials).
  • The coefficient does not depend on surface area.
  • The coefficient does not depend the speed of the object (for kinetic friction).
  • This model can still be used for rolling objects. Although the situation is a bit different, there is still a frictional force in the axle.
  • This is just a model. There are some cases where this model doesn't work.

But what about the less than or equal sign in the static friction model? This is simple. Suppose you push on a block sitting on table with a force of 1 Newton parallel to the table. If this block stays stationary, the static friction force must also be 1 Newton. Now suppose you push a little harder, say 1.5 Newtons but the block still doesn't move. This must mean that the static friction force is now 1.5 Newtons. So the static frictional force exerts whatever force it has to keep the two surfaces from sliding. It does this up to its maximum value. That is why there is a less than or equal sign there.

One other thing for the kinetic friction model. Suppose I have to carts with identical wheels (so identical coefficients of friction). If both carts start rolling with the same speed, but one cart has more mass, how will their accelerations compare? Let me draw a diagram.

Twofbdfrictions

I should have used different labels for these forces on the two different objects, but I didn't. The acceleration in the vertical direction is zero (so the forces in the y-direction must be zero). This along with the forces in the x-direction will let me solve for the acceleration in the x-direction.

Accel Friction

What's the point? The point is that for this case, acceleration of both object would be the same. This is something I can test in Bad Piggies.

Bad Piggies Friction

Now for a simple test. Let me make an object and see how it moves on a flat surface. In this situation, I will use the engine in the vehicle to move up a hill and then roll back down. I can then measure the motion of the car on the flat part of the ground. This is the object I will use.

Friction Bpwoodwheels 1

Why this configuration? Well, first is that it uses the wooden wheels. I want to test the frictional force for the wooden wheels. Second, I mostly know the mass. From my previous investigation, I know that the wooden blocks have a mass of 1 wb (where wb is the mass of 1 wood block). The pig has a mass of 2 wb, the engine is 3/2 wb and the wood wheels also have a mass of 3/2 wb. What about the propeller? After a quick experiment, it seems like it has a mass of 4/5 wb. This would put the total contraption mass at about 9.1 wb.

Now for some data. Here is my first look at the horizontal motion of the cart after going up the hill to the right and then rolling back down to the left.

Anothertryataccelerationfriciton

What can I say about this data? You probably notice that there was some errors from Video Tracker at the end - I didn't bother to fix these. However, this looks like it has a constant acceleration with a value of 1.39 m/s2. But what if the cart starts with a different speed? I can change the starting speed by letting it go higher on the hill before rolling down.

Here is another run with a different starting velocity.

Slowerspeedfriciton

This again looks like a fairly constant acceleration - since a quadratic equation seems to fit quite well. However, the acceleration is a little bit different. This has an acceleration of 1.07 m/s2. For this second friction experiment, the cart started with a speed of about 5.4 m/s. If I go back to the other data run and just look at the data after it slowed down to 5.4 m/s, it gives an acceleration 1.14 m/s2 - much closer to the second run. So, what is going on here? My first guess is that the first run has an error. Why? Well, the background had more motion since the cart was moving faster. This means I had to do more coordinate axis shifts. I guess this could cause the error.

Another possible explanation is that there is some non-constant force on the rolling cart. Maybe there is air resistance. However, it seems from other experiments that there might only be air resistance on the sand bags. I guess I need even more data.

For both of the previous sets of data, I didn't track the cart all the way until it stopped. Why? Because I didn't think ahead, that's why. I had chosen an origin that ends up getting obscured by one of the buttons. Here is the best data I could come up with.

Betteracceldata

With this, the acceleration would be 1.20 m/s2. However, this really shows an important point. Perhaps I need a better (quicker) method for measuring the acceleration. Here is my plan. I will measure the the time it takes the cart to stop along with the distance it takes to stop. From this, I can write down the following definitions for average velocity and acceleration (in just the x-direction).

Avgvfriction

Just to be clear, I am calling t the time it takes to stop from the initial position (x1) and initial velocity (v1). Really, I don't care where it starts or stops - just the distance it travels. Let me call this value s. Now if I take these two equations and eliminate the v1 variable, I get:

Accelefrictiondistancetime

So, I just need the distance (which would would be negative for a car moving to the left) and the time. If I use the same motion from above, s would be -22.70 meters and the time would be 6.233. Putting these values into the acceleration calculation gives a value of 1.17 m/s2. This is close enough for me.

One more note. Remember, this method is easier, but it comes with an assumption. The assumption is that the acceleration is constant. All three of my test runs showed a constant acceleration, so I think this is a safe bet. Now for even more data.

Wait! I have decided to change my plan. After collecting a little bit of data with this method, I see the flaw. The problem is with the time. Usually, I could use this method for a dropping object that starts from rest. However, the ending at rest is a problem. Why? Because it is very hard to pick the exact time that the cart comes to a stop - especially since it is moving very slowly. So, if I accidentally increase or decrease the time by even 0.3 seconds, this could have a big impact on the acceleration since it depends on the time squared.

Another method: How about this? What if I measure the position of the cart for two or three frames and use this to get a starting velocity? Oh sure, the velocity isn't actually constant but it is small enough that this method should give a good estimate for the starting speed. Now, I can eliminate time from my equations above to get:

Anothermethodforaccel

This method only depends on the initial velocity and the distance. The distance will be much easier to measure since I can wait until I am absolutely sure it is stopped. Ok - here is more data with this new method.

Fricaccelhisto 1

The data isn't perfect, but it's what I have. The average of these values is 1.276 m/s2 with a standard deviation of 0.276 m/s2. That value is good enough for now.

Friction and Mass

Now for some more data. Yes, I know this is already more data than I expected. However, what if I change the mass of the car? Will it have the same acceleration as the lower mass? Here is the car I am going to use.

Badpigfrictimmass 1

Since the mass of a metal block is 7/4 wb, this would put the total cart mass at 14.35 wb - not twice the mass, but much more massive than before. Using the same methods as before, I collected some acceleration data.

Compareaccelfriction

I know I didn't collect as much data for the more massive object, but at this point it seems like it has the same acceleration with a value around 1.199 m/s2 and a standard deviation of 0.122 m/s2. Using all this data, let me say that the cart has an acceleration of 1.25 m/s2. From this, I can calculate the coefficient of friction:

Muk 1

Metal Wheels

Now, let me do the same thing, but with different wheels. For this case, I will use the smaller metal wheels that aren't powered.

Metalwheels 1 2

I only ran this one five times, but it seems like the coefficient could be different. Here is a comparison between the accelerations for the wooden wheels and the metal ones.

Metalvswoodwhee

From this, the metal wheeled cart has an average acceleration of 0.942 m/s2 with standard deviation of 0.218 m/s2. The coefficient of friction for these wheels (from this data) is 0.096. I want to say this is different than the value for the wooden wheels - but I should probably collect more data.

How About a Different Experiment?

What if I could come up with a situation that would demonstrate a difference in the coefficients of friction rather than calculating the coefficients and making a comparison? You know this is what I am going to do, right? Here are two contraptions that I will push up a hill and then let them roll down.

Multiplewheelexperiment 3

After the roll back down the hill, I should be able to see a difference in acceleration. If the cart on the left has a lower acceleration, the two objects will separate. If the object on the right has a lower acceleration, the first object will slow down more causing the other object to push up against it. You can run this experiment yourself. The cart with the metal wheels does appear to have a lower acceleration and pull away from the wood-wheeled cart. Here is some data to show that.

Compareaccels

It should be clear that these two have different accelerations. The top set of data is the cart with the wooden wheels with an acceleration of 0.992 m/s2. The bottom set is the cart with the metal wheels. It has an acceleration of 0.74 m/s2. Why are these accelerations so different from my values before? I hate to say this, but it might be the case that the accelerations are not constant (even though I said they were before). Take a look at this plot of the velocity for both of these carts.

Comparevelocityfriction

If the acceleration was constant, both of these velocities would be linear functions. If I had to guess (and apparently, I do) I would say that there are two different frictional coefficients. A coefficient at low speeds and one for higher speeds. It could be that the transition from high to low speed is around 3 m/s. Yes, I am just guessing here. It is also possible there is some non-constant force - something like air resistance.

At this point, I am just not sure. Really, I need a different level with a larger flat stretch. Yes, there must be some level out there that will help with this.

Summary

Let me first point out something important. Why would I look at the frictional forces before looking at other things? Once I have a good model for the frictional force, I can look at other forces. I can look a the fan, the motors, the soda bottles and stuff like that. If I didn't know the frictional force, it would be quite difficult to exactly know how these other forces work.

Here are some other points.

  • Friction mostly seems to work like I would expect in Bad Piggies.
  • The acceleration of an object slowing due to friction does not depend on the mass that object.
  • The coefficient of friction for wooden wheels and for metal wheels appear to be different with the metal wheels having a lower coefficient value.
  • I did another quick test looking at the number of axles on a cart. It doesn't seem to change the frictional force. This agrees with the standard real-world model for friction. Since there are more axles, each axle would have lower normal force - but there are more of them.
  • The coefficient of kinetic friction for rolling wood wheels is about 0.128 and for metal wheels it is 0.096.

Here some other questions and things to do.

  • I would love to find a nice steady incline on some level (not curved). With this inclined plane, I could look at the acceleration of an object for both going up and down the plane. On the way up, the frictional force would be in the same direction as the gravitational force. This would give a larger magnitude of acceleration than when it is going down the incline. From the difference in accelerations (up vs. down), I could get an estimate for the frictional force.
  • With a good frictional model, I could do something cool. I could get a function for the shape of a slope on a particular level. Then I could use a numerical model in python and see if I could reproduce the exact same motion. That would be awesome.
  • Is the coefficient of friction different for ground that looks like dirt or grass?
  • What if you have one wooden wheel and one metal wheel. What would the effective coefficient of friction be? I can tell you from an informal test, it seems that the acceleration of a hybrid wood-metal wheel cart is lower than a pure wooden wheel cart. However, what if the center of mass is not in the center of the cart? This would mean more weight is on one of the wheels - and I think that would make that coefficient more significant than the other one.

It's clear I need some more data on the frictional forces in Bad Piggies. If it was too easy, it wouldn't be fun.