Skip to main content

Questions tagged [linear-algebra]

For code that aims to resolve problems of linear algebra like vectors, vectorial space, linear transformations and systems of equations.

2 votes
1 answer
96 views

Calculating the pattern behind the Levi-Civita symbol, works for all N >= 3

I have a code that calculates the pattern behind the Levi-Civita symbol. Unfortunately, it cheats for N >= 10. Any ideas how I can calculate the pattern for N >= 10 explicitly, without cheating? ...
shawn_halayka's user avatar
8 votes
4 answers
1k views

Calculating the determinant of a matrix using a purely analytical method that involves the "cross product" in nD

I've been conversing with the various AIs about the cross product in 3D and 7D. I've been lead to believe that n = 3 and n = 7 are only dimensions where the cross product is a well-defined operator. ...
shawn_halayka's user avatar
2 votes
1 answer
80 views

Building Multi Period Linear Programming Matrices

I'm solving a linear programming problem, made of many small problems with some common shared constraints, meaning that they are all together. Each individual unit has constraints unique to the unit ...
AReubens's user avatar
4 votes
2 answers
157 views

C - SIMD Code to invert a transformation matrix

I am writing a maths library for a raytracer project, and so I'm trying to make my heavy operations (like matrix inverse) more optimised. After doing some research, I discovered this trick to invert a ...
Astranged T'fyer's user avatar
3 votes
3 answers
155 views

Determinant of matrix Python

This is an addition of my previous question Python matrix class. I've added a determinant function using Laplace expansion to my Matrix class. What I am looking for specifically is how 3x3 matrices ...
Ben A's user avatar
  • 10.8k
8 votes
5 answers
1k views

Python matrix class

To prepare for my studies in linear algebra, I've decided to write a simple matrix class. This is the initial program, with functions to find the determinant and decomposition(s) to follow. I wanted ...
Ben A's user avatar
  • 10.8k
2 votes
1 answer
157 views

Multithreaded sparse linear solver in Python

I would like to know if there are any multithreaded sparse linear solvers for LU decomposed sparse matrices. I want to increase the solving speed of a system like: ...
aqw's user avatar
  • 29
5 votes
3 answers
339 views

Find highest number of swaps within a set of possible duty swaps with networkx and PuLP

With huge help from Stack Overflow, I have created code which takes possible swap matches with given weights as an input and outputs a set of matches which gives the highest weight with the highest ...
Oehoe's user avatar
  • 53
2 votes
1 answer
103 views

Scene Hierarchy with Translation, Rotation and Scale

This code represents an Entity Component that holds and manipulates an entity's local and world transforms, dealing with hierarchy and translation/rotation/scale transformations. The code is written ...
Daniel Marques's user avatar
-1 votes
1 answer
59 views

Python manual SVD only working for some matrices - how to stabilize it? [closed]

I use the following code for a manual single value decomposition using numpy. Depending on the array I choose it sometimes works out well and I can verify the svd and sometimes it does not work out ...
LF-137's user avatar
  • 7
5 votes
2 answers
531 views

Partial pivoting code in python

...
JustAnotherMind's user avatar
1 vote
1 answer
297 views

Implementing Preconditioned conjugate gradient

I have implemented the Preconditioned Conjugate Gradient (PCG) method for solving a system of linear equations in Python and I would appreciate it if someone could verify its correctness since I am ...
blov's user avatar
  • 29
2 votes
1 answer
290 views

Python integer optimization with PuLP involving polynomials that I think can be faster

I have a problem where we are given multivariate polynomials in variables like y_i and z_j and the goal is to express them as sums of products of terms of the form y_i-z_j with nonnegative integer ...
Matt Samuel's user avatar
5 votes
2 answers
553 views

Generic matrix library in Java

I have this repository. The most important source files follow. com.github.coderodde.math.linear.matrix.AbstractMatrix.java: ...
coderodde's user avatar
  • 31.9k
2 votes
0 answers
79 views

Implementing PLU Decomposition in Rust

I am using abstalg, because I wanted to learn more about how to do this with generic fields, (So you can implement LU decomposition not just for floats). I used ...
Rainb's user avatar
  • 121

15 30 50 per page