日期:11-14
作者:老李
按列选主元策略的高斯消去法
目标
编写函数,实现列选主元策略的高斯消去法
过程
1.消去
2.回代
代码如下:
function [ X, U ] = colGaussElim( A, b )
%colGaussElim :Gauss elimination method of column selection principal element
% Input - :A is the coefficient matrix(n*n)
% - :b is the value of equations(n*1)
% Output - :X is the solutions of equaions(n*1)
% - :U is the coefficient matrix after elimination
M = [A b];%增广矩阵
[n, ~] = size

本文介绍了一种改进的高斯消去法——列选主元策略的高斯消去法,并提供了一个MATLAB函数实现。该方法通过在每一步选择列中绝对值最大的元素作为主元,提高了数值稳定性。
最低0.47元/天 解锁文章
1万+





