Skip to content

SwiftfoxStudios/drivetrain

Repository files navigation

Project Overview

Project Drivetrain (Computer Science NEA)

Made in

INTRODUCTION TO THE PROBLEM

Drivetrain is an all-in-one fitness tracker, with features such as advanced routine management, social engagement, route tracking and generation and stats management. It is the answer to the modern issue of the lack of free, open-source fitness apps, and the increasingly common business model of apps having some or all features hidden behind paywalls.

The objective of this project is to provide an enjoyable experience of fitness via the means of a powerful and robust mobile app, accessible to all. The value of an accessible fitness app is immeasurable in today's society - a place where obesity rates are on average just under 30% in the UK. Helping tackle obesity, not only nationally, but globally - and keeping the world fit - should be a priority this year, especially after the globe heals itself from the coronavirus pandemic. The best way to get people out on their feet or bike is to make it as easy as possible to do so. Having an enjoyable and free experience will help them continue the cycle of keeping fit.

Not to mention that the NHS, alongside many global health studies and institutions, have explicitly stated the importance of regular exercise. It can reduce your risk of heart disease, stroke, type 2 diabetes and cancer by up to 50% and lower your risk of early death by up to 30%. Not to mention that exercise can also boost your self-esteem, mood, sleep quality and energy, as well as reducing your risk of stress and depression.

EXAMPLE ALGORITHMS IN USE

HAVERSINE FORMULA

The below algorithm calculates the latitude and longitude of a destination point, given the distance and bearing from the start point. It uses a reverse implementation of the Haversine Formula.

The Haversine Formula states

Such that: for _ d _, the distance between two points on a sphere with radius _ r _.

As such, the latitude, φ and longitude, λ of the second point can be given as:

POWER OUTPUT FORMULA

Estimating how much effort a user outputs is extremely important for those training without pricey equipment, and is a fundamental part of getting better and fitter on the bike. The rider's output forces experience several reaction forces, as the diagram below demonstrates. As such, we can work out the power required to overcome the sum of the resistive forces based on the final velocity. As shown below.

All formulae are commented alongside for clarity.

SQL INSERTION

SQL is the database of choice for this project - more details are shown later, but here is how the insertion itself works.

A key point to note here is that an Activity Object is created from a class which is added here. The object is created after an activity is saved/added.

XML PARSING

This function is used for importing previous activities through the .gpx standard, a form of XML. It parses the data from a file into the ActivityObject as shown above, then inserted into the database.

Evidence of code running (could be link to a video of a screen record, screenshots etc.)

Evaluation (Where did you get up to? What were the main problems/challenges? What about your own performance?)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages