Questions tagged [linear-equation]

An algebraic equation of the form y = mx+b

A linear equation is an algebraic equation in which each term is either a constant or the product of a constant and (the first power of) a single variable. More on Wolfram and Wikipedia.

203 questions
0
votes
1 answer

the maximum size of matrix in Matlab

I want to solve the linear equation Ax=b, with A is 40000x400000 matrix, x and b are 400000x1 array . When I use A\b in MATLAB, I have the error "out of memory". Because the size of matrix is too large, I can not use A\b in MATLAB. How can I solve…
PHuong
  • 11
  • 3
0
votes
2 answers

Matlab's least square estimate via \ for over-determined system in R

I want to find the least square estimate for an over-determined system of linear equations the way Matlab does with \. What I am trying to reproduce in R: % matlab code X = [3.8642 9.6604; 14.2000 35.5000; 41.7832 104.4580; …
0
votes
2 answers

Is there a way to solve Ternary first-order equation with Maxima?

I want to know the Solving Syntax for Ternary first-order equation on maxima. For example; F_A + F_C + F_E - 15 = 0; -F_A *0.4 + 15*0.2 m + F_E*0.4 = 0; F_C = 0.3*F_A + 0.3*F_E; wanna know How to get the solution F_A, F_C, F _E?
unmask
  • 1
  • 1
0
votes
1 answer

Wrong slope direction while calculating line equation with X and y coordinates

I need to detect some lines from a rasterized image. After having retrieved all the X and Y coordinates, I can manage to create the corresponding line equation for horizontal, vertical and barely diagonal lines perfectly. But I've just stumbled upon…
Axel Isouard
  • 1,498
  • 1
  • 24
  • 38
0
votes
0 answers

Solving equations with interdependent variables & functions when data is in bits

How to solve 2 equations with two variables when functions are involved and data is in bits ? Equation 1: f +i + constant data =reed solomon function (h+contant data) Equation 2: h +i + constant data = reed solomon function ( f + constant…
0
votes
2 answers

Solve the linear equations system AX = B in Python, np.linalg.solve not working

I'm trying to solve the linear equation AX=B where A,X,B are Matrices. I've tried using the np.linalg.solve function of numpy but the result seems to be wrong. Example: Matrix A [9 1 8] [3 2 5] [1 6 5] Matrix B [7 0 5] [7 8 4] [5 6…
0
votes
1 answer

Solving linear equations where each matrix element itself is matrix (2D) and each variables are 1D vectors

The simple example of the problem is: In my case: Any idea/suggestion is highly appreciated.
nero_bin
  • 65
  • 5
0
votes
2 answers

Create arrays for linear equations solver with Python

I'm new to this site and new to Python. I remember when I was at school, I wrote a program in BASIC (it was in the eighties) to solve systems of linear equations using matrices. I would like to do the same in Python and I found it could be done with…
Wilou
  • 1
  • 2
0
votes
1 answer

Linear Equation not possible to solve?

I want to solve a linear equation A*x=b with A<-matrix(c(1,4,9,5,2,3,8,4,3,2,7,3,4,1,6,2),4,4) b<-c(2,0,7,9) If I then use the solve() function it shows an error: solve(A,b) Error in solve.default(A, b) : system is computationally singular:…
Trigger
  • 35
  • 7
0
votes
1 answer

How to solving linear equations with python

I am trying to solve linear equations with a numpy array based on user inputs. I've programmed a simple calculator that can deal with every day problems, but I would like to add the feature where you can choose to solve a linear equation. Exp: 2x +…
0
votes
0 answers

C program solving parametric equations

Let's say you have N equations with M parameters. Task is to find if there is any solution. If there is, which one. If there are more solutions, how do you describe them ? example: 1) x + y + z = 1 2) y + z = 4 Matrix form: ( 1 1 1 | 1 ) ( 0 1 1…
Talos
  • 457
  • 4
  • 15
0
votes
0 answers

Solving a system of constrained linear equations

I need to solve a large system of linear equations using a least squares method. So far I have found the answers whilst unconstrained but would like to limit my answers to be non-negative. The code I have been using is shown below. 'Sheet 1' holds a…
0
votes
1 answer

Python - Finding the linear equation of a line in a image

I am using Python v2.7 for this work. As an input i have a relatively white image with a clear black line on it. The line is always linear, no polynomial of second or above order. The line can be anyway on the image I am trying to define the…
Sebdarmy
  • 145
  • 1
  • 13
0
votes
1 answer

Solve linear equation system b=0

I found this code to resolve a linear equation system with b=0, but I would like to know why with the first matrix only one column is returned and with the second matrix two columns are returned. library(MASS) Null(t(A)) R > (A <-…
0
votes
0 answers

Java API for solving Linear expression with one variable

Is there any standard Java API for solving Linear expressions with one variable as following example: x*1/40+5 = 12.45 x*635/(27*1024) = 52 x^2-3.4/6 = 43 3+logx-13 = 15 I tried to solve it with Apache Common Math library but the Matrix and…
Kishor Prakash
  • 8,011
  • 12
  • 61
  • 92