fix: correct function definitions (swap De Jongs)
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
surtur 2022-06-17 20:41:39 +02:00
parent 8a2d3eb5ee
commit 65d555b4df
Signed by: wanderer
GPG Key ID: 19CE1EC1D9E0486D

@ -23,7 +23,7 @@ func DeJong1st(x []float64) float64 {
var res float64 var res float64
for _, val := range x { for _, val := range x {
res += math.Floor(val) res += math.Pow(val, 2)
} }
return res return res
@ -34,7 +34,7 @@ func DeJong2nd(x []float64) float64 {
var res float64 var res float64
for _, val := range x { for _, val := range x {
res += math.Pow(val, 2) res += math.Floor(val)
} }
return res return res