Ejercicio sobre rango de una matriz a partir de un parámetro y resolución de sistema lineal homogéneo

Muestro la forma de resolver otro ejercicio propuesto para este curso escolar en Andalucía del selectividad de 2º de bachillerato de ciencias. El ejercicio consiste en operar matrices, obtener los valores de un parámetro para que una matriz no tenga rango 3 y resolver un sistema lineal homogéneo compatible indeterminado.

Para realizar los gráficos se hace uso del paquete tikz y para las divisiones por Ruffini del paquete polynom de LaTeX.

El fichero LyX/pythontex permite que se pongan los datos de la matriz AA forma manual o bien que él solo genere los valores de forma aleatoria.

Lo único que tendremos que adecuar en el fichero es:

  • Valores mínimo y máximo entre los que obtener los números de la matriz AA

    # Valores entre los que obtener las raíces del polinomio
    # característico de la matriz M que obtenemos después
    rm = -4
    rM = 4
    
  • Opciones del programa

    # Podemos trabajar con dos opciones para la matriz A:
    # m --> Datos manuales
    # a --> Datos aleatorios
    # Si no ponemos que opción es "m" siempre se hace con datos aleatorios.
    opción = ''
    
    # Podemos optar por poner la matriz A de forma manual si optamos por opción='m'
    A=Matrix([[1,1,0],[1,0,1],[0,1,1]])
    

Con esos valores (se obtiene la matriz AA de forma aleatoria), un posible resultado de la compilación es:

Ejercicio

Dadas las matrices A=(413011110)A=\begin{pmatrix}4 & -1 & -3\\ 0 & 1 & -1\\ 1 & -1 & 0 \end{pmatrix} y B=(001010100)B=\begin{pmatrix}0 & 0 & 1\\ 0 & 1 & 0\\ 1 & 0 & 0 \end{pmatrix}, se define la matriz M=A+(λ1)BM=A+(\lambda-1)\cdot B

  1. Halla los valores λ\lambda de para los que la matriz MM tiene rango menor que 3.
  2. Para λ=1\lambda=-1 , resuelve el sistema lineal homogéneo cuya matriz de coeficientes es MM.

Solución

  1. Calculemos MM

    M=A+(λ1)B=(413011110)+(λ1)(001010100)=(413011110)+(00λ10λ10λ100)=(41λ40λ1λ10)M=A+(\lambda-1)\cdot B=\begin{pmatrix}4 & -1 & -3\\ 0 & 1 & -1\\ 1 & -1 & 0 \end{pmatrix}+(\lambda-1)\cdot\begin{pmatrix}0 & 0 & 1\\ 0 & 1 & 0\\ 1 & 0 & 0 \end{pmatrix}=\begin{pmatrix}4 & -1 & -3\\ 0 & 1 & -1\\ 1 & -1 & 0 \end{pmatrix}+\begin{pmatrix}0 & 0 & \lambda-1\\ 0 & \lambda-1 & 0\\ \lambda-1 & 0 & 0 \end{pmatrix}=\begin{pmatrix}4 & -1 & \lambda-4\\ 0 & \lambda & -1\\ \lambda & -1 & 0 \end{pmatrix}

    Regla de Sarrus: las diagonales azules se suman y las diagonales rojas se restan.

    image

    a1,1a1,2a1,3a2,1a2,2a2,3a3,1a3,2a3,3\left|\begin{matrix}a_{1,1} & a_{1,2} & a_{1,3}\\ a_{2,1} & a_{2,2} & a_{2,3}\\ a_{3,1} & a_{3,2} & a_{3,3}\end{matrix}\right| =(a11a22a33+a21a32a13+a31a12a23)(a13a22a31+a23a32a11+a33a12a21)={\big(a_{11}a_{22}a_{33}+a_{21}a_{32}a_{13}+a_{31}a_{12}a_{23}\big)- \big(a_{13}a_{22}a_{31}+a_{23}a_{32}a_{11}+a_{33}a_{12}a_{21}\big)}

    y su determinante:

    M=\left|M\right|=41λ40λ1λ10=\left|\begin{matrix}4 & -1 & \lambda-4\\ 0 & \lambda & -1\\ \lambda & -1 & 0 \end{matrix}\right|=

    Si añadimos las dos primeras filas debajo y aplicamos la regla de Sarrus

    41λ40λ1λ1041λ40λ1\begin{array}{c} \left|\begin{array}{ccc} 4 & -1 & \lambda-4\\ 0 & \lambda & -1\\ \lambda & -1 & 0 \end{array}\right|\\ \textcolor{cyan}{\begin{array}{ccc} 4 & -1 & \lambda-4\\ 0 & \lambda & -1 \end{array} } \end{array}

    =[4λ0+0(1)(λ4)+λ(1)(1)][(λ4)λλ+(1)(1)4+0(1)0]=\left[4\lambda0+0\left(-1\right)\left(\lambda-4\right)+\lambda\left(-1\right)\left(-1\right)\right]-\left[\left(\lambda-4\right)\lambda\lambda+\left(-1\right)\left(-1\right)4+0\left(-1\right)0\right]=(λ)(λ34λ2+4)=λ3+4λ2+λ4=\left(\lambda\right)-\left(\lambda^{3}-4\lambda^{2}+4\right)=-\lambda^{3}+4\lambda^{2}+\lambda-4

    Factorizamos por Ruffini, los divisores del término independiente son:

    ±{1,2,4}\pm\left\{ 1,2,4\right\}image

    \RightarrowM=λ3+4λ2+λ4=(λ4)(λ1)(λ+1)\left|M\right|=-\lambda^{3}+4\lambda^{2}+\lambda-4=-\left(\lambda-4\right)\left(\lambda-1\right)\left(\lambda+1\right)

    Por tanto, para λ={1,1,4}\lambda=\left\{ -1,1,4\right\} tenemos que M=0\left|M\right|=0\Rightarrow para esos valores rango(M)<3rango(M)<3

  2. Para λ=1\lambda=-1 la matriz M=(415011110)M=\begin{pmatrix}4 & -1 & -5\\ 0 & -1 & -1\\ -1 & -1 & 0 \end{pmatrix}. Y en forma de sistema lineal homogéneo quedaría {4xy5z=0yz=0xy=0\left\{ \begin{aligned}4x-y-5z & = & 0\\ -y-z & = & 0\\ -x-y & = & 0 \end{aligned} \right.

    Del sistema anterior sabemos:

    • El rango de su matriz de coeficientes es menor que 3 \Rightarrow el sistema no puede ser compatible y determinado.
    • Los sistemas lineales homogéneos son siempre compatibles.

    Por tanto, tenemos un sistema compatible indeterminado. Resolvámoslo por Gauss [1].

    Escribamos la matriz ampliada, si podemos la simplificamos:

    (415001101100){F1F3F2F2F3F1}(110001104150){F1F1F2F2F3F3}(110001104150){F1F1F2F2F34F1+F3}(110001100550){F1F1F2F2F3F35}(110001100110){F1F1F2F2F3F3}(110001100110){F1F1F2F2F3F2+F3}(110001100000)\left(\begin{matrix}4 & -1 & -5 & 0\\ 0 & -1 & -1 & 0\\ -1 & -1 & 0 & 0 \end{matrix}\right)\begin{Bmatrix}F_{1} & \leftrightarrows & F_{3}\\ F_{2} & \leftrightarrows & F_{2}\\ F_{3} & \leftrightarrows & F_{1} \end{Bmatrix}\longmapsto\left(\begin{matrix}-1 & -1 & 0 & 0\\ 0 & -1 & -1 & 0\\ 4 & -1 & -5 & 0 \end{matrix}\right)\begin{Bmatrix}F_{1} & \leftrightarrows & -F_{1}\\ F_{2} & \leftrightarrows & F_{2}\\ F_{3} & \leftrightarrows & F_{3} \end{Bmatrix}\longmapsto\left(\begin{matrix}1 & 1 & 0 & 0\\ 0 & -1 & -1 & 0\\ 4 & -1 & -5 & 0 \end{matrix}\right)\begin{Bmatrix}F_{1} & \leftrightarrows & F_{1}\\ F_{2} & \leftrightarrows & F_{2}\\ F_{3} & \leftrightarrows & -4F_{1}+F_{3} \end{Bmatrix}\longmapsto\left(\begin{matrix}1 & 1 & 0 & 0\\ 0 & -1 & -1 & 0\\ 0 & -5 & -5 & 0 \end{matrix}\right)\begin{Bmatrix}F_{1} & \leftrightarrows & F_{1}\\ F_{2} & \leftrightarrows & F_{2}\\ F_{3} & \leftrightarrows & \frac{F_{3}}{5} \end{Bmatrix}\longmapsto\left(\begin{matrix}1 & 1 & 0 & 0\\ 0 & -1 & -1 & 0\\ 0 & -1 & -1 & 0 \end{matrix}\right)\begin{Bmatrix}F_{1} & \leftrightarrows & F_{1}\\ F_{2} & \leftrightarrows & -F_{2}\\ F_{3} & \leftrightarrows & F_{3} \end{Bmatrix}\longmapsto\left(\begin{matrix}1 & 1 & 0 & 0\\ 0 & 1 & 1 & 0\\ 0 & -1 & -1 & 0 \end{matrix}\right)\begin{Bmatrix}F_{1} & \leftrightarrows & F_{1}\\ F_{2} & \leftrightarrows & F_{2}\\ F_{3} & \leftrightarrows & F_{2}+F_{3} \end{Bmatrix}\longmapsto\left(\begin{matrix}1 & 1 & 0 & 0\\ 0 & 1 & 1 & 0\\ 0 & 0 & 0 & 0 \end{matrix}\right)

    Resolviendo el sistema escalonado

    {x+y=0y+z=00=0\left\{ \begin{aligned}x+y & = & 0\\ y+z & = & 0\\ 0 & = & 0 \end{aligned} \right.

    se obtiene de solución: {x=τ0y=τ0z=τ0\left\{ \begin{aligned}x & = & \tau_{0}\\ y & = & -\tau_{0}\\ z & = & \tau_{0} \end{aligned} \right.   τ0R\ \ \tau_{0}\in\mathbb{R}

Enlaces al fichero fuente y al pdf final de una posible compilación.

[1]Aunque en la mayoría de los casos la solución se puede obtener de forma inmediata a partir de las ecuaciones de partida.