浏览代码

fix parameter for atan2 in procedure asin

Yeongju Kang 3 年之前
父节点
当前提交
4e8bc0786d
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      core/math/math.odin

+ 1 - 1
core/math/math.odin

@@ -1357,7 +1357,7 @@ atan :: proc "contextless" (x: $T) -> T where intrinsics.type_is_float(T) {
 }
 }
 
 
 asin :: proc "contextless" (x: $T) -> T where intrinsics.type_is_float(T) {
 asin :: proc "contextless" (x: $T) -> T where intrinsics.type_is_float(T) {
-	return atan2(x, 1 + sqrt(1 - x*x))
+	return atan2(x, sqrt(1 - x*x))
 }
 }
 
 
 acos :: proc "contextless" (x: $T) -> T where intrinsics.type_is_float(T) {
 acos :: proc "contextless" (x: $T) -> T where intrinsics.type_is_float(T) {