Maple Professionel
Maple Académique
Maple Edition Étudiant
Maple Personal Edition
Maple Player
Maple Player for iPad
MapleSim Professionel
MapleSim Académique
Maple T.A. - Suite d'examens de classement
Maple T.A. MAA Placement Test Suite
Möbius - Didacticiels de mathématiques en ligne
Machine Design / Industrial Automation
Aéronautique
Ingénierie des véhicules
Robotics
Energie
System Simulation and Analysis
Model development for HIL
Modélisation du procédé pour la conception de systèmes de contrôle
Robotics/Motion Control/Mechatronics
Other Application Areas
Enseignement des mathématiques
Enseignement de l’ingénierie
Enseignement secondaire et supérieur (CPGE, BTS)
Tests et évaluations
Etudiants
Modélisation financière
Recherche opérationnelle
Calcul haute performance
Physique
Webinaires en direct
Webinaires enregistrés
Agenda des évènements
Forum MaplePrimes
Blog Maplesoft
Membres Maplesoft
Maple Ambassador Program
MapleCloud
Livres blancs techniques
Bulletin électronique
Livres Maple
Math Matters
Portail des applications
Galerie de modèles MapleSim
Cas d'Etudes Utilisateur
Exploring Engineering Fundamentals
Concepts d’enseignement avec Maple
Centre d’accueil utilisateur Maplesoft
Centre de ressources pour enseignants
Centre d’assistance aux étudiants
Magma[Format] - format a magma as text for inclusion in a document
Calling Sequence
Format( m )
Format( m, options )
Parameters
m
-
a magma to format
options
zero or more options of the form format = fmt or labels = lbls.
Description
The Format command formats a magma (as an operation table) to a string in any one of several supported formats. This is meant to be a tool for including small magmas in documents such as papers, e-mail or web pages.
The formatted magma is returned as a string of text formatted using the selected format. You can use the printf command (with the %s conversion specifier) to print the string. Alternatively, the returned text may be written to a file.
Options
The format option is used to specify the output format desired. Its value may be chosen from among those shown in the following table.
text
plain text, the default
latex
formatted as a LaTeX table
html
formatted as an HTML table
mathml
formatted as a MathML table
wiki
formatted as a MediaWiki table
Use the labels option to specify names for the members of the magma other than small integers. The value of the labels option must be either a string, or a list of strings. If a string is provided, then its length must be equal to the order of the magma, and the individual characters in the string will be used as element names, in the order given. If a list of strings is provided, then the number of its members must be equal to the order of the magma, and each string in the list will be used as element names, in the order given. You can use markup within these strings consistent with the output format chosen. For example, a list of labels of the form [ "$a$", "$b$", "$c$" ] may be given for LaTeX output.
Compatibility
The Magma[Format] command was introduced in Maple 15.
For more information on Maple 15 changes, see Updates in Maple 15.
Examples
Create a small magma with five members to be formatted.
The default is to format the magma as plain text.
4 2 1 2 5 4 5 2 2 3 2 2 1 3 1 4 1 1 2 4 5 3 2 3 5
Use LaTeX to include the formatted magma in a paper or book.
\begin{smallmatrix}4&2&1&2&5\\ 4&5&2&2&3\\ 2&2&1&3&1\\ 4&1&1&2&4\\ 5&3&2&3&5 \end{smallmatrix}
Use HTML, MathML or MediaWiki for inclusion in a web page.
<table cols='5'> <tr><td>4</td><td>2</td><td>1</td><td>2</td><td>5</td></tr> <tr><td>4</td><td>5</td><td>2</td><td>2</td><td>3</td></tr> <tr><td>2</td><td>2</td><td>1</td><td>3</td><td>1</td></tr> <tr><td>4</td><td>1</td><td>1</td><td>2</td><td>4</td></tr> <tr><td>5</td><td>3</td><td>2</td><td>3</td><td>5</td></tr> </table>
<matrix><matrixrow><mn>4</mn><mn>2</mn><mn>1</mn><mn>2</mn><mn>5</mn></matrixrow><matrixrow><mn>4</mn><mn>5</mn><mn>2</mn><mn>2</mn><mn>3</mn></matrixrow><matrixrow><mn>2</mn><mn>2</mn><mn>1</mn><mn>3</mn><mn>1</mn></matrixrow><matrixrow><mn>4</mn><mn>1</mn><mn>1</mn><mn>2</mn><mn>4</mn></matrixrow><matrixrow><mn>5</mn><mn>3</mn><mn>2</mn><mn>3</mn><mn>5</mn></matrixrow></matrix>
{| border="1" |- |4 || 2 || 1 || 2 || 5 |- |4 || 5 || 2 || 2 || 3 |- |2 || 2 || 1 || 3 || 1 |- |4 || 1 || 1 || 2 || 4 |- |5 || 3 || 2 || 3 || 5 |}
Display the magma using letters instead of small integers for its elements.
d b a b e d e b b c b b a c a d a a b d e c b c e
\begin{smallmatrix}$d$&$b$&$a$&$b$&$e$\\$d$&$e$&$b$&$b$&$c$\\$b$&$b$&$a$&$c$&$a$\\$d$&$a$&$a$&$b$&$d$\\$e$&$c$&$b$&$c$&$e$ \end{smallmatrix}
See Also
Magma RandomMagma
Download Help Document