Python math.log1p() နည်းလမ်း
ဥပမာ
မတူညီသောနံပါတ်များအတွက် မှတ်တမ်း(1+နံပါတ်) ကိုရှာပါ။
# Import math Library
import math
# Return the log(1+number) for different numbers
print(math.log1p(2.7183))
print(math.log1p(2))
print(math.log1p(1))
အဓိပ္ပါယ်နှင့် အသုံးပြုမှု
နံပါတ် ၏ math.log1p()
တန်ဖိုးသည် သုညနှင့်နီးစပ်သည့်တိုင် တိကျမှန်ကန်သောနည်းဖြင့် တွက်ချက်ထားသော log(1+number) ကို ပြန်ပေးသည်။
အထားအသို
math.log1p(x)
ကန့်သတ်တန်ဖိုးများ
Parameter | Description |
---|---|
x | Required. Specifies the number to process. If the value is a negative number, it returns a ValueError. If the value is not a number, it returns a TypeError |
နည်းပညာဆိုင်ရာအသေးစိတ်
ပြန်ပို့တန်ဖိုး- | 1+ နံပါတ် ၏ float မှတ်တမ်းတန်ဖိုးကို ကိုယ်စားပြုသော တန်ဖိုး |
---|---|
Python ဗားရှင်း- | ၂.၆ |