<< Chapter < Page Chapter >> Page >
A short introduction to writing Content MathML by hand. It covers tokens, prefix notation, and applying functions and operators. Inaddition it introduces writing derivatives, integrals, vectors, and matrices.

The authoritative reference for Content MathML is Section 4 of the MathML 2.0 Specification . The World Wide Web Consortium (W3C) is the body that wrote the specification forMathML. The text is very readable and it is easy to find what you are looking for. Look there for answers to questions thatare not answered in this tutorial or when you need more elaboration. This tutorial is based on MathML 2.0.

In this document, the m prefix is used to denote tags in the MathML namespace. Thus the <apply> tag is referred to as <m:apply> . Remember all markup in the MathML namespace must be surrounded by <m:math> tags.

The fundamentals of content mathml: applying functions and operators

The fundamental concept to grasp about Content MathML is that it consists of applying a series of functions and operators toother elements. To do this, Content MathML uses prefix notation. Prefix notation is when the operator comes first and is followed by the operands. Here is how towrite "2 plus 3". <m:math> <m:apply> <m:plus/> <m:cn>2</m:cn> <m:cn>3</m:cn> </m:apply> </m:math> This would display as 2 3 .

There are three types of elements in the Content MathML example shown above. First, there is the apply tag, which indicates that an operator (or function) is about to be applied to the operands. Second, there is the functionor operator to be applied. In this case the operator, plus , is being applied. Third, the operands follow the operator. In this case the operands are thenumbers being added. In summary, the apply tag applies the function (which could be sin or f , etc.) or operator (which could be plus or minus, etc.) to the elements that follow it.

Tokens

Content MathML has three tokens: ci , cn , and csymbol . A token is basically the lowest level element. The tokens denote what kind of element you are acting on.The cn tag indicates that the content of the tag is a number. The ci tag indicates that the content of the tag is an identifier. An identifier could be any variable or function; x , y , and f are examples of identifiers. In addition, ci elements can contain Presentation MathML. Tokens, especially ci and cn , are used profusely in Content MathML. Every number, variable, or function is marked by a token.

csymbol is a different type of token from ci and cn . It is used to create a new object whose semantics is defined externally. It cancontain plain text or Presentation MathML. If you find that you need something, such as an operator or function, that isnot defined in Content MathML, then you can use csymbol to create it.

Both ci and csymbol can use Presentation MathML to determine how an identifier or a newsymbol will be rendered. To learn more about Presentation MathML see Section 3 of the MathML 2.0 Specification . For example, to denote " x with a subscript 2", where the 2 does not have a more semantic meaning, you woulduse the following code. <m:math> <m:ci> <m:msub> <m:mi>x</m:mi> <m:mn>2</m:mn> </m:msub> </m:ci> </m:math> This would display as x 2 .

Questions & Answers

what is biology
Hajah Reply
the study of living organisms and their interactions with one another and their environments
AI-Robot
what is biology
Victoria Reply
HOW CAN MAN ORGAN FUNCTION
Alfred Reply
the diagram of the digestive system
Assiatu Reply
allimentary cannel
Ogenrwot
How does twins formed
William Reply
They formed in two ways first when one sperm and one egg are splited by mitosis or two sperm and two eggs join together
Oluwatobi
what is genetics
Josephine Reply
Genetics is the study of heredity
Misack
how does twins formed?
Misack
What is manual
Hassan Reply
discuss biological phenomenon and provide pieces of evidence to show that it was responsible for the formation of eukaryotic organelles
Joseph Reply
what is biology
Yousuf Reply
the study of living organisms and their interactions with one another and their environment.
Wine
discuss the biological phenomenon and provide pieces of evidence to show that it was responsible for the formation of eukaryotic organelles in an essay form
Joseph Reply
what is the blood cells
Shaker Reply
list any five characteristics of the blood cells
Shaker
lack electricity and its more savely than electronic microscope because its naturally by using of light
Abdullahi Reply
advantage of electronic microscope is easily and clearly while disadvantage is dangerous because its electronic. advantage of light microscope is savely and naturally by sun while disadvantage is not easily,means its not sharp and not clear
Abdullahi
cell theory state that every organisms composed of one or more cell,cell is the basic unit of life
Abdullahi
is like gone fail us
DENG
cells is the basic structure and functions of all living things
Ramadan
What is classification
ISCONT Reply
is organisms that are similar into groups called tara
Yamosa
in what situation (s) would be the use of a scanning electron microscope be ideal and why?
Kenna Reply
A scanning electron microscope (SEM) is ideal for situations requiring high-resolution imaging of surfaces. It is commonly used in materials science, biology, and geology to examine the topography and composition of samples at a nanoscale level. SEM is particularly useful for studying fine details,
Hilary
cell is the building block of life.
Condoleezza Reply
Got questions? Join the online conversation and get instant answers!
Jobilize.com Reply

Get Jobilize Job Search Mobile App in your pocket Now!

Get it on Google Play Download on the App Store Now




Source:  OpenStax, Cnxml tutorial. OpenStax CNX. Jul 08, 2009 Download for free at http://cnx.org/content/col10121/1.10
Google Play and the Google Play logo are trademarks of Google Inc.

Notification Switch

Would you like to follow the 'Cnxml tutorial' conversation and receive update notifications?

Ask