This commit is contained in:
nandard 2022-09-08 11:59:19 +07:00
parent 43c51ab2b5
commit 55426d22b8
2 changed files with 2 additions and 2 deletions

View File

@ -46,7 +46,7 @@
"\n",
" for i in range(2, height+2):\n",
" for j in range(height-1):\n",
" arr[i][j] = (arr[i-1][0]*arr[i-2][j+1] - arr[i-2][0]*arr[i-1][j+1])//2\n",
" arr[i][j] = (arr[i-1][0]*arr[i-2][j+1] - arr[i-2][0]*arr[i-1][j+1])/arr[i-1][0]\n",
" arr[i][j] += 0\n",
" \n",
" self.df = pd.DataFrame(arr)\n",

View File

@ -36,7 +36,7 @@ def calc_routh(self):
for i in range(2, height+2):
for j in range(height-1):
arr[i][j] = (arr[i-1][0]*arr[i-2][j+1] - arr[i-2][0]*arr[i-1][j+1])//2
arr[i][j] = (arr[i-1][0]*arr[i-2][j+1] - arr[i-2][0]*arr[i-1][j+1])/arr[i-1][0]
arr[i][j] += 0
self.df = pd.DataFrame(arr)