Ejercicios realizados

parent ba7800f0
...@@ -910,7 +910,7 @@ ...@@ -910,7 +910,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 9, "execution_count": 13,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
...@@ -954,6 +954,7 @@ ...@@ -954,6 +954,7 @@
" eliminaColumna(A, Inver, pivote) #Elimina la columna por debajo del pivote\n", " eliminaColumna(A, Inver, pivote) #Elimina la columna por debajo del pivote\n",
" \n", " \n",
" #Eliminación de Gauss-Jordan hacia arriba\n", " #Eliminación de Gauss-Jordan hacia arriba\n",
" if verbosity: print('Ahora hacia arriba:')\n",
" for pivote in reversed(range(n)):\n", " for pivote in reversed(range(n)):\n",
" eliminaColumna(A, Inver, pivote, reverse=True) #Elimina la columna por arriba del pivote\n", " eliminaColumna(A, Inver, pivote, reverse=True) #Elimina la columna por arriba del pivote\n",
" return Inver\n", " return Inver\n",
...@@ -986,7 +987,7 @@ ...@@ -986,7 +987,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 10, "execution_count": 15,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
...@@ -1056,6 +1057,7 @@ ...@@ -1056,6 +1057,7 @@
" [-0. -0. -0. 1. 8. ]\n", " [-0. -0. -0. 1. 8. ]\n",
" [-0. -0. -0. 0. 1. ]] \n", " [-0. -0. -0. 0. 1. ]] \n",
"\n", "\n",
"Ahora hacia arriba:\n",
"Elimino Columna 5 :\n", "Elimino Columna 5 :\n",
" [[-1. -0. 0.5 -0.5 0. ]\n", " [[-1. -0. 0.5 -0.5 0. ]\n",
" [ 0. -1. 1.5 -2. 0. ]\n", " [ 0. -1. 1.5 -2. 0. ]\n",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment