这是一个float型的常数

>>> cmath.e

2.718281828459045

>>> type(cmath.e)

文档

>>> import cmath

>>> help(cmath)

Help on module cmath:

NAME

cmath

FILE

/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/cmath.so

MODULE DOCS

http://docs.python.org/library/cmath Go

DESCRIPTION

This module is always available. It provides access to mathematical

functions for complex numbers.

FUNCTIONS

acos(...)

acos(x)

Return the arc cosine of x.

acosh(...)

acosh(x)

Return the inverse hyperbolic cosine of x.

asin(...)

asin(x)

Return the arc sine of x.

asinh(...)

asinh(x)

Return the inverse hyperbolic sine of x.

atan(...)

atan(x)

Return the arc tangent of x.

atanh(...)

atanh(x)

Return the inverse hyperbolic tangent of x.

cos(...)

cos(x)

Return the cosine of x.

cosh(...)

cosh(x)

Return the hyperbolic cosine of x.

exp(...)

exp(x)

Return the exponential value e**x.

isinf(...)

isinf(z) -> bool

Checks if the real or imaginary part of z is infinite.

isnan(...)

isnan(z) -> bool

Checks if the real or imaginary part of z not a number (NaN)

log(...)

log(x[, base]) -> the logarithm of x to the given base.

If the base not specified, returns the natural logarithm (base e) of x.

log10(...)

log10(x)

Return the base-10 logarithm of x.

phase(...)

phase(z) -> float

Return argument, also known as the phase angle, of a complex.

polar(...)

polar(z) -> r: float, phi: float

Convert a complex from rectangular coordinates to polar coordinates. r is

the distance from 0 and phi the phase angle.

rect(...)

rect(r, phi) -> z: complex

Convert from polar coordinates to rectangular coordinates.

sin(...)

sin(x)

Return the sine of x.

sinh(...)

sinh(x)

Return the hyperbolic sine of x.

sqrt(...)

sqrt(x)

Return the square root of x.

tan(...)

tan(x)

Return the tangent of x.

tanh(...)

tanh(x)

Return the hyperbolic tangent of x.

DATA

e = 2.718281828459045

pi = 3.141592653589793

>>>

python cmath模块_cmath模块-PYTHON相关推荐

  1. Python 3.x标准模块库目录

    文本 1. string:通用字符串操作 2. re:正则表达式操作 3. difflib:差异计算工具 4. textwrap:文本填充 5. unicodedata:Unicode字符数据库 6. ...

  2. math库是python语言的数学模块_Python 数学模块(Math)

    Python 数学模块(Math) 了解Python中可用的所有数学函数以及如何在程序中使用它们. Python中的数学模块是什么? math 模块是Python中的标准模块,并且始终可用.要在此模块 ...

  3. math库是python语言的数学模块_Python入门-函数库(模块)

    内建函数和异常 定义内建函数(例如 len,int, range ...)的 _ _builtin_ _ 模块, 以及定义所有内建异常的 exceptions模块. Python 在启动时导入这两个模 ...

  4. Python标准库——collections模块的Counter类

    更多16 最近在看一本名叫<Python Algorithm: Mastering Basic Algorithms in the Python Language>的书,刚好看到提到这个C ...

  5. Python中的pickle模块

    链客,专为开发者而生,有问必答! 此文章来自区块链技术社区,未经允许拒绝转载. Pickle模块的作用 Pickle模块用于将python对象序列化为字节流,可存储在文件或数据库中,也可同通过网络进行 ...

  6. Python培训教程分享:Python模块如何导入__all__属性?

    本期小编为大家带来的Python培训教程是关于"Python模块如何导入__all__属性?"的内容,后面在工作中是会遇到Python模块这个工作内容的,Python模块的开头通常 ...

  7. Python实战之logging模块使用详解

    用Python写代码的时候,在想看的地方写个print xx 就能在控制台上显示打印信息,这样子就能知道它是什么了,但是当我需要看大量的地方或者在一个文件中查看的时候,这时候print就不大方便了,所 ...

  8. 刻意练习:Python基础 -- Task13. datetime模块详解

    datetime模块 datetime 是 Python 中处理日期的标准模块,它提供了 4 种对日期和时间进行处理的类:datetime.date.time 和 timedelta. datetim ...

  9. 【廖雪峰python进阶笔记】模块

    1. 导入模块 要使用一个模块,我们必须首先导入该模块.Python使用import语句导入一个模块.例如,导入系统自带的模块 math: import math 你可以认为math就是一个指向已导入 ...

最新文章

  1. 关于《Android应用开发揭秘》中早期版本中联系人例子错误的解决办法
  2. Matlab绘制不同阻尼下的系统响应
  3. Spring IOC容器分析(1) -- BeanFactory
  4. 面试高频问题:HashMap实现原理
  5. php设计模式之责任链模式
  6. 自旋锁spin : spin_lock_irq , spin_lock_irqsave
  7. 第一篇SCI (IF5),心得交流(写的字数很多),希望多多交流!
  8. 职称计算机 将计算机broad_1下的e盘映射为k盘网络驱动器,职称计算机考试网络基础答案(1)...
  9. hbase与hadoop版本兼容问题,强烈谴责hadoop生态圈耦合性
  10. 黑色星期五c语言程序,黑色星期五C语言实现
  11. 轻松实现iMessage群发
  12. 小程序 rich-text 修改图片和文字样式
  13. 俄国防部组建信息作战部队 应对西方网络-心理攻击
  14. 福建农林大学计算机与信息学院宿舍,2021福建农林大学宿舍条件和新生宿舍图片及分配规则分享...
  15. 双出口NAT+PBR+IPSec V*N
  16. 已创建了一个包含学生学号、身高、性别的学生身高信息表并输出到屏幕,学生信息从records.txt文件读取。 编写一个函数 void reverse(Seqlist *lp); 功能是对已建立的学生身
  17. Java中Could not find the main class.program will的解决方法(转)
  18. 向日葵链接失败的解决办法
  19. 什么是Mocking framework?它有什么用?(转)
  20. 程序员如何解决面试难题?你可知道你的缺点是什么?

热门文章

  1. 软件测试不是一个功能
  2. 音视频编解码的一些源代码
  3. Java中十六进制转换 Integer.toHexString()
  4. Equation漏洞混淆利用分析总结(下)
  5. 获取BGR颜色的HSV值
  6. Rotate String
  7. windows phone 页面主题设计
  8. 如何阅读3,500万个博客?
  9. CSS margin 属性简介
  10. angularjs 结构的两种写法(2)