You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
706 B

This file contains invisible Unicode characters!

This file contains invisible Unicode characters that may be processed differently from what appears below. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to reveal hidden characters.

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

# 1.4 求解线性方程组
## (1). 解题说明
`numpy`与`scipy`库中提供了常用求解线性方程组的方法包括矩阵求逆、直接求解、LU分解等对于比较特殊的矩阵例如稀疏矩阵还提供了特殊的求解方法。不同方法的优缺点比较如下
| 求解方法 | 优点 | 缺点 |
| :-------------: | :--------------: | :--------------: |
| 1. 矩阵求逆求解 | 简单 | 效率较低 |
| 2. 消元法求解 | 算法直观、稳定 | 效率低 |
| 3. LU分解 | LU分解结果可复用 | 不保证数值稳定性 |
## (2). 运行结果
![](images/result.png)