1、对数函数

import math
import matplotlib.pyplot as plt
import numpy as np if __name__ == '__main__':
x = np.arange(0.05,3,0.05)
y1 = [math.log(a,1.5) for a in x]
plt.plot(x,y1,linewidth=2,color='#007500',label='log1.5(x)')
plt.plot([1,1],[y1[0],y1[-1]],"r--",linewidth=2)
y2 = [math.log(a,2) for a in x]
plt.plot(x,y2,linewidth=2,color='#9F35FF',label='log2(x)')
y3 = [math.log(a,3) for a in x]
plt.plot(x,y3,linewidth=2,color='#F75000',label='log3(x)')
plt.legend(loc='lower right')
plt.grid(True)
plt.show()

最新文章

  1. 在VS2010配置MPI--win7下64位系统
  2. 云服务器 ECS Linux IO 占用高问题排查方法
  3. HDU 5475 An easy problem 线段树
  4. liunx运维面试题汇总二
  5. logstash 使用grok正则解析日志
  6. Spark集群搭建中的问题
  7. ABAP 在屏幕上显示图片
  8. MongoDB学习笔记(一)
  9. web框架开发-Django的Forms组件
  10. JavaWeb学习日记----XML的解析
  11. 【Visual Studio】Visual Studio对CLR异常的特殊支持
  12. 导入不用的css文件及在不同设备显示不用的html页面
  13. 【Linux 命令】- tar 命令
  14. Java 深入浅出String
  15. 多进程并发简单socket
  16. Maven的目录结构和常用命令
  17. <Effective C++>读书摘要--Inheritance and Object-Oriented Design<二>
  18. CSS3不一样的下拉选择框
  19. Blender 软件 四视图布局的创建方法
  20. 架构师入门ing

热门文章

  1. go get 无反应、访问github.com速度慢、没反应问题的解决方案
  2. Ignatius and the Princess III HDU - 1028 -生成函数or完全背包计数
  3. 基于Ardalis.GuardClauses守卫组件的拓展
  4. SQL Server中变量的声明和使用方法
  5. 分布式存储MooseFS
  6. Java笔记(二)类
  7. 2011 ACM 0和1思想
  8. openstack之glance基础
  9. flask之flask-script组件
  10. 20、collections模块和re模块(正则表达式详解)