当前位置:网站首页>Application of MATLAB in Linear Algebra (4): similar matrix and quadratic form
Application of MATLAB in Linear Algebra (4): similar matrix and quadratic form
2022-07-05 07:03:00 【Wen Yu is solemn】
Sometimes we need exact eigenvalues and eigenvectors , You have to use Matlab Symbol operation function of .
stay Matlab The form of creating a symbolic matrix in is very similar to that of creating a numerical matrix , Just use symbols to define functions sym.
The following describes several forms of using this function to create a symbol matrix .
1、 Use sym Function directly creates the symbol matrix
This method is almost the same as the method of directly creating numerical matrix .
Matrix elements can be symbolic expressions , various The length of the symbolic expression can be different , Matrix elements can be separated by spaces or commas .
for example :
x=sym('[a+sin(d),b;1/c,d]'); y=det(x)
Get y=(d*c*a+d*c*sin(d)-b)/c
2、 Convert numerical matrix into symbolic matrix
stay Matlab in , Numerical matrices cannot be directly involved in symbolic operations , Must first be converted into a symbolic matrix .
for example :
a=[2/3,sqrt(2);3,1]
a=
0.66671.4142
3.00001.0000
b=sym(a)
b=
[ 2/3, sqrt(2)]
[3,1]
3、 Indexing and modification of symbol matrix
Matlab The index and modification of the symbol matrix of is exactly the same as that of the numerical matrix .
for example :
For the matrix in the above example b Make changes
b(2,2)='log(9)'
01
—
Find an orthogonal transformation x = Py ÿ
边栏推荐
猜你喜欢
Spinningup drawing curve
Ros2 - first acquaintance with ros2 (I)
Literacy Ethernet MII interface types Daquan MII, RMII, smii, gmii, rgmii, sgmii, XGMII, XAUI, rxaui
Sre core system understanding
代码中的英语全部
C语言数组专题训练
Rehabilitation type force deduction brush question notes D1
LSA Type Explanation - lsa-1 [type 1 LSA - router LSA] detailed explanation
Database mysql all
你心目中的数据分析 Top 1 选 Pandas 还是选 SQL?
随机推荐
UIO driven framework
U-Boot初始化及工作流程分析
The difference between new and malloc
Special training of C language array
window navicat连接阿里云服务器mysql步骤及常见问题
ROS2——Service服务(九)
Database mysql all
【MySQL8.0不支持表名大写-对应方案】
ROS2——工作空间(五)
MySQL setting trigger problem
Orin installs CUDA environment
Error: “MountVolume.SetUp failed for volume pvc 故障处理
A brief introduction to heading/pitch/roll and omega/phi/kappa
ROS2——常用命令行(四)
数据库Mysql全部
Ros2 - node (VII)
Financial risk control practice -- feature derivation based on time series
Markdown syntax
6-4 search by serial number of linked list
inux摄像头(mipi接口)简要说明