Skip main navigation

New offer! Get 30% off one whole year of Unlimited learning. Subscribe for just £249.99 £174.99. New subscribers only. T&Cs apply

Find out more

Hands-on: Linear algebra

Explore NumPy's in-built linear algebra routines
In this exercise you can will explore NumPy’s in-built linear algebra routines

Source code for this exercise is located in numpy/linear-algebra/

  1. Construct two symmetric 2×2 matrices A and B.
    Hint: a symmetric matrix can be constructed easily from a square matrix
    as Asym = A + A^T
  2. Calculate the matrix product C = A * B using
  3. Calculate the eigenvalues of matrix C with numpy.linalg.eigvals().

© CSC - IT Center for Science
This article is from the free online

Python in High Performance Computing

Created by
FutureLearn - Learning For Life

Reach your personal and professional goals

Unlock access to hundreds of expert online courses and degrees from top universities and educators to gain accredited qualifications and professional CV-building certificates.

Join over 18 million learners to launch, switch or build upon your career, all at your own pace, across a wide range of topic areas.

Start Learning now