Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

I have this equation, $$f(x)=Ax-diag(x)(Ax+b)$$, where $x\in \mathbb{R}^n$, $A\in \mathbb{R}^{n\times n}$ and $b\in \mathbb{R}^n$, for which I need to find the zeros. $x=0$ is an obvious solution, but I would like to see if there are other solutions as well.

Is there an explicit way to get the solution in terms of, $A$ and $b$ without specifying the matrices completely?

share|improve this question
add comment

1 Answer

It's hard to know how far you can go, but Solve can work in this kind of situation. For instance, leaving all parameters completely free, define the elements and the function f:

n=2;
aMat = Array[a, {n,n}];
xVec = Array[x, n];
bVec = Array[b, n];
f[xVec_] := aMat.xVec - DiagonalMatrix[xVec].(aMat.xVec + bVec);

Then solve for the zeros

Solve[f[xVec] == 0, xVec]

At least in the 2-by-2 case, you get a completely general answer, though it is unwieldy.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.