C#Ln到Mathf.Log

时间:2012-07-07 15:35:54

标签: c# math

您将如何在C#中编写此函数?

enter image description here

我知道这与Mathf.Log有关,但我的数学有点生疏。任何帮助都会很棒。

1 个答案:

答案 0 :(得分:4)

Mathf看起来像是Unity。除非您使用Unity,否则您可能需要:

double x = 1 + (Math.log(v -s) / (10 * Math.log(2)));