Inspiration

In physics, we just finished talking about shear forces and we thought a calculator for this would be cool.

What it does

This program has several inputs, force, length of bar, width of bar, and shape of the bar. It uses these inputs and calculates the sheer, compressive and tensile force on the bar. The program takes the material and determines if the bar takes the stress, deforms, or breaks. The user may add their own custom material as well, and they are saved to a file called Mat.txt that is part of the program. The initial materials are steel, brass, copper, and concrete.

How we built it

We used inheritance to create our bars, and ropes. We had an item which Bar and rope are sub classes of. Circle and N_gon are sub classes of Bar. There are MaterialProperties which were used for the type of material being used. Then there are two Javafx classes, one for the material properties addition and launch, and another for the simulation. We had a class for fileI/O that handled getting the material properties into the program. We used UML diagrams to show all of this before actually programing anything.

Challenges we ran into

The main challenges we had were learning how to use Javafx and making the GUI look good.

Accomplishments that we're proud of

It worked with relatively few issues which never happens when programing. The GUI looks good, the program saves to a file and can full information from a previous run of the program.

What we learned

We learned how to do Javafx better and learned file I/O and saving data from a previous run and using in a later run.

What's next for Material Stress Calculator

Refining methods, and adding more options and making the GUI look nicer. One option that can be added is adding a temperature field.

Built With

Share this project:

Updates