{"id":21873974,"url":"https://github.com/forentfraps/rocket-flight-simulation","last_synced_at":"2026-04-29T16:38:58.412Z","repository":{"id":116173059,"uuid":"472978416","full_name":"forentfraps/rocket-flight-simulation","owner":"forentfraps","description":"Made a graphical for rocket flying considering non-constant mass and air friction, turned out to look pretty cool","archived":false,"fork":false,"pushed_at":"2022-03-24T18:28:50.000Z","size":37,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-26T17:37:17.019Z","etag":null,"topics":["physics","physics-3d","python","rocket","science","scipy"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/forentfraps.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2022-03-23T00:07:48.000Z","updated_at":"2022-03-24T05:10:49.000Z","dependencies_parsed_at":null,"dependency_job_id":"32fa5879-fd78-4924-9937-201b8981844b","html_url":"https://github.com/forentfraps/rocket-flight-simulation","commit_stats":{"total_commits":21,"total_committers":1,"mean_commits":21.0,"dds":0.0,"last_synced_commit":"0f364a5aa21f7afea0757c6a743232e2ae5c5c83"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/forentfraps%2Frocket-flight-simulation","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/forentfraps%2Frocket-flight-simulation/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/forentfraps%2Frocket-flight-simulation/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/forentfraps%2Frocket-flight-simulation/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/forentfraps","download_url":"https://codeload.github.com/forentfraps/rocket-flight-simulation/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244880661,"owners_count":20525515,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["physics","physics-3d","python","rocket","science","scipy"],"created_at":"2024-11-28T07:10:07.956Z","updated_at":"2026-04-29T16:38:58.361Z","avatar_url":"https://github.com/forentfraps.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# rocket-flight-simulation\nMade a graphical demonstration for rocket flying, considering non-constant mass and air friction, turned out to look pretty cool\n\n# Theory\n\nFor such tasks involving non-constant mass I will be using the *mesherskiy equation*\n\n![image](https://user-images.githubusercontent.com/29946764/159786382-89347625-0936-4b18-a36b-2535b704c116.png)\n\n\n\"F..\" means external forces, such as air friction and gravitation pull\n\n![image](https://user-images.githubusercontent.com/29946764/159786537-a4ddaf49-6d77-4fe7-829b-653450884776.png)\n\n\nOur rocket will have 2 phases:\n\n    - With fuel, meaning differing mass, drag from the fuel exhaustion\n    \n    - Without fuel, constant mass, basically only air friction\n    \n\nAfter all those preparations we can finally make out final equations \n\n![image](https://user-images.githubusercontent.com/29946764/159787344-d4862e19-aa21-4866-9273-aad2ae614628.png)\n\nAfter expanding it into a 3 equation system it turnes out to be non-linear differential equations, which i am not going to solve analytically\nHowever we can try them out with some test data, to later reffer to this as an expected result \n*Note:* I will be doing x/y reffering to horizontal/vertical plane, however in the code x\\y is horizontal and z in vertical\n\n**PART 1**\n\n![image](https://user-images.githubusercontent.com/29946764/159787772-13656a7d-63ef-4c58-8041-154328aa14b2.png)\n\n**PART 2**\n\n![image](https://user-images.githubusercontent.com/29946764/159787825-f77bca53-4a7e-40ee-b223-f7a30b3927e2.png)\n\n# Testing Theory\n\n *Im using this input to plot my data manually:  plot_me(\"red\", a =math.pi/4 , b = math.pi/2.38,fcons =700,fsp = 23000 , v =10)*\n\nit has a very horizontal trajectory, much like a real rocket\n\nx1[t]\n\n![image](https://user-images.githubusercontent.com/29946764/159794622-5e3ff90f-abbd-47d4-ab7b-04604f6426ac.png)\n\nv1x[t]\n\n![image](https://user-images.githubusercontent.com/29946764/159794643-bc681ee0-d33f-4c6f-8bb6-1f7b62d77fed.png)\n\nx2[t] \n\n![image](https://user-images.githubusercontent.com/29946764/159795036-11b726c7-1013-4922-964d-61236d580939.png)\n\nv2x[t]\n\n![image](https://user-images.githubusercontent.com/29946764/159795114-78751a53-fe6c-459f-8bb4-3de2fadc9a6f.png)\n\n\nz1[t]\n\n![image](https://user-images.githubusercontent.com/29946764/159795316-5335928c-5ed7-4cb9-85f8-4670d94d3754.png)\n\nvz1[t]\n\n![image](https://user-images.githubusercontent.com/29946764/159795378-edc5ce5c-5030-4817-ab1b-ad808609d8ee.png)\n\nz2[t]\n\n![image](https://user-images.githubusercontent.com/29946764/159795497-aed208c9-38bc-4fe8-9b3a-0567b1f49735.png)\n\n\nvz2[t]\n\n![image](https://user-images.githubusercontent.com/29946764/159795547-b6a28c1f-832c-43b4-a5ea-ed078f1fd79e.png)\n\n\n\nCompairing theory and my data, it seems as it is quite similar, which concludes as a success\n\nI will include some actual plots, which my code can perform:\n\n![image](https://user-images.githubusercontent.com/29946764/159795999-c855bf89-531d-428a-8620-2f01a1fa7ff9.png)\n\n![image](https://user-images.githubusercontent.com/29946764/159796041-72b2fb05-cb51-4af1-b0d1-dcd5133473e4.png)\n\n![image](https://user-images.githubusercontent.com/29946764/159796063-31bc7175-3edc-4dc2-b634-178dc3d18a64.png)\n\n\n\n**Note:** after a closer look at the code, you could see that wind is indeed in the equation, HOWEVER, it shows wierd results, so it is better left at 0\n\n![image](https://user-images.githubusercontent.com/29946764/159796282-fdc13cd5-4328-49d1-90fe-07a695a201ad.png)\n\n![image](https://user-images.githubusercontent.com/29946764/159796292-3384fd79-4953-4b55-a57d-be8547a3969d.png)\n\n\n**TODO:**\n    \n    -Make dynamic graphs, add easy support for x/y/z[t]  as shown above (were done in a janky way)\n    \n    -Fix the wind\n\nHUGE THANKS TO Chelovechecheggg#5451 for helping\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fforentfraps%2Frocket-flight-simulation","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fforentfraps%2Frocket-flight-simulation","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fforentfraps%2Frocket-flight-simulation/lists"}