Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions physics/ground_to_ground_projectile_motion.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
*/

#include <cassert> /// for assert()
#define _USE_MATH_DEFINES
#include <cmath> /// for std::pow(), std::sin(), and std::cos()
#include <iostream> /// for IO operations

Expand All @@ -27,11 +28,12 @@ namespace ground_to_ground_projectile_motion {
/**
* @brief Convert radians to degrees
* @param radian Angle in radians
* @param PI The definition of the constant PI
* @returns Angle in degrees
*/
double degrees_to_radians(double radian, double PI = 3.14) {
return (radian * (PI / 180));

double degrees_to_radians(double degrees){
double radians = degrees * (M_PI / 180);
return radians;
}

/**
Expand Down
Loading