1、exp函数:求以e为底的指数函数
2、用法说明:y=exp(x) 函数对数组元素x进行逐个处理的函数。函数定义域包括复数。对于复数z=a+b*i,有ez=(cos(b)+i*sin(b)*ea)
3、实例
>> x=4
x =
4
>> y=exp(x)
y =
54.5982
>> x=rand(4,6)
x =
0.8147 0.6324 0.9575 0.9572 0.4218 0.6557
0.9058 0.0975 0.9649 0.4854 0.9157 0.0357
0.1270 0.2785 0.1576 0.8003 0.7922 0.8491
0.9134 0.5469 0.9706 0.1419 0.9595 0.9340
>> y=exp(x)
y =
2.2586 1.8820 2.6052 2.6043 1.5246 1.9266
2.4739 1.1025 2.6245 1.6248 2.4986 1.0364
1.1354 1.3211 1.1707 2.2262 2.2083 2.3376
2.4927 1.7279 2.6395 1.1524 2.6104 2.5447
>> x=[1+2i 3-4i 5+6i 7-4i]
x =
1.0000 + 2.0000i 3.0000 - 4.0000i 5.0000 + 6.0000i 7.0000 - 4.0000i
>> y=exp(x)
y =
1.0e+02 *
-0.0113 + 0.0247i -0.1313 + 0.1520i 1.4250 - 0.4147i -7.1681 + 8.2993i