【MATLAB】數(shù)值運算 ( 數(shù)值運算示例 | 三角函數(shù) | 指數(shù)運算 | 對數(shù)運算 | 常用的數(shù)學(xué)公式對應(yīng)函數(shù) )
文章目錄

一、數(shù)值運算 1
二、數(shù)值運算 2
三、常用的數(shù)學(xué)公式對應(yīng)函數(shù)
一、數(shù)值運算 1
使用 matlab 計算如下公式 :
cos ? ( ( 1 + 2 + 3 + 4 ) 3 5 ) \cos \bigg(\sqrt{ \cfrac{(1 + 2 + 3 + 4) ^3}{5} }\bigg) cos(5(1+2+3+4)3
)
在 matlab 中代碼如下 :
平方根 : https://ww2.mathworks.cn/help/matlab/ref/sqrt.html
冪運算 : https://ww2.mathworks.cn/help/matlab/ref/mpower.html
余弦函數(shù) : https://ww2.mathworks.cn/help/matlab/ref/double.cos.html
// 方式一 : cos(sqrt((1 + 2 + 3 + 4)^3/5))
1
2
// 方式二 : cos(((1 + 2 + 3 + 4)^3/5)^0.5)
1
2
執(zhí)行結(jié)果 :
>> Untitled ans = -0.0050
1
2
3
4
5
二、數(shù)值運算 2
計算如下公式 :
sin ? ( π ) + ln ? ( tan ? ( 1 ) ) \sin(\sqrt{\pi}) + \ln (\tan (1)) sin(π
)+ln(tan(1))
ln ? x \ln x lnx 是 log ? e x \log_ex loge x 函數(shù) , 求 x x x 的自然對數(shù) , 是 e x e^x ex 的反函數(shù) ;
涉及到的函數(shù) :
平方根 : https://ww2.mathworks.cn/help/matlab/ref/sqrt.html
sin ? \sin sin 函數(shù) : https://ww2.mathworks.cn/help/matlab/ref/sin.html
tan ? \tan tan 函數(shù) : https://ww2.mathworks.cn/help/matlab/ref/tan.html
log ? \log log 函數(shù) ( 自然對數(shù) ) : https://ww2.mathworks.cn/help/matlab/ref/log.html
常用的常量和測試矩陣 : https://ww2.mathworks.cn/help/matlab/constants-and-test-matrices.html , 在該文檔中有 π \pi π 的表示方法 ;
其它 log ? \log log 函數(shù) : 在 matlab 中 , log 函數(shù)表示以 e e e 為底的對數(shù)計算 ;
log10 表示以 10 10 10 為底的對數(shù) : https://ww2.mathworks.cn/help/matlab/ref/log10.html
log2 表示以 2 2 2 為底的對數(shù) : https://ww2.mathworks.cn/help/matlab/ref/log2.html
指數(shù)和對數(shù)運算參考 https://ww2.mathworks.cn/help/matlab/exponents-and-logarithms.html 頁面 ;
上述公式對應(yīng)的 matlab 代碼如下 :
sin( sqrt(pi) ) + log( tan(1) )
1
執(zhí)行結(jié)果 :
>> Untitled ans = 1.4228
1
2
3
4
5
三、常用的數(shù)學(xué)公式對應(yīng)函數(shù)
常用的數(shù)學(xué)公式對應(yīng)函數(shù) :
算數(shù)運算 : https://ww2.mathworks.cn/help/matlab/arithmetic.html
三角函數(shù) : https://ww2.mathworks.cn/help/matlab/trigonometry.html
指數(shù)與對數(shù) : https://ww2.mathworks.cn/help/matlab/exponents-and-logarithms.html
特殊函數(shù) : https://ww2.mathworks.cn/help/matlab/special-functions.html
離散數(shù)學(xué) : https://ww2.mathworks.cn/help/matlab/discrete-math.html
MATLAB
版權(quán)聲明:本文內(nèi)容由網(wǎng)絡(luò)用戶投稿,版權(quán)歸原作者所有,本站不擁有其著作權(quán),亦不承擔(dān)相應(yīng)法律責(zé)任。如果您發(fā)現(xiàn)本站中有涉嫌抄襲或描述失實的內(nèi)容,請聯(lián)系我們jiasou666@gmail.com 處理,核實后本網(wǎng)站將在24小時內(nèi)刪除侵權(quán)內(nèi)容。
版權(quán)聲明:本文內(nèi)容由網(wǎng)絡(luò)用戶投稿,版權(quán)歸原作者所有,本站不擁有其著作權(quán),亦不承擔(dān)相應(yīng)法律責(zé)任。如果您發(fā)現(xiàn)本站中有涉嫌抄襲或描述失實的內(nèi)容,請聯(lián)系我們jiasou666@gmail.com 處理,核實后本網(wǎng)站將在24小時內(nèi)刪除侵權(quán)內(nèi)容。