iOS常用的数学函数
| 1、 三角函数 | |
| double sin (double);正弦 | |
| double cos (double);余弦 | |
| double tan (double);正切 | |
| 2 、反三角函数 | |
| double asin (double); 结果介于[-PI/2, PI/2] | |
| double acos (double); 结果介于[0, PI] | |
| double atan (double); 反正切(主值), 结果介于[-PI/2, PI/2] | |
| double atan2 (double, double); 反正切(整圆值), 结果介于[-PI, PI] | |
| 3 、双曲三角函数 | |
| double sinh (double); | |
| double cosh (double); | |
| double tanh (double); | |
| 4 、指数与对数 | |
| double exp (double);求取自然数e的幂 | |
| double sqrt (double);开平方 | |
| double log (double); 以e为底的对数 | |
| double log10 (double);以10为底的对数 | |
| double pow(double x, double y);计算以x为底数的y次幂 | |
| float powf(float x, float y); 功能与pow一致,只是输入与输出皆为浮点数 | |
| 5 、取整 | |
| double ceil (double); 取上整 | |
| double floor (double); 取下整 | |
| 6 、绝对值 | |
| double fabs (double);求绝对值 | |
| double cabs(struct complex znum) ;求复数的绝对值 | |
| 7 、标准化浮点数 | |
| double frexp (double f, int *p); 标准化浮点数, f = x * 2^p, 已知f求x, p ( x介于[0.5, 1] ) | |
| double ldexp (double x, int p); 与frexp相反, 已知x, p求f | |
| 8 、取整与取余 | |
| double modf (double, double*); 将参数的整数部分通过指针回传, 返回小数部分 | |
| double fmod (double, double); 返回两参数相除的余数 | |
| 9 、其他 | |
| double hypot(double x, double y);已知直角三角形两个直角边长度,求斜边长度 | |
| double ldexp(double x, int exponent);计算x*(2的exponent次幂) | |
| double poly(double x, int degree, double coeffs [] );计算多项式 | |
| nt matherr(struct exception *e);数学错误计算处理程序 |
iOS常用的数学函数的更多相关文章
- iOS开发中常用的数学函数
iOS开发中常用的数学函数 /*---- 常用数学公式 ----*/ //指数运算 3^2 3^3 NSLog(,)); //result 9 NSLog(,)); //result 27 //开平方 ...
- 【python游戏编程之旅】第四篇---pygame中加载位图与常用的数学函数。
本系列博客介绍以python+pygame库进行小游戏的开发.有写的不对之处还望各位海涵. 在上一篇博客中,我们学习了pygame事件与设备轮询.http://www.cnblogs.com/msxh ...
- 【python游戏编程04--加载位图与常用的数学函数】
一.pygame中常用的数学函数 首先介绍两个角度和弧度转换的函数 math.degress()和math.radians()用法很简单,只要将数值传进去然后接受返回值就可以 math.cos(ang ...
- iOS math.h数学函数
在实际工作中有些程序不可避免的需要使用数学函数进行计算,比如地图程序的地理坐标到地图坐标的变换.Objective-C做为ANSI C的扩展,使用C标准库头文件<math.h>中定义的数学 ...
- PHP常用的数学函数和字符串函数
PHP常用函数总结 数学函数 1.abs(): 求绝对值 $abs = abs(-4.2); //4.2 数字绝对值数字 2.ceil(): 进一法取整 echo ceil(9.999); // 10 ...
- C++中常用的数学函数总结
我们在C++程序设计的过程中往往会使用到一些数学函数,那么不同的数学运算要用到什么函数哪?大家可以参考我的总结如下: 首先引用到数学函数时一定要记得加函数头文件 #include<cmath&g ...
- OC常用的数学函数及宏定义
一.函数 1. 三角函数 double sin (double);正弦 double cos (double);余弦 double tan (double);正切 2 .反三角函数 double as ...
- MySQL常用的数学函数
在使用mysql自带的函数要慎重,说是会影响数据执行效率,代价太大.这个也要区分开,区分快软件的引用范畴,比如说内部系统业务逻辑比较复杂,功能点很细,但是并发量不是很大,这个时候用MySQL自带的函数 ...
- SAP (ABAP) 常用的数学函数
Function func Return value abs Absolute value of the argument arg (绝对值) sign Plus/minus sign of the ...
随机推荐
- java期末总结
java期末总结: java语言特点:1.简洁有效 2.可移植性 3.面向对象 4.解释型 5.适合分布式计算 6.拥有较好的性能 7.健壮.防患于未然 8.具有多线程处理能力 9.具有较高的安全性 ...
- eclipse subclipse svn 插件安装使用
一.在线安装 1.打开Eclipse,菜单栏中选择"Help"->"Install New SoftWare..." 2.在弹出的对话框中,点击" ...
- 获取手机本地IP地址
public String getLocalIpAddress() { try { for (Enumeration<NetworkInterface> en = NetworkInter ...
- nodejs之流数据读取与写入
1.(fs.createReadStream)当文件比较大时,建议使用文件流读取,不会出现卡顿现象,demo如下. const fs = require('fs'); //流的方式读取文件 var r ...
- Promise.then链式调用
let a = new Promise((resolve,reject)=>{ resolve(1) }).then((r)=>{console.log(r)}).then(()=> ...
- 阶段3 2.Spring_02.程序间耦合_6 工厂模式解耦
使用类加载器去加载文件 定义getBean的方法 运行测试方法报错. 在工厂类里面打印输出BeanPath 删除dao的实现类 没有dao的实现类.再次运行程序.编译不报错.运行时报错 以上就是工厂模 ...
- 非GUI运行Jmeter,jtl文件没有响应数据的解决办法
一.问题 Jmeter官方一直强调要在非GUI模式下运行Jmeter:Run your JMeter test in command-line non-GUI mode. 但在非GUI模式下运行生成的 ...
- Jmeter之乱码 (三)
使用Jmeter执行JDBC请求,往MySQL数据库中插入数据,如下图: 执行结果如下: 解决方案: 在JDBC Connection Configuration中的Database URL后加上&a ...
- ubuntu 常用命令及一些问题collection
转载请包含http://www.cnblogs.com/lqruui/p/5306941.html 一.安装卸载删除 1.手动 install.卸载.删除 1.首先tar -zxvf +压缩包名解压压 ...
- (转)Maven的pom.xml文件配置使用
转载:http://www.cnblogs.com/GarfieldTom/p/3707160.html <project xmlns="http://maven.apache.org ...