summaryrefslogtreecommitdiff
path: root/Master/texmf-dist
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2023-02-08 21:01:00 +0000
committerKarl Berry <karl@freefriends.org>2023-02-08 21:01:00 +0000
commit567cf6938b059938837ddd3e5a4e8893e5dbe536 (patch)
tree5fd3cb901999b372a286682a68dda9eef51c4d13 /Master/texmf-dist
parent35670eff73db8009e4de2e843b88932510f90879 (diff)
resolsysteme (8feb23)
git-svn-id: svn://tug.org/texlive/trunk@65760 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist')
-rw-r--r--Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-doc.pdfbin123651 -> 132738 bytes
-rw-r--r--Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-doc.tex93
-rw-r--r--Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples-pyluatex.pdfbin95573 -> 98310 bytes
-rw-r--r--Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples-pyluatex.tex11
-rw-r--r--Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples.pdfbin134039 -> 138727 bytes
-rw-r--r--Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples.tex15
-rw-r--r--Master/texmf-dist/tex/latex/resolsysteme/ResolSysteme.sty145
7 files changed, 242 insertions, 22 deletions
diff --git a/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-doc.pdf b/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-doc.pdf
index 7e155db2164..9e5d8c6476d 100644
--- a/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-doc.pdf
+++ b/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-doc.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-doc.tex b/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-doc.tex
index 143dd663945..28b9e5b397a 100644
--- a/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-doc.tex
+++ b/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-doc.tex
@@ -3,8 +3,8 @@
% arara: lualatex: {shell: yes, synctex: no, interaction: batchmode} if found('log', '(undefined references|Please rerun|Rerun to get)')
\documentclass[a4paper,11pt]{article}
-\def\TPversion{0.1.1}
-\def\TPdate{7 Février 2023}
+\def\TPversion{0.1.2}
+\def\TPdate{8 Février 2023}
\usepackage[executable=python.exe]{pyluatex}
\usepackage[table,svgnames]{xcolor}
\usepackage{amsmath,amssymb}
@@ -133,7 +133,11 @@
\vspace{0.25cm}
-{$\blacktriangleright$~~Des commandes pour travailler sur des matrices carrées (2x2, 3x3 ou 4x4).}
+{$\blacktriangleright$~~Une commande pour afficher une matrice carrée (2x2, 3x3 ou 4x4) avec la syntaxe du package.}
+
+\smallskip
+
+{$\blacktriangleright$~~Des commandes pour calculer le déterminant et l'inverse de matrices carrées (2x2, 3x3 ou 4x4).}
\smallskip
@@ -145,7 +149,7 @@
\begin{center}
\begin{tcolorbox}[enhanced,colframe=ForestGreen,colback=lightgray!5,center,width=0.95\linewidth,drop fuzzy shadow=lightgray]
- Le \textbf{déterminant} de $A=\begin{pNiceMatrix} -1&{0,5} \\ \frac12&4 \end{pNiceMatrix}$ est
+ Le \textbf{déterminant} de $A=\begin{pNiceMatrix} -1&\frac12 \\ \frac12&4 \end{pNiceMatrix}$ est
$\det(A)=\DetMatrice[dec](-1,0.5 § 1/2,4)$.
\medskip
@@ -162,7 +166,7 @@
%\hfill{}\textit{Merci aux membres du groupe \faFacebook{} du \og Coin \LaTeX{} \fg{} pour leur aide et leurs idées !}
-%\hfill{}\textit{Merci à Denis Bitouzé et à Patrick Bideault pour leurs retours et idées !}
+\hfill{}\textit{Merci à Denis Bitouzé pour leurs retours et idées !}
\vfill
@@ -336,12 +340,65 @@ Les \textit{transformations} en fraction devraient pouvoir fonctionner avec des
\pagebreak
+\section{Affichage d'une matrice}
+
+\subsection{La commande}
+
+\begin{cautionblock}
+La première commande (matricielle) est dédiée à l'affichage d'une matrice \textbf{2x2} ou \textbf{3x3} ou \textbf{4x4} :
+
+\begin{itemize}
+ \item en saisissant les coefficients via une syntaxe propre au package (l'affichage est géré en interne par \textsf{nicematrix}) ;
+ \item en caclulant et convertissant éventuellement les coefficients sous forme de fraction (grâce à la commande précédente !).
+\end{itemize}
+\vspace*{-\baselineskip}\leavevmode
+\end{cautionblock}
+
+\begin{PresentationCode}{listing only}
+%commande disponible avec les deux versions, pyluatex ou non
+\AffMatrice(*)[option de formatage](matrice)
+\end{PresentationCode}
+
+\subsection{Utilisation}
+
+\begin{tipblock}
+Concernant cette commande, qui est à insérer dans un environnement \textit{math} :
+
+\begin{itemize}
+ \item la version \textit{étoilée} force l'écriture du signe \og $-$ \fg{} avant l'éventuelle fraction ;
+ \item le premier argument, \textit{optionnel} et entre \textsf{[...]} permet de spécifier un formatage du résultat :
+ \begin{itemize}
+ \item \Cle{t} pour l'affichage de la fraction en mode \textsf{tfrac} ;
+ \item \Cle{d} pour l'affichage de la fraction en mode \textsf{dfrac} ;
+ \item \Cle{n} pour l'affichage de la fraction en mode \textsf{nicefrac} ;
+ \item \Cle{dec} pour l'affichage du résultat en mode \texttt{décimal} (sans arrondi !) ;
+ \item \Cle{dec=k} pour l'affichage du résultat en mode \texttt{décimal} arrondi à $10^{-k}$ ;
+ \end{itemize}
+ \item le deuxième argument, \textit{optionnel} et entre \textsf{<...>} correspond aux \Cle{options} à passer à l'environnement \texttt{pNiceMatrix} ;
+ \item le troisième argument, \textit{obligatoire} et entre \textsf{(...)}, est quant à lui, la matrice donnée par ses coefficients \textsf{a11,a12,... § a21,a22,...} (syntaxe héritée de \texttt{sympy}).
+\end{itemize}
+\vspace*{-\baselineskip}\leavevmode
+\end{tipblock}
+
+\begin{PresentationCode}{}
+On considère les matrices $A=\AffMatrice(1,2 § 3,4)$
+et $B=\AffMatrice[n](-1,1/3,4 § 1/3,4,-1 § -1,0,0)$
+et $C=\AffMatrice(1,2,3,4 § 5,6,7,0 § 1,1,1,1 § 2,-3,-5,-6)$.
+\end{PresentationCode}
+
+\begin{PresentationCode}{}
+On considère la matrice
+$M=\AffMatrice*[d]<cell-space-limits=2pt>(1+1/4,0,3+4/5 § 0,1,-5/3 § 1/2,0.45,6/7)$.
+\end{PresentationCode}
+
+\pagebreak
+
\section{Calcul de déterminant}
\subsection{Introduction}
\begin{cautionblock}
-La première commande (matricielle) disponible est pour calculer le déterminant d'une matrice :
+La deuxième commande (matricielle) disponible est pour calculer le déterminant d'une matrice :
\begin{itemize}
\item \textbf{2x2} ou \textbf{3x3} pour le package \textit{classique} ;
@@ -380,35 +437,35 @@ Concernant cette commande, qui est à insérer dans un environnement \textit{mat
\begin{PresentationCode}{}
%version classique
-Le dét. de $A=\begin{pNiceMatrix}1&2\\3&4\end{pNiceMatrix}$ est
+Le dét. de $A=\AffMatrice(1,2 § 3,4)$ est
$\det(A)=\DetMatrice(1,2 § 3,4)$.
\end{PresentationCode}
\begin{PresentationCode}{}
%version classique
-Le dét. de $A=\begin{pNiceMatrix}-1&{0,5}\\\frac12&4\end{pNiceMatrix}$ est
+Le dét. de $A=\AffMatrice[dec](-1,0.5 § 1/2,4)$ est
$\det(A)=\DetMatrice[dec](-1,0.5 § 1/2,4)$.
\end{PresentationCode}
\begin{PresentationCode}{}
%version classique
-Le dét. de $A=\begin{pNiceMatrix}-1&\frac13&4\\\frac13&4&-1\\-1&0&0\end{pNiceMatrix}$ est
+Le dét. de $A=\AffMatrice*[t](-1,1/3,4 § 1/3,4,-1 § -1,0,0)$ est
$\det(A) \approx \DetMatrice[dec=3](-1,1/3,4 § 1/3,4,-1 § -1,0,0)$.
\end{PresentationCode}
\begin{PresentationCode}{}
%version python
-Le dé. de $A=\begin{pNiceMatrix}1&2\\3&4\end{pNiceMatrix}$ est
+Le dé. de $A=\AffMatrice(1,2 § 3,4)$ est
$\det(A)=\DetMatricePY(1,2 § 3,4)$.
\end{PresentationCode}
\begin{PresentationCode}{}
-Le dét. de $A=\begin{pNiceMatrix}-1&{0,5}\\\frac12&4\end{pNiceMatrix}$ est
+Le dét. de $A=\AffMatrice[dec](-1,0.5 § 1/2,4)$ est
$\det(A)=\DetMatricePY*[d](-1,0.5 § 1/2,4)$.\end{PresentationCode}
\begin{PresentationCode}{}
%version python
-Le dét. de $A=\begin{pNiceMatrix}-1&\frac13&4\\\frac13&4&-1\\-1&0&0\end{pNiceMatrix}$ est
+Le dét. de $A=\AffMatrice(-1,1/3,4 § 1/3,4,-1 § -1,0,0)$ est
$\det(A) \approx \DetMatricePY[dec=3](-1,1/3,4 § 1/3,4,-1 § -1,0,0)$.
\end{PresentationCode}
@@ -417,7 +474,7 @@ $\det(A) \approx \DetMatricePY[dec=3](-1,1/3,4 § 1/3,4,-1 § -1,0,0)$.
\subsection{Introduction}
\begin{cautionblock}
-La deuxième commande (matricielle) disponible est pour calculer l'éventuelle inverse d'une matrice :
+La troisième commande (matricielle) disponible est pour calculer l'éventuelle inverse d'une matrice :
\begin{itemize}
\item \textbf{2x2} ou \textbf{3x3} pour le package \textit{classique} ;
@@ -457,25 +514,25 @@ Concernant cette commande, qui est à insérer dans un environnement \textit{mat
\begin{PresentationCode}{}
%version classique
-L'inverse de $A=\begin{pNiceMatrix}1&2\\3&4\end{pNiceMatrix}$ est
+L'inverse de $A=\AffMatrice(1,2 § 3,4)$ est
$A^{-1}=\MatriceInverse<cell-space-limits=2pt>(1,2 § 3,4)$.
\end{PresentationCode}
\begin{PresentationCode}{}
%version classique
-L'inverse de $A=\begin{pNiceMatrix}1&2&3\\4&5&6\\7&8&8\end{pNiceMatrix}$ est
+L'inverse de $A=\AffMatrice(1,2,3 § 4,5,6 § 7,8,8)$ est
$A^{-1}=\MatriceInverse[n]<cell-space-limits=2pt>(1,2,3 § 4,5,6 § 7,8,8)$.
\end{PresentationCode}
\begin{PresentationCode}{}
%version python
-L'inverse de $A=\begin{pNiceMatrix}1&2\\3&4\end{pNiceMatrix}$ est
+L'inverse de $A=\AffMatrice(1,2 § 3,4)$ est
$A^{-1}=\MatriceInversePY*[d]<cell-space-limits=2pt>(1,2 § 3,4)$.
\end{PresentationCode}
\begin{PresentationCode}{}
%version python
-L'inv. de $A=\begin{pNiceMatrix}1&2&3&4\\5&6&7&0\\1&1&1&1\\-2&-3&-5&-6\end{pNiceMatrix}$ est
+L'inv. de $A=\AffMatrice(1,2,3,4 § 5,6,7,0 § 1,1,1,1 § -2,-3,-5,-6)$ est
$A^{-1}=
\MatriceInversePY*[n]<cell-space-limits=2pt>(1,2,3,4 § 5,6,7,0 § 1,1,1,1 § -2,-3,-5,-6)$.
\end{PresentationCode}
@@ -619,6 +676,8 @@ def inverse_matrice_TT(a,b,c,d,e,f,g,h,i) :
\part{Historique}
+\verb|v0.1.2|~:~~~~Ajout d'une commande d'affichage (formaté) d'une matrice 2x2, 3x3 ou 4x4
+
\verb|v0.1.1|~:~~~~Correction d'un bug avec le caractère \og ; \fg{}
\verb|v0.1.0|~:~~~~Version initiale
diff --git a/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples-pyluatex.pdf b/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples-pyluatex.pdf
index 3275b5262e7..2f1f0191c2e 100644
--- a/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples-pyluatex.pdf
+++ b/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples-pyluatex.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples-pyluatex.tex b/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples-pyluatex.tex
index c6439a053cd..7d891b08a52 100644
--- a/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples-pyluatex.tex
+++ b/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples-pyluatex.tex
@@ -1,6 +1,7 @@
% !TeX TXS-program:compile = txs:///lualatex/[--shell-escape]
\documentclass[french,a4paper,10pt]{article}
+\def\RSver{0.1.2}
\usepackage[margin=1.5cm]{geometry}
\usepackage[executable=python.exe]{pyluatex}
\usepackage[pyluatex]{ResolSysteme}
@@ -12,7 +13,7 @@
\begin{document}
-\part*{Version \og pyluatex \fg}
+\part*{ResolSysteme (\RSver), version \og pyluatex \fg{}}
\section{Préambule, avec le package pyluatex}
@@ -25,6 +26,14 @@
\sisetup{locale=FR,output-decimal-marker={,}}
\end{ShowCodeTeX}
+\section{Affichage d'une matrice, 2x2 ou 3x3 ou 4x4}
+
+\begin{ShowCodeTeX}
+On considère les matrices $A=\AffMatrice(1,2 § 3,4)$
+et $B=\AffMatrice*[n](-1,1/3,4 § 1/3,4,-1 § -1,0,0)$
+et $C=\AffMatrice(1,2,3,4 § 5,6,7,0 § 1,1,1,1 § 2,-3,-5,-6)$.
+\end{ShowCodeTeX}
+
\section{Inverse d'une matrice, 2x2 ou 3x3 ou 4x4}
\begin{ShowCodeTeX}
diff --git a/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples.pdf b/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples.pdf
index 2afa0bbc426..7a2d7f45760 100644
--- a/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples.pdf
+++ b/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples.tex b/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples.tex
index f9daeb9826c..2bf3f3b252b 100644
--- a/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples.tex
+++ b/Master/texmf-dist/doc/latex/resolsysteme/ResolSysteme-exemples.tex
@@ -2,6 +2,7 @@
% !TeX TXS-program:compile = txs:///pdflatex
\documentclass[french,a4paper,10pt]{article}
+\def\RSver{0.1.2}
\usepackage[margin=1.5cm]{geometry}
\usepackage{ResolSysteme}
\usepackage{systeme}
@@ -12,7 +13,7 @@
\begin{document}
-\part*{Version \og classique \fg{} avec xint}
+\part*{ResolSysteme (\RSver), version \og classique \fg{}}
\section{Préambule sans utiliser python}
@@ -24,15 +25,23 @@
\sisetup{locale=FR,output-decimal-marker={,}}
\end{ShowCodeTeX}
+\section{Affichage d'une matrice, 2x2 ou 3x3 ou 4x4}
+
+\begin{ShowCodeTeX}
+On considère les matrices $A=\AffMatrice(1,2 § 3,4)$
+et $B=\AffMatrice*[n](-1,1/3,4 § 1/3,4,-1 § -1,0,0)$
+et $C=\AffMatrice(1,2,3,4 § 5,6,7,0 § 1,1,1,1 § 2,-3,-5,-6)$.
+\end{ShowCodeTeX}
+
\section{Déterminant d'une matrice, 2x2 ou 3x3}
\begin{ShowCodeTeX}
-Le déterminant de $A=\begin{pNiceMatrix} 1&2 \\ 3&4 \end{pNiceMatrix}$ est
+Le déterminant de $A=\AffMatrice(1,2 § 3,4)$ est
$\det(A)=\DetMatrice(1,2 § 3,4)$.
\end{ShowCodeTeX}
\begin{ShowCodeTeX}
-Le déterminant de $A=\begin{pNiceMatrix} -1&{0,5} \\ \frac12&4 \end{pNiceMatrix}$ est
+Le déterminant de $A=\AffMatrice*(-1,0.5 § 1/2,4)$ est
$\det(A)=\DetMatrice[dec](-1,0.5 § 1/2,4)$.
\end{ShowCodeTeX}
diff --git a/Master/texmf-dist/tex/latex/resolsysteme/ResolSysteme.sty b/Master/texmf-dist/tex/latex/resolsysteme/ResolSysteme.sty
index 338e8b3d3c6..930cfd33e97 100644
--- a/Master/texmf-dist/tex/latex/resolsysteme/ResolSysteme.sty
+++ b/Master/texmf-dist/tex/latex/resolsysteme/ResolSysteme.sty
@@ -2,7 +2,8 @@
% licence........: Released under the LaTeX Project Public License v1.3c or later, see http://www.latex-project.org/lppl.txtf
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{ResolSysteme}[2023/02/07 v0.1.1 Travailler sur un systeme lineaire avec xint ou pyluatex]
+\ProvidesPackage{ResolSysteme}[2023/02/08 v0.1.2 Travailler sur un systeme lineaire avec xint ou pyluatex]
+% 0.1.2 Ajout pour afficher une matrice, à l'aide d'une syntaxe similaire aux autres commandes
% 0.1.1 Correction d'un bug avec le séparateur ";"
% 0.1.0 Version initiale
@@ -147,6 +148,148 @@ def inverse_matrice_TT(a,b,c,d,e,f,g,h,i) :
}%
}
+%------Affichage d'une matrice classique, 2x2 ou 3x3 ou 4x4
+\NewDocumentCommand\AffMatrice{ s O{} D<>{} r() }{%
+ %*=fractions avec - devant
+ %2=options conversion
+ %3=options nicematrix
+ %4=matrice (,,;,,)
+ %---------------------
+ %lectures des matrices
+ \setsepchar{§/,}%
+ \readlist*\MAMATRICEA{#4}%
+ %les coeffs de A et le déterminant et les coeff de l'inverse
+ \ifnum \MAMATRICEAlen=3
+ \itemtomacro\MAMATRICEA[1,1]\MatA
+ \itemtomacro\MAMATRICEA[1,2]\MatB
+ \itemtomacro\MAMATRICEA[1,3]\MatC
+ \itemtomacro\MAMATRICEA[2,1]\MatD
+ \itemtomacro\MAMATRICEA[2,2]\MatE
+ \itemtomacro\MAMATRICEA[2,3]\MatF
+ \itemtomacro\MAMATRICEA[3,1]\MatG
+ \itemtomacro\MAMATRICEA[3,2]\MatH
+ \itemtomacro\MAMATRICEA[3,3]\MatI
+ %les conversions
+ \IfBooleanTF{#1}%
+ {%
+ \def\MatAffA{\ConvVersFrac*[#2]{\MatA}}%
+ \def\MatAffB{\ConvVersFrac*[#2]{\MatB}}%
+ \def\MatAffC{\ConvVersFrac*[#2]{\MatC}}%
+ \def\MatAffD{\ConvVersFrac*[#2]{\MatD}}%
+ \def\MatAffE{\ConvVersFrac*[#2]{\MatE}}%
+ \def\MatAffF{\ConvVersFrac*[#2]{\MatF}}%
+ \def\MatAffG{\ConvVersFrac*[#2]{\MatG}}%
+ \def\MatAffH{\ConvVersFrac*[#2]{\MatH}}%
+ \def\MatAffI{\ConvVersFrac*[#2]{\MatI}}%
+ }%
+ {%
+ \def\MatAffA{\ConvVersFrac[#2]{\MatA}}%
+ \def\MatAffB{\ConvVersFrac[#2]{\MatB}}%
+ \def\MatAffC{\ConvVersFrac[#2]{\MatC}}%
+ \def\MatAffD{\ConvVersFrac[#2]{\MatD}}%
+ \def\MatAffE{\ConvVersFrac[#2]{\MatE}}%
+ \def\MatAffF{\ConvVersFrac[#2]{\MatF}}%
+ \def\MatAffG{\ConvVersFrac[#2]{\MatG}}%
+ \def\MatAffH{\ConvVersFrac[#2]{\MatH}}%
+ \def\MatAffI{\ConvVersFrac[#2]{\MatI}}%
+ }%
+ %l'affichage
+ \begin{pNiceMatrix}[#3]
+ {\MatAffA}&{\MatAffB}&{\MatAffC} \\
+ {\MatAffD}&{\MatAffE}&{\MatAffF} \\
+ {\MatAffG}&{\MatAffH}&{\MatAffI}
+ \end{pNiceMatrix}%
+ \fi
+ \ifnum \MAMATRICEAlen=2
+ \itemtomacro\MAMATRICEA[1,1]\MatA
+ \itemtomacro\MAMATRICEA[1,2]\MatB
+ \itemtomacro\MAMATRICEA[2,1]\MatC
+ \itemtomacro\MAMATRICEA[2,2]\MatD
+ %les conversions
+ \IfBooleanTF{#1}%
+ {%
+ \def\MatAffA{\ConvVersFrac*[#2]{\MatA}}%
+ \def\MatAffB{\ConvVersFrac*[#2]{\MatB}}%
+ \def\MatAffC{\ConvVersFrac*[#2]{\MatC}}%
+ \def\MatAffD{\ConvVersFrac*[#2]{\MatD}}%
+ }%
+ {%
+ \def\MatAffA{\ConvVersFrac[#2]{\MatA}}%
+ \def\MatAffB{\ConvVersFrac[#2]{\MatB}}%
+ \def\MatAffC{\ConvVersFrac[#2]{\MatC}}%
+ \def\MatAffD{\ConvVersFrac[#2]{\MatD}}%
+ }%
+ %l'affichage
+ \begin{pNiceMatrix}[#3]
+ {\MatAffA}&{\MatAffB} \\
+ {\MatAffC}&{\MatAffD}
+ \end{pNiceMatrix}%
+ \fi
+ \ifnum \MAMATRICEAlen=4
+ \itemtomacro\MAMATRICEA[1,1]\MatA
+ \itemtomacro\MAMATRICEA[1,2]\MatB
+ \itemtomacro\MAMATRICEA[1,3]\MatC
+ \itemtomacro\MAMATRICEA[1,4]\MatD
+ \itemtomacro\MAMATRICEA[2,1]\MatE
+ \itemtomacro\MAMATRICEA[2,2]\MatF
+ \itemtomacro\MAMATRICEA[2,3]\MatG
+ \itemtomacro\MAMATRICEA[2,4]\MatH
+ \itemtomacro\MAMATRICEA[3,1]\MatI
+ \itemtomacro\MAMATRICEA[3,2]\MatJ
+ \itemtomacro\MAMATRICEA[3,3]\MatK
+ \itemtomacro\MAMATRICEA[3,4]\MatL
+ \itemtomacro\MAMATRICEA[4,1]\MatM
+ \itemtomacro\MAMATRICEA[4,2]\MatN
+ \itemtomacro\MAMATRICEA[4,3]\MatO
+ \itemtomacro\MAMATRICEA[4,4]\MatP
+ %les conversions
+ \IfBooleanTF{#1}%
+ {%
+ \def\MatAffA{\ConvVersFrac*[#2]{\MatA}}%
+ \def\MatAffB{\ConvVersFrac*[#2]{\MatB}}%
+ \def\MatAffC{\ConvVersFrac*[#2]{\MatC}}%
+ \def\MatAffD{\ConvVersFrac*[#2]{\MatD}}%
+ \def\MatAffE{\ConvVersFrac*[#2]{\MatE}}%
+ \def\MatAffF{\ConvVersFrac*[#2]{\MatF}}%
+ \def\MatAffG{\ConvVersFrac*[#2]{\MatG}}%
+ \def\MatAffH{\ConvVersFrac*[#2]{\MatH}}%
+ \def\MatAffI{\ConvVersFrac*[#2]{\MatI}}%
+ \def\MatAffJ{\ConvVersFrac*[#2]{\MatJ}}%
+ \def\MatAffK{\ConvVersFrac*[#2]{\MatK}}%
+ \def\MatAffL{\ConvVersFrac*[#2]{\MatL}}%
+ \def\MatAffM{\ConvVersFrac*[#2]{\MatM}}%
+ \def\MatAffN{\ConvVersFrac*[#2]{\MatN}}%
+ \def\MatAffO{\ConvVersFrac*[#2]{\MatO}}%
+ \def\MatAffP{\ConvVersFrac*[#2]{\MatP}}%
+ }%
+ {%
+ \def\MatAffA{\ConvVersFrac[#2]{\MatA}}%
+ \def\MatAffB{\ConvVersFrac[#2]{\MatB}}%
+ \def\MatAffC{\ConvVersFrac[#2]{\MatC}}%
+ \def\MatAffD{\ConvVersFrac[#2]{\MatD}}%
+ \def\MatAffE{\ConvVersFrac[#2]{\MatE}}%
+ \def\MatAffF{\ConvVersFrac[#2]{\MatF}}%
+ \def\MatAffG{\ConvVersFrac[#2]{\MatG}}%
+ \def\MatAffH{\ConvVersFrac[#2]{\MatH}}%
+ \def\MatAffI{\ConvVersFrac[#2]{\MatI}}%
+ \def\MatAffJ{\ConvVersFrac[#2]{\MatJ}}%
+ \def\MatAffK{\ConvVersFrac[#2]{\MatK}}%
+ \def\MatAffL{\ConvVersFrac[#2]{\MatL}}%
+ \def\MatAffM{\ConvVersFrac[#2]{\MatM}}%
+ \def\MatAffN{\ConvVersFrac[#2]{\MatN}}%
+ \def\MatAffO{\ConvVersFrac[#2]{\MatO}}%
+ \def\MatAffP{\ConvVersFrac[#2]{\MatP}}%
+ }%
+ %l'affichage
+ \begin{pNiceMatrix}[#3]
+ {\MatAffA} & {\MatAffB} & {\MatAffC} & {\MatAffD} \\
+ {\MatAffE} & {\MatAffF} & {\MatAffG} & {\MatAffH} \\
+ {\MatAffI} & {\MatAffJ} & {\MatAffK} & {\MatAffL} \\
+ {\MatAffM} & {\MatAffN} & {\MatAffO} & {\MatAffP} \\
+ \end{pNiceMatrix}%
+ \fi
+}
+
%------Commande classique, 2x2 ou 3x3
\NewDocumentCommand\MatriceInverse{ s O{} D<>{} r() }{%
%*=fractions avec - devant