diff --git "a/Chapitre 9 - Produits scalaires et espaces euclidens/9.6-9.7 Comment trouver une base orthogonale au orthonormale - Le proc\303\251d\303\251 de Gram-Schmidt.ipynb" "b/Chapitre 9 - Produits scalaires et espaces euclidens/9.6-9.7 Comment trouver une base orthogonale au orthonormale - Le proc\303\251d\303\251 de Gram-Schmidt.ipynb" index 571cc95..5e1a04e 100644 --- "a/Chapitre 9 - Produits scalaires et espaces euclidens/9.6-9.7 Comment trouver une base orthogonale au orthonormale - Le proc\303\251d\303\251 de Gram-Schmidt.ipynb" +++ "b/Chapitre 9 - Produits scalaires et espaces euclidens/9.6-9.7 Comment trouver une base orthogonale au orthonormale - Le proc\303\251d\303\251 de Gram-Schmidt.ipynb" @@ -1,82 +1,120 @@ { "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ - "# **Concept(s)-clé(s) et théorie**" + "# **Concept(s)-clé(s) et théorie**\n", + "\n", + "## Proposition 1\n", + "Soient $V$ un $\\mathbb{R}$-espace vectoriel muni d'un produit scalaire $\\langle \\cdot,\\cdot\\rangle$ et $S = \\{v_1, \\dots, v_k\\} \\subset V$ une famille orthogonale de vecteurs non-nuls. Alors $S$ est une famille libre.\n", + "\n", + "## Définition 1\n", + "Soit $V$ un $\\mathbb{R}$-espace vectoriel muni d'un produit scalaire $\\langle \\cdot,\\cdot\\rangle$. Pour $u,v \\in V$, on définit la **projection orthogonale de $u$ sur $v$** par $$ proj_v u = \\dfrac{\\langle u,v \\rangle}{\\langle v,v \\rangle} v = \\dfrac{\\langle u,v \\rangle}{||v||^2}v$$\n", + "\n", + "## Proposition 2\n", + "Soit $V$ un $\\mathbb{R}$-espace vectoriel muni d'un produit scalaire $\\langle \\cdot,\\cdot\\rangle$. Alors les affirmations suivantes sont vérifiée:\n", + "\n", + "1. Pour tous $u,v \\in V$ le vecteur $proj_v u \\in V$ appartient à $Vect(\\{v\\})$\n", + "2. Pour tous $u,v \\in V$, on a $\\langle u - proj_v u, v \\rangle = 0$\n", + "\n", + "## Théorème 1: Procédé de Gram-Schmidt\n", + "Soient $V$ un $\\mathbb{R}$-espace vectoriel muni d'un produit scalaire $\\langle \\cdot,\\cdot \\rangle$ et $S = \\{x_1, \\dots, x_k\\}$ une famille de vecteurs dans $V$. Alors en posant successivement\n", + "\\begin{equation}\n", + "\\begin{aligned}\n", + "v_1 &= x_1 \\\\\n", + "v_2 &= x_2 - proj_{v_1}x_2 \\\\\n", + "v_3 &= x_3 - proj_{v_1}x_3 - proj_{v_2}x_3 \\\\\n", + "\\vdots & \\qquad \\\\\n", + "v_k &= x_k - proj_{v_1}x_k - proj_{v_2}x_k - \\cdots - proj_{v_{k-1}}x_k\n", + "\\end{aligned}\n", + "\\end{equation}\n", + "la famille $\\{v_1, \\dots, v_k\\}$ ainsi obtenue est une famille orthogonale.\n", + "\n", + "## Théorème 2: Proprietes du procédé de Gram-Schmidt\n", + "Soient $V$ un $\\mathbb{R}$-espace vectoriel muni d'un produit scalaire $\\langle \\cdot,\\cdot \\rangle$ et $S = \\{x_1, \\dots, x_k\\}$ une famille de vecteurs *linéarment indépentants* dans $V$. La procédé de Gram-Schmidt applique à la famille $S$ définit une suite de vecteurs $v_1, \\dots v_k$ telle que $\\{v_1, \\dots, v_k\\}$ est une famille de vecteurs deux-à-deux ortogonaux, non-nuls et donc linéarment indédendants. De plus, on a $$ Vect(S) = Vect(v_1, \\dots, v_k)$$\n", + "\n", + "## Remarque 1\n", + "1. Si $\\{x_1, \\dots, x_k\\}$ est une base de $V$, le procédé de Gram-Schmidt donne une base orthogonale $\\{v_1,\\dots, v_k\\}$ de $V$.\n", + "2. Si l'on souhaite avoir une base orthonormale de $V$, il suffit de normaliser la base obtenue." ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "# Exercises et Exemples" ] }, { "cell_type": "code", - "execution_count": 1, + "execution_count": null, "metadata": {}, - "outputs": [ - { - "data": { - "text/html": [ - " \n", - " " - ] - }, - "metadata": {}, - "output_type": "display_data" - } - ], + "outputs": [], "source": [ "import Librairie.AL_Fct as al\n", "import Corrections.corrections as corrections\n", "import numpy as np" ] }, { - "cell_type": "code", - "execution_count": null, + "cell_type": "markdown", "metadata": {}, - "outputs": [], - "source": [] + "source": [ + "## Exercice 1\n", + "\n", + "Choose different vector spaces $V$ ($\\mathbb{R}^2$, $\\mathbb{R}^3$, $\\mathbb{R}^5$, $\\mathbb{P}^3(\\mathbb{R})$) with associated inner products (standard!). Give two elements $u,v \\in V$ and ask to compute the projection of $u$ over $v$; enrich with plots if possible. Verify orthogonality --> if wrong show that it cannot be the projection because orthogonality does not occur." + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Exercice 2\n", + "\n", + "Interactive Gram-Schmidt process in $\\mathbb{R}^3$. Give a family of vectors. Ask the user to insert the coefficients of the projections (step by step). If the value is right, display the \"status\" in a plot and go on; if the value is wrong, display again the \"status\" to show that something is wrong and ask the user to insert the value again.\n", + "\n", + "Show that the order in which the vectors are chosen is not important! Show that, if the vectors are linearly dependent, then the result of GS will contain at least one null element." + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Exercise 3\n", + "\n", + "Interactive Gram-Schmidt in $\\mathbb{P}^3(\\mathbb{R})$. It works as in $\\mathbb{R}^3$, but at each step a plot of the functions is returned. We can do it in $[-1;1]$ so that the Legendre basis is derived." + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Exercise 4\n", + "\n", + "Same as on the MOOC. Give an underdetermined system / rank deficient matrix; compute a basis for its kernel; from it, apply GS to derive an orthogonal/orthonormal basis; finally compute the coordinates of an \"extra\" element with respect to such basis." + ] } ], "metadata": { "kernelspec": { "display_name": "Python 3", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.7.4" } }, "nbformat": 4, "nbformat_minor": 4 }