在线等 ---求助C++高手 高斯—塞德尔迭代法 问题

来源:百度知道 编辑:UC知道 时间:2024/05/30 12:09:19
高手 看看 顺便 翻译下注释的英文....在线等
回答好的 再 加分
要详细说明高斯-赛德尔迭代法的基本原理和算法。
//'mat' is my actual matrix
//size of 'variable' always =(column-1)
//contains the solution set
//counts number of iterations
//performs a single iteration on all the equations
//the argument is the relaxation coefficient
//checks the allowable error
//small funtion for asking the user for the number of rows and columns
//prepares function for reduction
//solves by gauss-seigel method,
//perfomes multiple iterations until a solution is found
//the argument is the relaxation-coefficient, and this is "past" to 'iteration'
//prints the solution
//creates my matrix dynamically, but there are still no values in the positions

//rearranges the system so that it can be solved by gauss-seigel method
//must always rearange before solving
//'variable' will contain the

给我分!!!!!!!!!!!!!!

高斯-塞德尔迭代法算法: 设方程组AX=b 的系数矩阵的对角线元素 ,M为迭代次数容许的最大值, 为容许误差。
① 取初始向量 ,令k=0
② 对 计算
③ 如果 ,则输出 ,结束;否则执行④,
④ 如果 ,则不收敛,终止程序;否则 ,转②。