Skip to content

Commit 07f1319

Browse files
committed
remove warning about implicit data type conversion
1 parent 44130af commit 07f1319

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/simulation/dynamics/gravityEffector/sphericalHarmonicsGravityModel.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace {
2525
// Computes the term (2 - d_l), where d_l is the kronecker delta.
26-
inline double getK(const unsigned int degree)
26+
inline double getK(const size_t degree)
2727
{
2828
return (degree == 0) ? 1.0 : 2.0;
2929
}
@@ -92,7 +92,7 @@ SphericalHarmonicsGravityModel::computeField(const Eigen::Vector3d& position_pla
9292

9393
Eigen::Vector3d
9494
SphericalHarmonicsGravityModel::computeField(const Eigen::Vector3d& position_planetFixed,
95-
unsigned int degree, bool include_zero_degree) const
95+
size_t degree, bool include_zero_degree) const
9696
{
9797
if (degree > this->maxDeg) {
9898
auto errorMsg =

src/simulation/dynamics/gravityEffector/sphericalHarmonicsGravityModel.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ class SphericalHarmonicsGravityModel : public GravityModel {
6969
* If include_zero_degree is false the degree that corresponds to the spherical
7070
* term (point-mass) of the gravity is ignored.
7171
*/
72-
Eigen::Vector3d computeField(const Eigen::Vector3d& position_planetFixed, unsigned int degree,
72+
Eigen::Vector3d computeField(const Eigen::Vector3d& position_planetFixed, size_t degree,
7373
bool include_zero_degree) const;
7474

7575
/** Returns the gravitational potential energy at a position around this body.

0 commit comments

Comments
 (0)