2019 THE UNIVERSITY OF DANANG DANANG UNIVERSITY OF SCIENCE AND TECHNOLOGY FACULTY OF INFORMATION TECHNOLOGY PROJECT’S NAME: BUILDING A FITNESS PERSONAL TRAINER APPLICATION GRADUATION PROJECT THESIS MAJOR: INFORMATION TECHNOLOGY SPECIALTY: INFORMATION SECURITY PROJECT TITLE: BUILDING A FITNESS PERSONAL TRAINER APPLICATION Instructor: M. PHAN THANH TAO Student: NGO MINH CUONG Student ID: 102150087 Class: 15T2 Ngo Minh Cuong Da Nang, 12/2019 THE UNIVERSITY OF DANANG DANANG UNIVERSITY OF SCIENCE AND TECHNOLOGY FACULTY OF INFORMATION TECHNOLOGY GRADUATION PROJECT THESIS MAJOR: INFORMATION TECHNOLOGY SPECIALTY: INFORMATION SECURITY PROJECT TITLE: BUILDING A FITNESS PERSONAL TRAINER APPLICATION Instructor: M. PHAN THANH TAO Student: NGO MINH CUONG Student ID: 102150087 Class: 15T2 Da Nang, 12/2019 INSTRUCTOR’S COMMENTS. SUMMARY Project’s name: Building a fitness personal trainer application Student name: Ngo Minh Cuong Student ID: 102150087 Class: 15T2 This project aims to create a mobile application helping users to create workout plan and nutrition plan based on their goal.
Initially, users need to determine their specific fitness goal such as weight loss, muscle gain and some requirement criterion like time for workout every week and every day, time to achieve the goal, daily activity level … The system acquires those information to generate an appropriate workout schedule with a collection of exercises to practice every day, every week during the time of plan. Besides that, users also have a daily nutrition plan specify amount of calories/protein/carbs/fat need to gain. Users just practice and eat following the plan. Periodically, they input their current masses such as weight, forearms circumference and the system generate statistic of how well they improve.
In this project, I’ve already had the application with necessary features to help users create and follow fitness plan. I’ve also done on generalizing essential knowledge of fitness term to make an effective generating algorithm. The application for users was created with React Native and the API was created by using Django framework based on Python programming language. Besides that, I used PostgreSQL to store all the data and deploy the system to Heroku.
DA NANG UNIVERSITY THE SOCIALIST REPUBLIC OF VIETNAM UNIVERSITY OF SICIENCE AND Independence - Freedom - Happiness TECHNOLOGY FALCUTY OF INFORMATION TECHNOLOGY GRADUATION PROJECT REQUIREMENTS Student Name: Ngo Minh Cuong Student ID: 102150087 Class: 15T2 Faculty: Information Technology Major: Information Technology 1. Topic title: Building a fitness personal trainer application 2. Project topic: ☐has signed intellectual property agreement for final result 3. Initial figure and data: All the figure and data were gathered on the internet from trusted resources Content of the explanations and calculations: - Conceptions of fitness term - Workout schedule and nutrition plan for users 4.
Drawings, charts (specify the types and sizes of drawings): - User case diagram - Class diagram - Sequence diagram - Activity diagram - Package diagram 5. Name of instructor: Content parts: M. Phan Thanh Tao 6. Date of assignment : 07/09/2019 7.
Date of completion : 20/12/2019 Da Nang, date month year 2019 Head of Division…………………. Instructor ACKNOWLEDGMENTS First of all, I would like to spend my honest appreciation to my instructor, M. Phan Thanh Tao for his continuous support, supervision and guidance through the tenure of my project. His wisdom and experience gave me the understanding on determining the idea, designing the system and handling researching.
In addition, I would like to thank mentors from Enclave company for their valuable guidance. During the progress, they always gave helpful advice and resource to make my project better and better. I also thank to my colleagues at Enclave company for their supportive advice. Specially, thanks to my family and my friends for always be with me and give enthusiasm and motivation to keep my on my way.
I also would like to thank all teachers at Da Nang University of Science and Technology for their continuous contribution for education. During four years at university, I was taught a lot, they imparted us knowledge, taught us to do the right thing. Without the generous help from all of them, my senior project wouldn’t have been successful. Sincerely, Ngo Minh Cuong GUARANTEE I guarantee: 1.
The whole project was made on my own following the instruction of M.S Phan Thanh Tao. Every information was from trusted resource and was verify about the reliability. I take full responsibility for my project. Student Performed, Ngo Minh Cuong i CONTENT SUMMARY.
ii LIST OF TABLES. iv LIST OF FIGURES. vi LIST OF ABBREVIATIONS. Tools and environment development.
2 Chapter 1 : THEORIES AND TECHNOLOGIES. The six principles of REST. Django and Django REST framework. Django REST framework.
React Native & Redux. 11 ii Chapter 2 : ANALYSIS AND DESIGN. Use case diagram. Description for the main use-case.
50 Chapter 3 : IMPLEMENTATION AND RESULT EVALUATION. Demo system’s main features. 62 iii LIST OF TABLES Table 2.1: User case description – Administrator – Login .2: User case description – Administrator – Manage sample data .3: User case description – Administrator – Create sample data .4: User case description – Administrator – Update sample data .5: User case description – Administrator – Delete sample data .6: User case description – Administrator – Create user account .7: User case description – Administrator – Delete user account .8: User case description – User – Register account .9: User case description – User – Login .10: User case description – User – Input initial information .11: User case description – User – Consult recommend workout plan .12: User case description – User – Consult sample workout plan.13: User case description – User – Consult sample execises .14: User case description – User – Examine statistic .15: User case description – User – Create food .16: User case description – User – Modify food .17: User case description – User – Delete food .18: User case description – User – Add daily diet record .19: User case description – User – Update daily diet record .20: User case description – User – Remove food from daily diet record30 Table 2.21: User case description – User – Clear daily diet record .22: Description of table – User .23: Description of table – FitnessMass .24: Description of table – Activity level .25: Description of table – FitnessLevel .26: Description of table – FitnessGoal.27: Description of table – Plan.28: Description of table – DaySequence .29: Description of table – ExerciseSequence.30: Description of table – Exercise .31: Description of table – DateRecord.32: Description of table – Meal .33: Description of table – Meal Record .34: Description of table – Food. 49 v LIST OF FIGURES Figure 1.1: Django architecture overview .2: Example of using Django Rest framework with React overview .3: React Native architecture overview .5: Basic PostgreSQL architecture.2: Use case diagram for Administrator.3: User case diagram for Users.4: Activity diagram – Administrator – Login .5: Activity diagram – Administrator – Manage sample data .6: Activity diagram – Administrator – Create sample data .7: Activity diagram – Administrator – Update sample data .8: Activity diagram – Administrator – Delete sample data .9: Activity diagram – Administrator – Create account .10: Activity diagram – Administrator – Delete account .11: Activity diagram – Users – Register account .12: Activity diagram – Users – Login .13: Activity diagram – User – Input initial information .14: Activity diagram – Users – Consult workout data .15: Activity diagram – Users – Statistic .16: Activity diagram – Users – Create personal food .17: Activity diagram – Users – Modify personal food .18: Activity diagram – Users – Delete personal food .19: Activity diagram – Users – Add food to daily diet record .20: Activity diagram – Users – Update food of daily diet record .21: Activity diagram – Users – Remove food from daily diet record .22: Activity diagram – Users – Clear daily diet record .24: Sequence diagram – Login .25: Sequence diagram – Administrator – Create sample data.26: Sequence diagram – Users – Register account.27: Sequence diagram – Users – Input initial information .28: Sequence diagram – Users – Practice exercises .29: Sequence diagram – Users – Add food to daily diet record .31: Relationship between tables .1: Response from API – GET method.2: Response from API – POST method.3: Response from API – PUT method .4: Response from API – DELETE method .5: Result – Input initial information .6: Result – Workout plan.7: Result – Days sequence of each plan .8: Result – Detail information of each plan day .9: Result – Practice feature .10: Result – Library of exercises .11: Result – Detail of each exercise .12: Result – Daily nutrition information .13: Result – Daily eaten food record.
59 vii LIST OF ABBREVIATIONS No Items Description 1 API Application Programming Interface 2 HTML Hypertext Markup Language 3 HTTP Hypertext Transfer Protocol 4 REST Representational State Transfer 5 UX/UI User Experience/User Interface viii Building a Fitness Personal Trainer Application INTRODUCTION 1. Context Nowadays, the growth and development of the knowledge economy lead to the transference from manual-working into intellectual-working. That means people use grey matter to work and have a sedentary lifestyle. People were carried in the moving of life, they become too busy to care about their fitness.
According to the researching from “Global Emotions Report”, there were third of people from 143 countries said they experienced “a lot of stress” on their life, most of them are intellectual worker. This state comes from being unhealthy because most of them don’t have time to create a fitness plan. There is no time for them for gym center or self-researching about how to build a suitable fitness plan. Cause of those problems I decided to come up with the project “Build a fitness personal trainer application”.
Purpose This system aims to help users create a fitness plan which is appropriate for them. The users just need to input the initial requirement criterion, the system would generate a plan based on that. The plan contains a workout schedule and daily nutrition plan, users practice and eat follow it to achieve their goal. With each plan, users will get a schedule of what exercises they need to practice and how long/ how often to do it.
All the exercises of the system don’t need equipment thus users can practice at home or at their office. Besides practicing, users also need to follow the nutrition plan for the best result. Different from usual diet, nutrition plan for a specific goal is harder, it called clean-eating. It’s totally follow the science so that users can apply it for their daily meal even they plan is over.
Users need to determine the specific time to get their goal, how often they can spend for workout and some more criteria. Then the plan will be customized to suit them. During the goal time, users just follow the plan, practice following the schedule and adjust their meal to fit the nutrition plan. They are able to control their progress by regularly update their current body mass, combine with the statistic of the system they will see how well they changed.
Ngo Minh Cuong – 15T2 1 Building a Fitness Personal Trainer Application Meanwhile, I built this system not for everyone. People who don’t care much about their fitness and don’t afford to follow the heavy fitness plan shouldn’t use this system. Technologies - Django and Django REST framework - React Native & Redux - PostgreSQL - REST API 2. Tools and environment development - Microsoft Visual Studio Code - Android Studio Emulator - Postman - Google chrome 3.
Thesis structure INTRODUCION – This chapter gives information about context and purpose of the project as well as technologies were used in the project. Chapter 1: THEORIES AND TECHNOLOGIES – This chapter introduces all technologies and knowledge theories were used in the project. Chapter 2: ANALYSIS AND DESIGN – This chapter contains the main features, software requirement specifications and database design of the project.