Linear algebra

1.模块文档

NAME
    numpy.linalg
DESCRIPTION
    Core Linear Algebra Tools
    -------------------------
    Linear algebra basics:

    - norm            Vector or matrix norm
    - inv             Inverse of a square matrix
    - solve           Solve a linear system of equations
    - det             Determinant of a square matrix
    - lstsq           Solve linear least-squares problem
    - pinv            Pseudo-inverse (Moore-Penrose) calculated using a singular
                      value decomposition
    - matrix_power    Integer power of a square matrix

    Eigenvalues and decompositions:

    - eig             Eigenvalues and vectors of a square matrix
    - eigh            Eigenvalues and eigenvectors of a Hermitian matrix
    - eigvals         Eigenvalues of a square matrix
    - eigvalsh        Eigenvalues of a Hermitian matrix
    - qr              QR decomposition of a matrix
    - svd             Singular value decomposition of a matrix
    - cholesky        Cholesky decomposition of a matrix

    Tensor operations:

    - tensorsolve     Solve a linear tensor equation
    - tensorinv       Calculate an inverse of a tensor

    Exceptions:

    - LinAlgError     Indicates a failed linear algebra operation
LA.info?
Type:        module
String form: <module 'numpy.linalg.info' from 'F:\\Anaconda3\\lib\\site-packages\\numpy\\linalg\\info.py'>
File:        f:\anaconda3\lib\site-packages\numpy\linalg\info.py
Docstring:
Core Linear Algebra Tools
-------------------------
Linear algebra basics:

- norm            Vector or matrix norm
- inv             Inverse of a square matrix
- solve           Solve a linear system of equations
- det             Determinant of a square matrix
- lstsq           Solve linear least-squares problem
- pinv            Pseudo-inverse (Moore-Penrose) calculated using a singular
                  value decomposition
- matrix_power    Integer power of a square matrix

Eigenvalues and decompositions:

- eig             Eigenvalues and vectors of a square matrix
- eigh            Eigenvalues and eigenvectors of a Hermitian matrix
- eigvals         Eigenvalues of a square matrix
- eigvalsh        Eigenvalues of a Hermitian matrix
- qr              QR decomposition of a matrix
- svd             Singular value decomposition of a matrix
- cholesky        Cholesky decomposition of a matrix

Tensor operations:

- tensorsolve     Solve a linear tensor equation
- tensorinv       Calculate an inverse of a tensor

Exceptions:

- LinAlgError     Indicates a failed linear algebra operation

2.可用方法

'bench','cholesky','cond','det','division','eig','array','eigh','eigvals','eigvalsh','info','inv','lapack_lite','linalg','lstsq','matrix_power','matrix_rank','multi_dot','norm','pinv','print_function','qr','slogdet','solve','svd','tensorinv','tensorsolve','test'
eig : eigenvalues and right eigenvectors of general arrays
    eigvalsh : eigenvalues of symmetric or Hermitian arrays.
    eigh : eigenvalues and eigenvectors of symmetric/Hermitian arrays.

3.常用方法

首先导入相关模块

import numpy as np
from numpy import linalg as LA

3.1求数组的行列式:det

3.2求方阵的特征值、特征向量:eig

3.3求方阵的逆矩阵::inv

3.4求解线性方程组:solve

Solve the system of equations 3 * x0 + x1 = 9 and x0 + 2 * x1 = 8:

3.5一个方阵的整数次幂:matrix_power

3.6计算在一个函数调用两个或两个以上的阵列的点积:multi_dot

4.官网文档

https://docs.scipy.org/doc/numpy/reference/routines.linalg.html

Python Linear algebra的更多相关文章

  1. PYTHON替代MATLAB在线性代数学习中的应用(使用Python辅助MIT 18.06 Linear Algebra学习)

    前言 MATLAB一向是理工科学生的必备神器,但随着中美贸易冲突的一再升级,禁售与禁用的阴云也持续笼罩在高等学院的头顶.也许我们都应当考虑更多的途径,来辅助我们的学习和研究工作. 虽然PYTHON和众 ...

  2. Linear Algebra lecture1 note

    Professor: Gilbert Strang Text: Introduction to Linear Algebra http://web.mit.edu/18.06   Lecture 1 ...

  3. 算法库:基础线性代数子程序库(Basic Linear Algebra Subprograms,BLAS)介绍

    调试DeepFlow光流算法,由于作者给出的算法是基于Linux系统的,所以要在Windows上运行,不得不做大量的修改工作.移植到Windows平台,除了一些头文件找不到外,还有一些函数也找不到.这 ...

  4. 线性代数导论 | Linear Algebra 课程

    搞统计的线性代数和概率论必须精通,最好要能锻炼出直觉,再学机器学习才会事半功倍. 线性代数只推荐Prof. Gilbert Strang的MIT课程,有视频,有教材,有习题,有考试,一套学下来基本就入 ...

  5. Here’s just a fraction of what you can do with linear algebra

    Here’s just a fraction of what you can do with linear algebra The next time someone wonders what the ...

  6. cdoj793-A Linear Algebra Problem

    http://acm.uestc.edu.cn/#/problem/show/793 A Linear Algebra Problem Time Limit: 3000/1000MS (Java/Ot ...

  7. 个案排秩 Rank (linear algebra) 秩 (线性代数)

    非叫“秩”不可,有秩才有解_王治祥_新浪博客http://blog.sina.com.cn/s/blog_8e7bc4f801012c23.html 我在一个大学当督导的时候,一次我听一位老师给学生讲 ...

  8. 读Linear Algebra -- Gilbert Strang

    转眼间我的学士学位修读生涯已经快要到期了,重读线性代数,一是为了重新理解Algebra的的重要概念以祭奠大一刷过的计算题,二是为了将来的学术工作先打下一点点(薄弱的)基础.数学毫无疑问是指导着的科研方 ...

  9. Codeforces Gym101502 B.Linear Algebra Test-STL(map)

    B. Linear Algebra Test   time limit per test 3.0 s memory limit per test 256 MB input standard input ...

随机推荐

  1. 关于Linux的loop设备

    偶然发现/dev目录里有几个loop设备,一番搜索得知,这是一种伪设备(pseudo-device),它可以把一个文件连接为设备(就像Windows下用虚拟光驱挂载ISO文件). 遂做实验验证: 1. ...

  2. 谈谈浏览器http缓存

    请求头 user-agent pragma Cache-control Referer Accept Cookit If-Modified-Since If-None-Match 响应头 conten ...

  3. Struts 2.5 Filter mapping specifies an unknown filter name [struts2]

    问题一:java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start ...

  4. Safe Area Layout Guide

    原文:Safe Area Layout Guide Apple在iOS 7中引入了topLayoutGuide和bottomLayoutGuide作为UIViewController属性.它们允许您创 ...

  5. OpenCV探索之路(二十五):制作简易的图像标注小工具

    搞图像深度学习的童鞋一定碰过图像数据标注的东西,当我们训练网络时需要训练集数据,但在网上又没有找到自己想要的数据集,这时候就考虑自己制作自己的数据集了,这时就需要对图像进行标注.图像标注是件很枯燥又很 ...

  6. C - Coin Change (III)(多重背包 二进制优化)

    C - Coin Change (III) Time Limit:2000MS     Memory Limit:32768KB     64bit IO Format:%lld & %llu ...

  7. python之路第五篇之装饰器:(进阶篇)

    装饰器: 学前必备知识: def f1(): print "f1" f1() #表示函数执行 f1 #表示函数,指向内存地址 f1 = lambda x: x + 1 f1() # ...

  8. Python GUI - Tkinter tkMessageBox

    Python GUI - Tkinter tkMessageBox: tkMessageBox模块用于显示在您的应用程序的消息框.此模块提供了一个功能,您可以用它来显示适当的消息     tkMess ...

  9. 使用dropload.js插件进行下拉刷新

    移动端的下拉刷新是一个比较常见的功能了,网上也有很多框架,插件都有这种功能,所以直接拿来用就好了. html代码: <!--选项卡--><div class="tab&qu ...

  10. 一些精妙的sql语句收集

    --1.说明:复制表(只复制结构,源表名:a 新表名:b) (Access可用) --法一: select * into b from a where 1<>1 --法二: select ...