Inspiration

We chose to do a space-themed project to cohere with this hackathon's theme. We also wanted to learn more about web-scraping, MATLAB, and devising physics formulas.

What it does

Space Navigate is an application that lets you navigate through the solar system taking into account realistic planetary factors such as mass, diameter, density, gravity, orbital speed, and more. This project combines Python for data scraping along with MATLAB for complex calculations related to orbital dynamics.

How we built it

The application is built using a combination of Python and MATLAB to provide both data gathering and computational functionalities:

  • Web Scraping: We use Python's requests library to scrape real-time data about planetary attributes such as mass, diameter, and orbital speed.
  • Data Transformation: The BeautifulSoup library is used for parsing the scraped HTML data, and it's then transformed into a usable format.
  • Orbital Calculations: MATLAB is used for the heavy computational work, calculating the optimal paths for space travel between planets.
  • Integration with Python: We use Python's subprocess module to call MATLAB scripts and fetch the results for further use in the application.
  • Planet Class: A Python class named Planet holds attributes and methods related to each planet. This makes it easy to manipulate and visualize planetary data.
  • Planetary Visualization: We use CMU Graphics for drawing and animating the planets and other celestial objects in the application.

Challenges we ran into

  • File Importing: We were unsure how to import MATLAB files into Python for calculations.
  • Data Accuracy: Figuring out how to correctly scrape web data through Python posed a challenge.
  • Planetary Scale: Drawing planets to scale was a difficult task as we had to accurately represent the size differences between planets.
  • Rotational Challenges: Properly rotating visual elements like stars required an understanding of graphics and geometry within the graphics framework we used. Overall, each challenge provided us an opportunity to learn and improve the application.

Accomplishments that we're proud of

We're proud of being able to create a full working model of the solar system complete with dual backgrounds (plain and random generation of rotating stars) with a splash screen that introduces the project and starts off the space-vibe which we aimed for. It's also a submittable project which is a first for some of us:)

What we learned

We learned that MATLAB is extremely difficult to work with in Python. We also learned that rotating stars require an individual algorithm (using class) for all stars with a central point for it to feel more like the universe is rotating around a central system (which is what we aimed to go for).

What's next for Space Navigate

We aim to try fully integrating MATLAB into our system as well as trying to expand to other solar systems/the greater universe. We also want to add in a feature which would allow the user to more fully explore the planets which they can visit.

Share this project:

Updates