Why can't solve this equation, why there is no answer [closed]

Why can't solve this equation, why there is no answer. Please give me advice if you can understand,

m=Subscript[p, 0, 8], Subscript[p, 1, 7], Subscript[p, 1, 8], \
Subscript[p, 2, 6], Subscript[p, 2, 7], Subscript[p, 3, 5], \
Subscript[p, 3, 6], Subscript[p, 4, 4], Subscript[p, 4, 5], \
Subscript[p, 5, 3], Subscript[p, 5, 4], Subscript[p, 6, 2], \
Subscript[p, 6, 3], Subscript[p, 7, 1], Subscript[p, 7, 2], \
Subscript[p, 8, 0], Subscript[p, 8, 1], Subscript[p, 8, 2], \
Subscript[p, 9, 0], Subscript[p, 9, 1], Subscript[p, 10, 0]

soll=20 Subscript[p, 0, 8]==30 Subscript[p, 1, 7] + 30 Subscript[p, 1, 8],
50 Subscript[p, 1, 7] ==50 Subscript[p, 1, 8] + 30 Subscript[p, 2, 6] +
30 Subscript[p, 2, 7], 100 Subscript[p, 1, 8] == 20 Subscript[p, 0, 8] +
30 Subscript[p, 2, 8], 50 Subscript[p, 2, 6] == 50 Subscript[p, 2, 7] +
30 Subscript[p, 3, 5] + 30 Subscript[p, 3, 6], 100 Subscript[p, 2, 7] ==
20 Subscript[p, 1, 7] + 50 Subscript[p, 2, 8] + 30 Subscript[p, 3, 7],
50 Subscript[p, 3, 5] == 50 Subscript[p, 3, 6] + 30 Subscript[p, 4, 4] +
30 Subscript[p, 4, 5], 100 Subscript[p, 3, 6] == 20 Subscript[p, 2, 6] +
50 Subscript[p, 3, 7] + 30 Subscript[p, 4, 6], 50 Subscript[p, 4, 4] ==
50 Subscript[p, 4, 5] + 30 Subscript[p, 5, 3] + 30 Subscript[p, 5, 4],
100 Subscript[p, 4, 5] == 20 Subscript[p, 3, 5] + 50 Subscript[p, 4, 6] +
30 Subscript[p, 5, 5],50 Subscript[p, 5, 3] == 50 Subscript[p, 5, 4] +
30 Subscript[p, 6, 2] + 30 Subscript[p, 6, 3], 100 Subscript[p, 5, 4] ==
20 Subscript[p, 4, 4] + 50 Subscript[p, 5, 5] + 30 Subscript[p, 6, 4],
50 Subscript[p, 6, 2] == 50 Subscript[p, 6, 3] + 30 Subscript[p, 7, 1] +
30 Subscript[p, 7, 2], 100 Subscript[p, 6, 3] == 20 Subscript[p, 5, 3] +
50 Subscript[p, 7, 2] + 30 Subscript[p, 8, 0] + 30 Subscript[p, 8, 1],
100 Subscript[p, 7, 2] == 20 Subscript[p, 6, 2] + 50 Subscript[p, 7, 3] +
30 Subscript[p, 8, 2], 50 Subscript[p, 8, 0] == 50 Subscript[p, 8, 1] +
30 Subscript[p, 9, 0], 100 Subscript[p, 8, 1] == 20 Subscript[p, 7, 1] +
50 Subscript[p, 8, 2] + 30 Subscript[p, 9, 1], 80 Subscript[p, 8, 2] ==
20 Subscript[p, 7, 2], 50 Subscript[p, 9, 0] == 20 Subscript[p, 8, 0] +
50 Subscript[p, 9, 1] + 30 Subscript[p, 10, 0], 80 Subscript[p, 9, 1] ==
20 Subscript[p, 8, 1], 30 Subscript[p, 10, 0] == 20 Subscript[p, 9, 0],
Subscript[p, 0, 8] + Subscript[p, 1, 7] + Subscript[p, 1, 8] +
Subscript[p, 2, 6] + Subscript[p, 2, 7] + Subscript[p, 3, 5] +
Subscript[p, 3, 6] + Subscript[p, 4, 4] + Subscript[p, 4, 5] +
Subscript[p, 5, 3] + Subscript[p, 5, 4] + Subscript[p, 6, 2] +
Subscript[p, 6, 3] + Subscript[p, 7, 1] + Subscript[p, 7, 2] +
Subscript[p, 8, 0] + Subscript[p, 8, 1] + Subscript[p, 8, 2] +
Subscript[p, 9, 0] + Subscript[p, 9, 1] + Subscript[p, 10, 0] == 1


It is difficult to see it because the code is long, however please advise why the answer doesn't come. Is it because there is no linear independence?

closed as off-topic by Cassini, Bob Hanlon, Henrik Schumacher, m_goldberg, Niki EstnerJan 3 at 14:55

This question appears to be off-topic. The users who voted to close gave this specific reason:

• "This question arises due to a simple mistake such as a trivial syntax error, incorrect capitalization, spelling mistake, or other typographical error and is unlikely to help any future visitors, or else it is easily found in the documentation." – Bob Hanlon, Henrik Schumacher, Niki Estner
If this question can be reworded to fit the rules in the help center, please edit the question.

• You need to use something like Solve to solve equations. – Chris K Jan 2 at 17:23
• Please take a look at some other examples (here on this site and in the documentation of Mathematica). Your code contains syntax errors and it's unclear to me what exactly you're after. Also, do not to use Subscript type variables unless you know exactly what you're doing. – Lukas Lang Jan 2 at 17:23
• @Chris K Thank you for advice.It solved properly. – Kenta Kawai Jan 7 at 6:30
• @Lukas Lang Thank you for advice.It solved properly. – Kenta Kawai Jan 7 at 6:30

This is an extended comment.

Can we assume that m is a list of unknowns and that soll is a list of equations? If so you should put curly brackets { } around them to indicate that they are a list.

I have put in the brackets and looked at your list of unknowns and list of equations. Just looking at the Length indicated that they are both equal to 21. Then I did

Solve[soll, m]


which gave me a list of solutions. However the solutions were in terms of the variables so there is a problem.

Next I changed your equations into a list of expressions by doing

e = soll /. a_ == b_ :> a - b


which gave a list of expressions. Next I looked at the variables in your expressions

v = Union[Variables[e]]


This gave me a list of your variables in the expressions. I then looked at its length

Length@v


27

so there are 27 variables in your expression and only 21 unknowns in your list m.

Complement[v, m]


{Subscript[p, 2, 8], Subscript[p, 3, 7], Subscript[p, 4, 6], \ Subscript[p, 5, 5], Subscript[p, 6, 4], Subscript[p, 7, 3]}

As stated by @LucasLang it is best not to use Subscript. The simpler form is to use single brackets so p[0,8] is the simple Mathematica approach. Note the difference with double brackets [[1,2]] which means Part.

To get rid of your Subscript I did

m1 = m /. Subscript[p, a_, b_] -> p[a, b]


{p[0, 8], p[1, 7], p[1, 8], p[2, 6], p[2, 7], p[3, 5], p[3, 6], p[4, 4], p[4, 5], p[5, 3], p[5, 4], p[6, 2], p[6, 3], p[7, 1], p[7, 2], p[8, 0], p[8, 1], p[8, 2], p[9, 0], p[9, 1], p[10, 0]}

and the same for

eqns = soll /. Subscript[p, a_, b_] -> p[a, b];


and now we can solve.

sol = NSolve[eqns, m1];


An example of the first of the solutions is

sol[[1, 1]]


p[0, 8] -> 0.194055 + 5.48157 p[2, 8] + 4.01839 p[3, 7] + 2.78865 p[4, 6] + 1.76732 p[5, 5] + 0.529744 p[6, 4] + 0.226656 p[7, 3]

Which shows that the solution can only be obtained in terms of some of your variables.

Hope that helps.