MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / log10

Method log10

tools/python-3.11.9-amd64/Lib/_pydecimal.py:4698–4724  ·  view source on GitHub ↗

Returns the base 10 logarithm of the operand. >>> c = ExtendedContext.copy() >>> c.Emin = -999 >>> c.Emax = 999 >>> c.log10(Decimal('0')) Decimal('-Infinity') >>> c.log10(Decimal('0.001')) Decimal('-3') >>> c.log10(Decimal('1.

(self, a)

Source from the content-addressed store, hash-verified

4696 return a.ln(context=self)
4697
4698 def log10(self, a):
4699 """Returns the base 10 logarithm of the operand.
4700
4701 >>> c = ExtendedContext.copy()
4702 >>> c.Emin = -999
4703 >>> c.Emax = 999
4704 >>> c.log10(Decimal('0'))
4705 Decimal('-Infinity')
4706 >>> c.log10(Decimal('0.001'))
4707 Decimal('-3')
4708 >>> c.log10(Decimal('1.000'))
4709 Decimal('0')
4710 >>> c.log10(Decimal('2'))
4711 Decimal('0.301029996')
4712 >>> c.log10(Decimal('10'))
4713 Decimal('1')
4714 >>> c.log10(Decimal('70'))
4715 Decimal('1.84509804')
4716 >>> c.log10(Decimal('+Infinity'))
4717 Decimal('Infinity')
4718 >>> c.log10(0)
4719 Decimal('-Infinity')
4720 >>> c.log10(1)
4721 Decimal('0')
4722 """
4723 a = _convert_other(a, raiseit=True)
4724 return a.log10(context=self)
4725
4726 def logb(self, a):
4727 """ Returns the exponent of the magnitude of the operand's MSD.

Callers

nothing calls this directly

Calls 2

_convert_otherFunction · 0.85
log10Method · 0.45

Tested by

no test coverage detected