[AV-330] implement simple parachute simulation#23
Conversation
…https://github.com/ISSUIUC/ISS_SILSIM into feature/AV-330-implement-simple-parachute-simulation
…https://github.com/ISSUIUC/ISS_SILSIM into feature/AV-330-implement-simple-parachute-simulation
NPIPHI
left a comment
There was a problem hiding this comment.
Core logic and graphs look good. I think organizationally most of the parachute logic should be moved to rocket.cpp or into a class called Parachute.
Physics engine is also only setup for a rocket flying straight through the air, so there needs to be some modifications past just increasing the coefficient of drag. I would extract the component of forwardeuler that calculates drag forces into a member function of rocket, then that function on rocket could decide how to calculate drag based on parachute status.
|
|
||
| // simulation completion criteria | ||
| if ((r_dot.z() < -3.0) && !drogue_deploy) { | ||
| std::cout << "Drogue: " << std::to_string(tStamp_) << " s" |
There was a problem hiding this comment.
This info should be logged with the sim_log->info function, see the logging near the bottom of the function for how it works
AyberkY
left a comment
There was a problem hiding this comment.
I feel that the current approach of just increasing CD isn't quite right. You can see in the plots that it does some weird stuff soon after apogee. It also starts spinning uncontrollably which is fun to watch in the animation lol.
I think a better approach would be to have a march_step_descent() function that just treats the rocket as a point mass during the descent phase. The Simulation class would then decide to switch between _ascent() and _descent(). At this point, we could just freeze the rockets orientation and treat the physics as a point mass with a parachute.
|
I think creating ascent/descent functions is a good idea. I think I'll incorporate Nick's changes and then create a new ticket to tackle that issue |
|
Still a WIP, I moved most logic into a new parachute class and the rocket class, some changes need to be made to runge-kutta to properly change the physics at different differentiation points |

Basic parachute simulations. Some issues rebasing from Eigen commit so some changes are carried over from those commits. Verified with differing altitudes and parachute areas. Works good for now.