1

Numpyでそのような方程式の自明でない解を得るにはどうすればよいですか?

r1 = r1 * 0.03  + r2 * 0.88 + r3 * 0.2425 + r4 * 0.03 + r5 * 0.03
r2 = r1 * 0.455 + r2 * 0.03 + r3 * 0.2425 + r4 * 0.03 + r5 * 0.88
r3 = r1 * 0.455 + r2 * 0.03 + r3 * 0.03   + r4 * 0.03 + r5 * 0.03
r4 = r1 * 0.03  + r2 * 0.03 + r3 * 0.2425 + r4 * 0.03 + r5 * 0.03
r5 = r1 * 0.03  + r2 * 0.03 + r3 * 0.2425 + r4 * 0.88 + r5 * 0.03
4

1 に答える 1

1

If you're just looking for a library function that does this, just use numpy.linalg.eig and look for the eigenvector with eigenvalue equal to 1. If you need to implement an iterative solver, probably the power method is the best idea for this. It should simply work because the vector with eigenvalue of 1 is also the one with largest eigenvalue. Krylov subspace method (Rayleigh iteration) should work well on this too.

于 2012-11-08T22:49:43.900 に答える