Create a single Processing program that fulfills the two requirements below. Write a Processing program to calculate the pulling force of the Heisler locomotive in terms of oxen.

Processing Program

INSTRUCTIONS BELOW AND USE THIS SITE TO COMPLETE ASSIGNMENT:

https://appinventor.mit.edu/explore/ai2/molemash

In this lab, we continue to practice with the different parts of a programming language. Specifically, we will look at variables, data types, and calculations. This lab will be done in two parts.

Objective

Create a single Processing program that fulfills the two requirements below.

For each part, you must use variables wherever possible, and format your console output so it is easy to read and understand. No draw( ) function will be required for this program, though you’re allowed to produce the results of your work however you want.

Part 1: Locomotives and Oxen

Using rough estimation, assume that a typical ox weighs around 2000 lbs and can produce a pulling force 2.5 to 3 times its weight. For the case of this lab, this gives us a figure of around 6000 lbs of pulling force per ox.

In many cases, multiple oxen are used to pull a single wagon.

Geared steam locomotives (such as the Heisler in Locomotive Park here in Lewiston) can pull up to the friction limit of their wheels. Geared steam locomotives have a drive shaft running the length of the machine, providing all-wheel drive. Because steel wheels have poor traction on steel rails, the maximum force of a geared steam locomotive is around only 30% of its weight. A Heisler locomotive would weigh approximately 90 tons.

Write a Processing program to calculate the pulling force of the Heisler locomotive in terms of oxen. The output of your program should be something like “The Heisler locomotive has the pulling force of X oxen!”

Remember that you must use variables in your app. Something like this would be appropriate:

int heisler_weight = 90; // weight in tons

Part 2: Bulldozers

Unlike locomotives, bulldozers have excellent traction! The exact amount of traction depends on the surface on which the bulldozer is sitting, so we’ll have to estimate. According to various non-authoritative sources on bulldozer forum posts, we will estimate that a bulldozer can pull approximately 175% of its weight.

Add onto Part 1 of this lab and calculate the pulling force for three bulldozers in terms of oxen. Use the following three bulldozers:

– Caterpillar D5

– Caterpillar D11

– Komatsu D575A (the world’s largest bulldozer)

Similar to Part 1, the output of your program should be something like “The Caterpillar D5 has the pulling force of X oxen!”

Create a single Processing program that fulfills the two requirements below. Write a Processing program to calculate the pulling force of the Heisler locomotive in terms of oxen.
Scroll to top