[C #] study notes (1): Science Math class of computing

With Math some simple scientific computing classes, including the power logarithmic, exponential, logarithmic or the like is calculated

Namespace using System

m Double, n-; 
m = Math.exp (0.5); // e is the natural logarithm of the power of 0.5 
n = Math.Exp (30); // natural number e 30th power of 
n = Math.Log (3 ); // base e, of the number of 3 
n = Math.Log (125, 5) ; // 5 is a bottom, the number of 125 
n = Math.Log10 (1000); // base 10 , 1000 logarithmic 
n = Math.Pow (8, 2.5) ; // 8 -th power of 2.5 

n = Math.pow (10, -1) ; // 10de -1 th 
n = 1.34e-3; / / scientific notation represented by the numeral

Math official description class: https://docs.microsoft.com/zh-cn/dotnet/api/system.math?view=netframework-4.7.2

Guess you like

Origin www.cnblogs.com/RicardoIsLearning/p/12111327.html