Home About us Products Services Contact us Bookmark
:: wikimiki.org ::
Division (mathematics)

Division (mathematics)

:This article is about the arithmetic operation. For other uses, see Division (disambiguation). In mathematics, especially in elementary arithmetic, division is an arithmetic operation which is the inverse of multiplication, and sometimes it can be interpreted as repeated subtraction. Specifically, if :c \times b = a where b is not zero, then :\frac ab = c that is, a divided by b equals c. For instance, \frac 63 = 2 since 2 \times 3 = 6\,. In the above expression, a is called the dividend, b the divisor and c the quotient. Division by zero (i.e. where the divisor is zero) is usually not defined.

Notation

Division is most often shown by placing the dividend over the divisor with a horizontal line between them. For example, a divided by b is written \frac ab. This can be read out loud as "a divided by b". A way to express division all on one line is to write the dividend, then a slash, then the divisor, like this: a/b\,. This is the usual way to specify division in most computer programming languages since it can easily be typed as a simple sequence of characters. A typographical variation which is halfway between these two forms uses a slash but elevates the dividend, and lowers the divisor: ab Any of these forms can be used to display a fraction. A fraction is a division expression where both dividend and divisor are integers (although typically called the numerator and denominator), and there is no implication that the division needs to be evaluated further. A less common way to show division is to use the obelus (or division sign) in this manner: a \div b. This form is infrequent except in elementary arithmetic. The obelus is also used alone to represent the division operation itself, as for instance as a label on a key of a calculator. In some non-English-speaking cultures, "a divided by b" has sometimes been written a : b. However, in English usage the colon is restricted to expressing the related concept of ratios.

Computing division

With a knowledge of multiplication tables, two integers can be divided on paper using the method of long division. If the dividend has a fractional part (expressed as a decimal fraction), one can continue the algorithm past the ones place as far as desired. If the divisor has a fractional part, one can restate the problem by moving the decimal to the right in both numbers until the divisor has no fraction. Division can be calculated with an abacus by repeatedly placing the dividend on the abacus, and then subtracting the divisor the offset of each digit in the result, counting the number of divisions possible at each offset. In modular arithmetic, some numbers have a multiplicative inverse with respect to the modulus. In such a case, division can be calculated by multiplication. This approach is useful in computers that do not have a fast division instruction.

Division of integers

Division of integers is not closed. Apart from division by zero being undefined, the quotient will not be an integer unless the dividend is an integer multiple of the divisor; for example 26 cannot be divided by 10 to give an integer. In such a case there are four possible approaches. # Say that 26 cannot be divided by 10. # Give the answer as a decimal fraction or a mixed number, so \frac = 2.6 or 26/10 = 2 \frac 35. This is the approach usually taken in mathematics. # Give the answer as a quotient and a remainder, so \frac = 2 remainder 6. # Give the quotient as the answer, so \frac = 2. This is sometimes called integer division. One has to be careful when performing division of integers in a computer program. Some programming languages, such as C, will treat division of integers as in case 4 above, so the answer will be an integer. Other languages, such as MATLAB, will first convert the integers to real numbers, and then give a real number as the answer, as in case 2 above.

Division of rational numbers

The result of dividing two rational numbers is another rational number when the divisor is not 0. We may define division of two rational numbers p/q and r/s by : = (p \times s)/(q \times r). All four quantities are integers, and only p may be 0. This definition ensures that division is the inverse operation of multiplication.

Division of real numbers

Division of two real numbers results in another real number when the divisor is not 0. It is defined such a/b = c if and only if a = cb and b ≠ 0.

Division of complex numbers

Dividing two complex numbers results in another complex number when the divisor is not 0, defined thus: : = + i. All four quantities are real numbers. r and s may not both be 0. Division for complex numbers expressed in polar form is simpler and easier to remember than the definition above: : = e^. Again all four quantities are real numbers. r may not be 0.

Division of polynomials

One can define the division operation for polynomials. Then, as in the case of integers, one has a remainder. See polynomial long division.

Division in abstract algebra

In abstract algebras such as matrix algebras and quaternion algebras, fractions such as are typically defined as a \cdot or a \cdot b^ where b is presumed to be an invertible element (i.e. there exists a multiplicative inverse b^ such that bb^ = b^b = 1 where 1 is the multiplicative identity). In an integral domain where such elements may not exist, division can still be performed on equations of the form ab = ac or ba = ca by left or right cancellation, respectively. More generally "division" in the sense of "cancellation" can be done in any ring with the aforementioned cancellation properties. By a theorem of Wedderburn, all finite division rings are fields, hence every nonzero element of such a ring is invertible, so division by any nonzero element is possible in such a ring. To learn about when algebras (in the technical sense) have a division operation, refer to the page on division algebras. In particular Bott periodicity can be used to show that any real normed division algebra must be isomorphic to either the real numbers R, the complex numbers C, the quaternions H, or the octonions O.

Division and calculus

The derivative of the quotient of two functions is given by the quotient rule: :' = \frac There is no general method to integrate the quotient of two functions.

See also


- Division (electronics)
- Rational number
- Vulgar fraction
- Reciprocal
- Inverse element
- Division by two
- Division by zero
- Quasigroup
- Group
- Field (algebra)
- Division algebra
- Division ring
- Long division
- Vinculum

External links


- [http://www.mathsisfun.com/dividing-decimals.html Method for Dividing Decimals]
-
- [http://webhome.idirect.com/~totton/abacus/pages.htm#Division1 Division on a Japanese abacus] selected from [http://webhome.idirect.com/~totton/abacus/ Abacus: Mystery of the Bead]
- [http://webhome.idirect.com/~totton/suanpan/sh_div/ Chinese Short Division Techniques on a Suan Pan] Category:Elementary arithmetic Category:Arithmetic ja:除法 simple:Division th:การหาร

Division (disambiguation)

Division may mean:
- Division (mathematics), the opposite operation to multiplication.
- Division (electronics), digital implementation of Division (mathematics).
- Division (military), a unit typically consisting of from 10,000 to 20,000 troops.
- Division (sport), a group of comparable teams in organised sport who compete amongst themselves for a Divisional title.
- Division (botany), a classification of plants (the botanical counterpart to zoology's phylum).
- Division (vote), a manner by which the votes of legislators are recorded.
- Division (organisation), a subsidiary of a larger organisation.
- Division (subnational entity), a subnational entity similar to a state or perfecture.
- Cell division, the process in which biological cells multiply.
- A county constituency or Parliamentary seat in the United Kingdom Parliament.
- A subpart of a hundred (division), former administrative unit in England and Wales.
- Police division, a large territorial unit (now often referred to as a Basic Command Unit) of the British police.
- Segmentation (disambiguation)
- Continental divide, the geographical term for separation between land masses.
- North-South divide, the geopolitical term for the division between wealthy nations and poor nations.
- In pipe organs a division is a grouping of pipe ranks, often with its own case, windchest, and keyboard.

Arithmetic

Arithmetic or arithmetics (from the Greek word αριθμός = number) in common usage is a branch of (or the forerunner of) mathematics which records elementary properties of certain operations on numerals, though in usage by professional mathematicians, it often is treated as a synonym for number theory. It is the oldest and simplest branch of mathematics, used widely by almost everyone from simple daily counting to more advanced science and business.

Arithmetic operations

The traditional arithmetic operations are addition, subtraction, multiplication and division, although more advanced operations (such as manipulations of percentages, square root, exponentiation, and logarithmic functions) are also sometimes included in this subject. Arithmetic is performed according to an order of operations. The arithmetic of natural numbers, integers, rational numbers (in the form of vulgar fractions), and real numbers (using the decimal place-value system known as algorism) is typically studied by schoolchildren, who learn manual algorithms for arithmetic. However, in adult life, many people prefer to use tools such as calculators, computers, or the abacus to perform the more complex arithmetical computations.

Number theory

The term arithmetic is also used to refer to number theory. This includes the properties of integers related to primality, divisibility, and the solution of equations by integers, as well as modern research which is an outgrowth of this study. It is in this context that one runs across the fundamental theorem of arithmetic and arithmetic functions. A Course in Arithmetic by Serre reflects this usage, as do such phrases as first order arithmetic or arithmetical algebraic geometry.

See also


- addition in N
- additive inverse
- associativity
- commutativity
- distributivity
- elementary arithmetic
- finite field arithmetic
- number line
- Important publications in arithmetic
- Arithmetic coding Category:Arithmetic ja:算数 simple:Arithmetic th:เลขคณิต

Multiplication

:This article is about multiplication in mathematics. For multiplication in music, see multiplication (music). In its simplest form, multiplication is the sum of a list of identical numbers. For example, the product 7 × 4 is 7 + 7 + 7 + 7. The numbers being multiplied are called the multiplicand and multiplier or the factors.

Notation

Multiplication can be denoted in several equivalent ways. All of the following mean, "5 times 2": :5×2 :5·2 :(5)2, 5(2), (5)(2), 5[2], [5]2, [5][2] :5
- 2 The asterisk (
- ) is often used on computers because it is a symbol on every keyboard, but it is rarely used when writing math by hand. This usage originated in the FORTRAN programming language. Frequently, multiplication is implied by Juxtaposition rather than shown in a notation. This is standard in algebra, taking forms like :5x and xy This is potentially confusing if variables are permitted to have names longer than one letter. The notation is not used with numbers alone: 52 never means 5 × 2. If the terms are not written out individually, then the product may be written with an ellipsis to mark out the missing terms, as with other series operations (like sums). Thus, the product of all the natural numbers from 1 to 100 can be written 1 \cdot 2 \cdot \ldots \cdot 99 \cdot 100. This can also be written with the ellipsis vertically placed in the middle of the line, as 1 \cdot 2 \cdot \cdots \cdot 99 \cdot 100. Alternatively, the product can be written with the product symbol, which derives from the capital letter Π (Pi) in the Greek alphabet. This is defined as: : \prod_^ x_ := x_ \cdot x_ \cdot x_ \cdot \cdots \cdot x_ \cdot x_. The subscript gives the symbol for a dummy variable (i in our case) and its lower value (m); the superscript gives its upper value. So for example: : \prod_^ \left(1 + \right) = \left(1 + \right) \cdot \left(1 + \right) \cdot \left(1 + \right) \cdot \left(1 + \right) \cdot \left(1 + \right) = . One may also consider products of infinitely many terms; these are called infinite products. Notationally, we would replace n above by the infinity symbol (∞). The product of such a series is defined as the limit of the product of the first n terms, as n grows without bound. That is: : \prod_^ x_ := \lim_ \prod_^ x_. One can similarly replace m with negative infinity, and :\prod_^\infty x_i := \left(\lim_\prod_^m x_i\right) \cdot \left(\lim_\prod_^n x_i\right), for some integer m, provided both limits exist.

Definition

As for what multiplication means, the product of two whole numbers n and m is: :mn := \sum_^n m This is just a shorthand for saying, "Add m to itself n times." Expanding the above to make its meaning more clear: :m × n = m + m + m + ... + m such that there are n m's added together. So for instance:
  • 5 × 2 = 5 + 5 = 10
  • 2 × 5 = 2 + 2 + 2 + 2 + 2 = 10
  • 4 × 3 = 4 + 4 + 4 = 12
  • m × 6 = m + m + m + m + m + m
Using this definition, it is easy to prove some interesting properties of multiplication. As the first two examples above hint at, the order in which two numbers are multiplied does not matter. This is called the commutative property and it turns out to be true in general that for any two numbers x and y, :x · y = y · x. Multiplication also has what is called the associative property. The associative property means that for any three numbers x, y, and z, :(x · y)z = x(y · z). Note from algebra: the parentheses mean that the operations inside the parentheses must be done before anything outside the parentheses is done. Multiplication also has what is called a distributive property with respect to the addition, because :x(y + z) = xy + xz. Also of interest is that any number times 1 is equal to itself, thus, :1 · x = x. and this is called the identity property What about zero? Well, we have: :m · 0 = m + m + m +...+ m where there are zero m's added together. The sum of zero m's is zero, so :m · 0 = 0 no matter what m is (as long as it is finite). Multiplication with negative numbers also requires a little thought. First consider negative 1. For any positive integer m: :(−1)m = (−1) + (−1) +...+ (−1) = −m This is an interesting fact that shows that any negative number is just negative one multiplied by a positive number. So multiplication with any integers can be represented by multiplication of whole numbers and (−1)'s. All that remains is to explicitly define (−1)(−1): :(−1)(−1) = −(−1) = 1 In this way, the multiplication of any two integers is defined. The definitions can be extended to larger and larger sets of numbers: first to vulgar fractions called the rational numbers, then to infinitely long decimals called real numbers, and then to the complex numbers. Students are sometimes mystified when told that the result of multiplying no numbers is 1. A formal recursive definition of multiplication can be given by the rules: : x · 0 = 0 : x · y = x + x·(y − 1) where x is a real number, and y is a natural number. Once multiplication has been defined for natural numbers, it can be extended to include integers, and then to real and complex numbers.

Computation

For fast ways to compute products of large numbers, see multiplication algorithms. Some algorithms are suitable for multiplying numbers using pencil and paper. Most, such as lattice multiplication, require a multiplication table of memorized or consulted products of small numbers (typically any two numbers from 0 to 9); the peasant multiplication algorithm does not.

See also


- Peasant multiplication
- reciprocal
- tables of multiplication
- Product (mathematics) - lists generalizations

External links


- [http://www.cut-the-knot.org/do_you_know/multiplication.shtml Multiplication] at cut-the-knot
- [http://www.mathsisfun.com/multiplying-negatives.html Multiplying Negative Numbers]
- [http://www.cut-the-knot.org/blue/SysTable.shtml Arithmetic Operations In Various Number Systems] at cut-the-knot
- [http://webhome.idirect.com/~totton/abacus/pages.htm#Multiplication1 Multiplication on a Japanese abacus] selected from [http://webhome.idirect.com/~totton/abacus/ Abacus: Mystery of the Bead]
- [http://webhome.idirect.com/~totton/suanpan/mod_mult/ Modern Chinese Multiplication Techniques on an Abacus] Category:Elementary arithmetic ko:곱셈 ja:乗法 simple:Multiplication th:การคูณ

0 (number)

:This page is about the number and numeral 0. For other uses of 0 or "zero", see 0 (disambiguation) 0 (zero), alternatively called naught or nought, is both a number and a numeral. It was the last numeral to be created in most numerical systems, as it is not a counting number (which is to say, one begins counting at the number 1) and was in many eras and places represented only by a gap or mark very different from the other numerals.

0 as a number

0 is the integer that precedes the positive 1, and all positive integers, and follows -1, and all negative integers. In most (if not all) numerical systems, 0 was identified before the idea of 'negative integers' was accepted. Zero is a number which means nothing, null, void or an absence of value. For example, if the number of one's brothers is zero, then that person has no brothers. If the difference between the number of pieces in two piles is zero, it means the two piles have an equal number of pieces. Almost all historians omit the year zero from the proleptic Gregorian and Julian calendars, but astronomers include it in these same calendars. However, the phrase Year Zero may be used to describe any event considered so significant that it virtually starts a new time reckoning.

0 as a numeral

Year Zero The modern numeral 0 is normally written as a circle or (rounded) rectangle. On the seven-segment displays of calculators, watches, etc., 0 is usually written with six line segments (at right), though on some historical calculator models it was written with four line segments. This variant glyph has not caught on. It is important to distinguish the number zero (as in the "zero brothers" example above) from the numeral or digit zero, used in numeral systems where the position of a digit signifies its value. Successive positions of digits have higher values, so the digit zero is used to skip a position and give appropriate value to the preceding and following digits. The Babylonian numeral system used two narrow slanting wedges, similar to \\, for the equivalent of a positional zero numeral starting in about 400BC. A zero digit is not always necessary in a positional number system: decimal without a zero provides a possible counterexample. In fonts with text figures, 0 is usually the same height as a lowercase X, for example, Image:TextFigs036.png.

History

Etymology

The word zero comes ultimately from the Arabic sifr (صفر) meaning empty or vacant, a literal translation of the Sanskrit meaning void or empty. Through transliteration this became zephyr or zephyrus in Latin. The word zephyrus already meant "west wind" in Latin; the proper noun Zephyrus was the Roman god of the west wind (after the Greek god Zephyros). With its new use for the concept of zero, zephyr came to mean a light breeze—"an almost nothing" (Ifrah 2000; see References). The word zephyr survives with this meaning in English today. The Italian mathematician Fibonacci (c.1170-1250), who grew up in Arab North Africa and is credited with introducing the Arabic decimal system to Europe, used the term zephyrum. This became zefiro in Italian, which was contracted to zero in the Venetian dialect, giving the modern English word. As the decimal zero and its new mathematics spread through a Europe that was still in the Middle Ages, words derived from sifr and zephyrus came to refer to calculation, as well as to privileged knowledge and secret codes. According to Ifrah (2000), "in thirteenth-century Paris, a 'worthless fellow' was called a... cifre en algorisme, i.e., an 'arithmetical nothing.' " (algorithm is also a borrowing from the Arabic, in this case from the name of the 9th-century mathematician al-Khwarizmi.) The Arabic root gave rise to the modern French chiffre, which means digit, figure, or number; chiffrer, to calculate or compute; and chiffré, encrypted; as well as to the English word cipher. Today, the word in Arabic is still sifr, and cognates of sifr are common throughout the languages of Europe. A few additional examples follow.
- Polish: cyfra, digit; szyfrować, to encrypt
- German: Ziffer, digit, figure, numeral, cypher
- French: zéro, zero
- Spanish: cifra, figure, numeral, cypher, code; cero, zero
- Swedish: siffra, numeral, sum, digit Note that zero in Greek is translated as Μηδέν (Meithen).

Babylonians and Greeks

By the mid second millennium BC, Babylonians had a sophisticated sexagesimal positional numeral system. The lack of a positional value (or zero) was indicated by a space between sexagesimal numerals. By 300 BC a punctuation symbol (two slanted wedges) was co-opted as a placeholder in the same Babylonian system. However, "... a tablet found at Kish ... thought to date from around 700 BC, uses three hooks to denote an empty place in the positional notation. Other tablets dated from around the same time use a single hook for an empty place" ([http://www-history.mcs.st-and.ac.uk/history/HistTopics/Zero.html] and natural number). Records show that the Ancient Greeks seemed unsure about the status of zero as a number: they asked themselves "how can 'nothing' be something?", leading to interesting philosophical and, by the Medieval period, religious arguments about the nature and existence of zero and the vacuum. The paradoxes of Zeno of Elea depend in large part on the uncertain interpretation of zero. (The ancient Greeks even questioned that 1 was a number.)

First use of the number

An early use of zero by the Indian mathematician Pingala (possibly 5th-3rd century BC), implied at first glance by [http://home.ica.net/~roymanju/Binary.htm Binary Numbers in Ancient India], is only the modern binary representation using 0 and 1 of Pingala's binary system, which used short and long syllables (the latter equal in length to two short syllables) as described in [http://www.sju.edu/~rhall/Rhythms/Poets/arcadia.pdf Math for Poets and Drummers] (pdf), making it similar to Morse code. In Pingala's system, four short syllables meant one, not zero. Nevertheless, he does use the Sanskrit word Shunya to refer to the concept of void, which was fairly similar to the concept of zero [http://sunsite.utk.edu/math_archives/.http/hypermail/historia/apr99/0197.html]. The late Olmec people of south-central Mexico began to use a true zero (a shell glyph) in the New World possibly by the 4th century BC but certainly by 40 BC, which became an integral part of Maya numerals, but did not influence Old World numeral systems. By 130, Ptolemy, influenced by Hipparchus and the Babylonians, was using a symbol for zero (a small circle with a long overbar) within a sexagesimal numeral system otherwise using alphabetic Greek numerals. Because it was used alone, not as just a placeholder, this Hellenistic zero was the first documented use of a true zero in the Old World. In later Byzantine manuscripts of his Syntaxis Mathematica (Almagest), the Hellenistic zero had morphed into the Greek letter omicron (otherwise meaning 70). Another true zero was used in tables alongside Roman numerals by 525 (first known use by Dionysius Exiguus), but as a word, nulla meaning nothing, not as a symbol. When division produced zero as a remainder, nihil, also meaning nothing, was used. These medieval zeros were used by all future medieval computists (calculators of Easter). An isolated use of their initial, N, was used in a table of Roman numerals by Bede or a colleague about 725, a true zero symbol.

Zero as a decimal digit

The earliest known decimal digit zero is thought to have been introduced by Indian mathematicians sometime around the 3rd century. It was written in the shape of a dot, and consequently called "dot". An early documented use of the zero by Brahmagupta dates to 628. He treated zero as a number and discussed operations involving it. By this time (7th century) the concept had clearly reached Cambodia, and documentation shows the idea later spreading to China and the Islamic world. The Hindu-Arabic number system reached Europe in the late 11th century, via Andalusia, together with knowledge of astronomy and instruments like the astrolabe. The Italian mathematician Fibonacci was instrumental in bringing the system into European mathematics around 1200, though he spoke of the "sign" zero, not as a number. It was not until the 1600s that decimal notation began to come into widespread use in the Occident.

In mathematics

Zero (0) is both a number and a numeral. The natural number following zero is one and no natural number precedes zero. Zero may or may not be counted as a natural number, depending on the definition of natural numbers. Zero is neither prime nor composite. In set theory, the number zero is the cardinality of the empty set: if one does not have any apples, then one has zero apples. In fact, in certain axiomatic developments of mathematics from set theory, zero is defined to be the empty set. The following are some basic rules for dealing with the number zero, first described in Brahmasphutasiddhanta. These rules apply for any complex number x, unless otherwise stated.
- Addition: x + 0 = x and 0 + x = x. (That is, 0 is an identity element with respect to addition.)
- Subtraction: x − 0 = x and 0 − x = − x.
- Multiplication: x · 0 = 0 · x = 0.
- Division: 0 / x = 0, for nonzero x. But x / 0 is undefined, because 0 has no multiplicative inverse, a consequence of the previous rule. For positive x, as y in x / y approaches zero from positive values, its quotient increases toward positive infinity, but as y approaches zero from negative values, the quotient increases toward negative infinity. The different quotients confirms that division by zero is undefined.
- Exponentiation: x0 = 1, except that the case x = 0 may be left undefined in some contexts. For all positive real x, 0x = 0. The expression "0/0" is an "indeterminate form". That does not simply mean that it is undefined; rather, it means that if f(x) and g(x) both approach 0 as x approaches some number, then f(x)/g(x) could approach any finite number or ∞ or −∞; it depends on which functions f and g are. See L'Hopital's rule. The sum of 0 numbers is 0, and the product of 0 numbers is 1.

Extended use of zero in mathematics


- Zero is the identity element in an additive group or the additive identity of a ring.
- A zero of a function is a point in the domain of the function whose image under the function is zero. See zero (complex analysis).
- In geometry, the dimension of a point is 0.
- In analytic geometry, 0 is the origin.
- In nonstandard analysis the number zero is taken as an infinitesimal element of a non-principal ultrafilter.
- The concept of "almost" impossible in probability. More generally, the concept of almost nowhere in measure theory.
- A zero function is a constant function with 0 as its only possible output value; i.e., f(x) = 0. A particular zero function is a zero morphism. A zero function is the identity in the additive group of functions.
- The zero of a function is a preimage of zero, also called the root of a function.
- Zero is one of three possible return values of the Möbius function. Passed an integer x2 or x2y, the Möbius function returns zero.
- It is the number of n×n magic squares for n = 2.
- It is the number of n-queens problem solutions for n = 2, 3.
- Zero is neither a prime nor a composite number.

In physics

The value zero plays a special role for a large number of physical quantities. For some quantities, the zero level is naturally distinguished from all other levels, where as it for others is more or less arbitrarily chosen. For example, on the kelvin temperature scale, zero is the coldest possible temperature (so that negative temperatures are non-existent), where as on the celsius scale, zero is arbitrarily defined to be at the freezing point of water. Measuring sound intensity in decibels or phons, the zero level is arbitrarily set at a reference value, e.g. at a value for the threshold of hearing.

In computer science

Numbering from 1 or 0?

Human beings usually number things starting from one, not zero. Yet in computer science zero has become the popular indication for a starting point. For example, in almost all old programming languages, an array starts from 1 by default, which is natural for humans. As programming languages have developed, it has become more common that an array starts from zero by default (zero-based). One reason for this convention is that modular arithmetic normally describes a set of N numbers as containing 0,1,2,...N-1 in order to contain the additive identity. Because of this, many arithmetic concepts (such as hash tables) are less elegant to express in code unless the array starts at zero. Another reason to use zero-based array indices is that it can improve efficiency under certain circumstances. To illustrate, suppose a is the memory address of the first element of an array, and i is the index of the desired element. In this fairly typical scenario, it is quite common to want the address of the desired element. If the index numbers count from 1, the desired address is computed by this expression: :a + s \times (i-1) where s is the size of each element. In contrast, if the index numbers count from 0, the expression becomes this: :a + s \times i This simpler expression can be more efficient to compute in certain situations. Note, however, that a language wishing to index arrays from 1 could simply adopt the convention that every "array address" is represented by a'=a-s; that is, rather than using the address of the first array element, such a language would use the address of an imaginary element located immediately before the first actual element. The indexing expression for a 1-based index would be the following: :a' + s \times i Hence, the efficiency benefit of zero-based indexing is not inherent, but is an artifact of the decision to represent an array by the address of its first element. This situation can lead to some confusion in terminology. In a zero-based indexing scheme, the first element is "element number zero"; likewise, the twelfth element is "element number eleven". For this reason, the first element is often referred to as the zeroth element to eliminate any possible doubt (though, strictly speaking, this is unnecessary and arguably incorrect, since the meanings of the ordinal numbers are not ambiguous).

Null value

In databases a field can have a null value. This is equivalent to the field not having a value. For numeric fields it is not the value zero. For text fields this is not blank nor the empty string. The presence of null values leads to three-valued logic. No longer is a condition either true or false, but it can be undetermined. Any computation including a null value delivers a null result. Asking for all records with value 0 or value not equal 0 will not yield all records, since the records with value null are excluded. This is owing to the notion that records in a relational database are a set of key/value tuples. A null value, notionally, indicates not that the record has some particular value – "null" – for a given column, but rather that the record has no value at all for that particular column.

Null pointer

A null pointer is a pointer in a computer program that does not point to any object or function. In C, the integer constant 0 is converted into the null pointer at compile time when it appears in a pointer context, and so 0 is a standard way to refer to the null pointer in code. However, the internal representation of the null pointer may be any bit pattern (possibly different values for different data types), and has no particular association with zero.

Negative zero

In some signed number representations (but not the two's complement representation predominant today) and most floating point number representations, zero has two distinct representations, one grouping it with the positive numbers and one with the negatives; this latter representation is known as negative zero. Representations with negative zero can be troublesome, because the two zeroes will compare equal but may be treated differently by some operations.

Distinguishing zero from O

negative zero The oval-shaped zero (appearing like a rugby ball stood on end) and circular letter O together came into use on modern character displays. The zero with a dot in the centre seems to have originated as an option on IBM 3270 controllers (this has the problem that it looks like the Greek letter Theta). The slashed zero, looking identical to the letter O other than the slash, is used in old-style ASCII graphic sets descended from the default typewheel on the venerable ASR-33 Teletype. This format causes problems for certain Scandinavian languages which use Ø as a letter. The convention which has the letter O with a slash and the zero without was used at IBM and a few other early mainframe makers; this is even more problematic for Scandinavians because it means two of their letters collide. Some Burroughs/Unisys equipment displays a zero with a reversed slash. And yet another convention common on early line printers left zero unornamented but added a tail or hook to the letter-O so that it resembled an inverted Q or cursive capital letter-O. The typeface used on some European number plates for cars distinguish the two symbols by making the O rather egg-shaped and the zero more circular, but most of all by opening the zero on the upper right side, so here the circle is not closed any more (as in German plates). In paper writing one may not distinguish the 0 and O at all, or may add a slash across it in order to show the difference, although this sometimes causes ambiguity in regard to the symbol for the null set.

In other fields


- In some countries, 0 on a telephone calls for operator assistance. On the BlackBerry the 0 key also functions as a spacebar.
- In Braille, the numeral 0 has the same dot configuration as the letter J.
- DVDs that can be played in any region are sometimes referred to as being "region 0".

See also


- Negative and non-negative numbers
- Nothing
- Null
- Slashed zero
- Nullar number
- Division by zero

References


- [http://www.amazon.com/exec/obidos/ASIN/0471393401/qid=1124292648/sr=2-2/ref=pd_bbs_b_2_2/102-7275474-2228915 The Universal History of Numbers: From Prehistory to the Invention of the Computer.] Georges Ifrah. Wiley (2000)
- [http://www.mediatinker.com/blog/archives/008821.html A Brief History of Zero] - Kristen McQuillin, July 1997 (revised January 2004)
- [http://www-gap.dcs.st-and.ac.uk/~history/HistTopics/Zero.html A history of Zero]
- [http://home.ubalt.edu/ntsbarsh/zero/ZERO.HTM Zero Saga]
- [http://www.neo-tech.com/zero/part6.html The Discovery of the Zero]
- Charles Seife (2000). [http://www.amazon.com/exec/obidos/tg/detail/-/0140296476/qid=1111606043/sr=8-1/ref=sr_8_xs_ap_i1_xgl14/104-6166861-2891133?v=glance&s=books&n=507846 "Zero: The Biography of a Dangerous Idea".] Publisher: Penguin USA (Paper). ISBN 0140296476 Category:Elementary arithmetic 0 Category:Integers ko:0 ja:0 simple:Zero th:0 (จำนวน)

Division by zero

In mathematics, a division is called a division by zero if the divisor is zero. Such a division can be formally expressed as \frac, where a is the dividend. Whether this expression can be assigned a meaningful (well-defined) value depends upon how the expression is interpreted.

Algebraic interpretation

It is generally regarded among mathematicians that a natural way to interpret division by zero is to first define division in terms of other arithmetic operations. Under the standard rules for arithmetic on integers, rational numbers, real numbers and complex numbers, the value of a division by zero is undefined, as it is in any field. The reason is that division is defined to be the inverse operation of multiplication. This means that the value of : is the solution x of the equation : b x = a \quad whenever such a value exists and is unique. Otherwise the expression is undefined. For b = 0, the equation bx = a can be rewritten as 0x = a or simply 0 = a. Thus, in this case, the equation bx = a has no solution if a is not equal to 0, and has any x as a solution if a equals 0. In either case, is undefined. Conversely, for the number systems mentioned above, the expression is always defined if b is not equal to zero.

Fallacies based on division by zero

It is possible to disguise a special case of division by zero in an algebraic argument, leading to spurious proofs that 2 = 1 such as the following:
- 1) For any real number x: :: x^2 - x^2 = x^2 - x^2 \quad
- 2) Factoring both sides in two different ways: :: (x - x)(x + x) = x(x - x)\quad
- 3) Dividing both sides by x - x, giving (0/0) : :: (0/0)(x + x) = x(0/0) \quad
- 4) Simplified, yields: :: (1)(x + x) = x(1) \quad
- 5) Which is: :: 2x = x \quad
- 6) Since this is valid for any value of x, we can plug in x = 1. :: 2 = 1 \quad The fallacy is the assumption in step 4 that (x - x)/(x - x) -- which is (0/0) -- simplifies to 1 . This proof is for the special case of dividing by zero when the numerator is zero. The fallacy results from the assumption that 0/0 = 1 -- an assumption that generates the absurdity that 2 = 1 . This special case proof is instructive in that it is commonly held to be a general proof on how division by zero is destructive to math (a virtual Weapon of Math Destruction). In reality it only shows that 0/0 = 1 is bad for algebra. This proof, strictly speaking, is not a general case against division by zero. If one were to rewrite the proof and assume that 0/0 = 0 , the absurdity would be erased. This flexibility on assuming the value of 0/0 gets to the real issue: 0/0 is indeterminate on the Reals. In the above proof it was determined to be 1 -- possibly because of the rule that a/a = 1 . But when a = 0 we have an indeterminate meaning, and we are also free to work as if 0/0 = 0 . Still, in practice, division by a term in any algebraic argument will require either an explicit assumption that the term is not zero, or a separate justification showing that the term can never be zero.

Abstract algebra

Similar statements are true in more general algebraic structures, such as rings and fields. In a field, every nonzero element is invertible under multiplication, so as above, division poses problems only when attempting to divide by zero. However, in other rings, division by nonzero elements may also pose problems. Consider, for example, the ring Z/6Z of integers mod 6. What meaning should we give to the expression : This should be the solution x of the equation : 2x = 2 \quad But this equation has two distinct solutions, x = 1 and x = 4, so the expression is undefined. The problem occurs because 2 is not invertible under multiplication.

Limits and division by zero

field At first glance it seems possible to define by considering the limit of as b approaches 0. For any nonzero a, it is known that :\lim_ = \infty and :\lim_ = \infty Therefore, we might consider defining as +\infty for positive a, and -\infty for negative a. However, this definition is not generally useful, because positive and negative infinity are not real numbers, and the equation :0 \, x = a still has no solution for any finite a. Furthermore, there is no obvious definition of that can be derived from considering the limit of a ratio. The limit : \lim_ does not exist. Limits of the form : \lim_ in which both f(x) and g(x) approach 0 as x approaches 0, may converge to any value or may not converge at all. See l'Hopital's rule for discussion and examples of limits of ratios.

In mathematical analysis

In distribution theory one can extend the function : to a distribution on the whole space of real numbers (in effect by using Cauchy principal values). It does not, however, make sense to ask for a 'value' of this distribution at x = 0; a sophisticated answer refers to the singular support of the distribution.

Other number systems

Although division by zero is undefined with real numbers and integers, it is possible to consistently define division by zero in other mathematical structures, for instance on the Riemann sphere (see also poles in complex analysis). In hyperreal numbers and surreal numbers, division by non-zero infinitesimals is possible. If a number system forms a commutative ring, as do the integers, the real numbers, and the complex numbers, for instance, it can be extended to a wheel in which division by zero is always possible, but division has then a slightly different meaning.

Division by zero in computer arithmetic

The IEEE floating-point standard, supported by almost all modern processors, specifies that every floating point arithmetic operation, including division by zero, has a well-defined result. In IEEE 754 arithmetic, a/0 is positive infinity when a is positive, negative infinity when a is negative, and NaN (not a number) when a = 0. These definitions are derived from the properties of limits of ratios, as discussed above. Integer division by zero is usually handled differently from floating point since there is no integer representation for the result. Some processors generate an exception when an attempt is made to divide an integer by zero, although others will simply continue and simply generate an incorrect result for the division (often 0). If an exception is raised, the usual result is aborting whatever program it occurred in, although some programs (especially those that use fixed-point arithmetic where no dedicated floating-point hardware is available) will use behavior similar to the IEEE standard, using large positive and negative numbers to approximate infinities.

See also


- defined and undefined Category:Elementary arithmetic Category:Computer arithmetic Category:Fractions ja:ゼロ除算

Slash (punctuation)

A solidus, oblique or slash, /, is a punctuation mark. It is also called a diagonal, separatrix, shilling mark, stroke, virgule, slant, or forward slash.

Usage

History

This symbol goes back to the days of ancient Rome. In the early modern period, in the Fraktur script, which was widespread through Europe in the Middle Ages, one slash (/) represented a comma, while two slashes (//) represented a Dash. The two slashes eventually evolved into a sign similar to the Equals sign (=), then being further simplified to a single dash (-).

English

The most common use is to replace the hyphen to make clear a strong joint between words or phrases, such as "the Ernest Hemingway/William Faulkner generation". Yet very often it is used to represent the concept or, especially in instruction books. The symbol also appears in the phrase and/or, a prose representation of the logical concept of inclusive or. The State Legislature of Georgia, however, has banned this usage as cumbersome. The slash is often used (incorrectly) to separate the letters in a two-letter initialism, such as R/C (short for radio control) or even w/e (an internet slang abbreviation for whatever). Purists strongly discourage this misuse of the symbol, however, because it could potentially create confusion about its meaning. The virgule is also used to indicate a line break when quoting multiple lines from a poem, play, or headline. For a specialized use of the slash in the titles of fan fiction stories, see slash fiction. Note that the solidus and virgule are distinctly different typographic symbols with decidedly different uses. The solidus is significantly more oblique than the virgule. The character found on standard keyboards is the virgule and while most people lump the two characters together, (and when there is no alternative it is acceptable to use the virgule in place of the solidus,) they are different. The solidus is used in the display of ratios and fractions as in constructing a fraction using superscript and subscript as in “123456”; the virgule is used for essentially any other textual purpose.

Linguistics

Slashes are used to enclose a phonemic transcription of speech.

Arithmetic

A solidus is used to separate the numerator and denominator in a vulgar fraction, or as a division operator in general. :3/8    (three eighths) :x = a / b    (x equals a divided by b) Note that the special character Fraction slash U+2044, character ⁄ (the solidus or shilling mark proper), can be used instead of a virgule, and is preferred whenever possible. It is also found in many legacy Apple Macintosh character sets. Systems capable of fine typography should display the result as a true fraction with smaller numbers. Unicode also distinguishes the Division Slash U+2215 (∕) which may be more oblique than the normal solidus character.

Computing

Files

On Unix-like systems, the slash carries two distinct meanings. Its primary use, as with URLs, is to separate directory and file components of a path: :pictures/image.jpg :http://en.wikipedia.org/wiki/Slash_%28punctuation%29 A leading slash however represents the root directory of the Virtual file system; it is used when specifying absolute paths: :/home/joe/pictures/image.jpg It is sometimes called a "forward slash" to contrast with the backslash \, which is the path delimiter on MS-DOS and Microsoft Windows systems. These operating systems use the backslash rather than the slash because in the early days of CP/M—before directories were supported —the slash was chosen as the command-line option indicator: :dir /w /ogn Note however that the "forward slash" will be translated into a backslash by most versions of DOS and Windows, in contexts where there is little ambiguity with command-line options. Some people incorrectly refer to a slash as a "backslash", for instance when reading URLs out loud.

Chat

Many Internet Relay Chat and in-game chat clients use the slash to distinguish commands, such as the ability to join or part a chat room or send a private message to a certain user. :/join #services :/me sings a song about birds.

Programming

In computer programming, the solidus corresponds to Unicode and ASCII character 47, or 0x002F. It is used in the following settings:
- In most programming languages, / is used as a division operator,
- Comments in C and JAVA begin with /
-
(a slash and an asterisk), and ended with
- /
(the same characters in the opposite order).
- C++ and C99 introduced comments that begin with // (two slashes) and span a single line.
- In HTML and XML, a slash is used to indicate a closing tag. For example, in HTML, </em> ends a section of emphasized text that had been started with <em>.

Dates

Certain shorthand date formats use / as a delimiter, for example "9/16/2003" (in United States usage) or "16/9/2003" (in many other countries) means September 16, 2003. In Britain there was a specialized use in prose: 7/8 May referred to the night which starts the evening of 7 May and ends the morning of 8 May, totalling about 12 hours depending on the season. This was used to list night-bombing air-raids which would carry past midnight. Some police units in the US use this notation for night disturbances or chases. Contrariwise, the form with a hyphen, 7-8 May, would refer to the two-day period, at most 49 hours. This would commonly be used for meetings. The International Standard ISO 8601, in attempting to resolve this ambiguity, introduced problems of its own. According to this norm, dates must be written year-month-day using hyphens, but time periods are written as two standard dates separated by a slash: 1939-09-01/1945-05-08, for example, would be the duration of the Second World War in the European theatre, while 09-03/12-22 might be used for a fall term of a Western school, from September third to December twenty-second.

British money

Before decimalisation in the UK, / was used to separate pounds, shillings, and pence values. Notice how the dash is used to represent zero.

Alternative names

In the UK, the usual term for the mark is an oblique, although slash is gaining currency with increasing use of computers and also through the media, such as BBC Radio and mainstream television. Sometimes this is called stroke (and oblique stroke) , although that may be confused with the hyphen. Stroke is most commonly used among the North American amateur radio community. Among American telephone technical support representatives in the computer industry, the double-slash in a URL address is commonly nicknamed "whack-whack." For example, the representative may tell the user to go to a support website: "OK, open up a browser and type in the following address: http colon whack-whack, www dot supportsite dot com." The origins of this slang term are not known but may be related to the slang for the exclamation point (!) which support engineers, especially in password resets, often refer to as "bang." —C.J. Newton Category:Punctuation Category:Typography ja:スラッシュ (記号)

Programming language

A programming language or computer language is a standardized communication technique for expressing instructions to a computer. It is a set of syntactic and semantic rules used to define computer programs. A language enables a programmer to precisely specify (but see Genetic Programming) what data a computer will act upon, how these data will be stored/transmitted, and what actions will be taken under various circumstances.

Features of programming language

Each programming language can be thought of as a set of formal specifications concerning syntax, vocabulary, and meaning. These specifications usually include:
- Data Types
- Data Structures
- Instruction and Control Flow
- Design Philosophy
- Compilation and Interpretation Most languages that are widely used, or have been used for a considerable period of time, have standardization bodies that meet regularly to create and publish formal definitions of the language, and discuss extending or supplementing the already extant definitions.

Data types

Internally, all data in modern digital computers are stored simply as zeros or ones (binary). The data typically represent information in the real world such as names, bank accounts and measurements and so the low-level binary data are organized by programming languages into these high-level concepts. The particular system by which data are organized in a program is the type system of the programming language; the design and study of type systems is known as type theory. Languages can be classified as statically typed languages, and dynamically typed languages. Statically typed languages can be further subdivided into languages with manifest types, where each variable and function declaration has its type explicitly declared, and type-inferred languages. It is possible to perform type inference on programs written in a dynamically typed language, but it is entirely possible to write programs in these languages that make type inference infeasible. Sometimes dynamically typed languages are called latently typed. With statically typed languages, there usually are pre-defined types for individual pieces of data (such as numbers within a certain range, strings of letters, etc.), and programmatically named values (variables) can have only one fixed type, and allow only certain operations: numbers cannot change into names and vice versa. Most mainstream statically typed languages, such as C, C++, C#, Java and Delphi, require all types to be specified explicitly; advocates argue that this makes the program easier to understand, detractors object to the verbosity it produces. Type inference is a mechanism whereby the type specifications can often be omitted completely, if it is possible for the compiler to infer the types of values from the contexts in which they are used -- for example, if a variable is assigned the value 1, a type-inferring compiler does not need to be told explicitly that the variable is an integer. There are however many different uses for integers; it might e.g. make sense in a program to prevent inadvertent adding of a phone number to the number of apples in a box. Therefore some languages such as Ada allow defining different kinds of incompatible integers; this is called strong typing. Type-inferred languages can be more flexible to use, particularly when they also implement parametric polymorphism. Examples of type-inferring languages are Haskell, MUMPS and ML. Dynamically typed languages treat all data locations interchangeably, so inappropriate operations (like adding names, or sorting numbers alphabetically) will not cause errors until run-time -- although some implementations provide some form of static checking for obvious errors. Examples of these languages are APL, Objective-C, Lisp, Smalltalk, JavaScript, Tcl, Prolog, Python, and Ruby. Strongly typed languages do not permit the usage of values as different types; they are rigorous about detecting incorrect type usage, either at runtime for dynamically typed languages, or at compile time for statically typed languages. Ada, Java, ML, and Oberon are examples of strongly typed languages. Weakly typed languages do not strictly enforce type rules or have an explicit type-violation mechanism, often allowing for undefined behavior, segmentation violations, or other unsafe behavior if types are assigned incorrectly. C, assembly language, C++, and Tcl are examples of weakly typed languages. Note that strong vs. weak is a continuum; Java is a strongly typed language relative to C, but is weakly typed relative to ML. Use of these terms is often a matter of perspective, much in the way that an assembly language programmer would consider C to be a high-level language while a Java programmer would consider C to be a low-level language. Note that strong and static are orthogonal concepts. Java is a strongly, statically typed language. C is a weakly, statically typed language. Python is a strongly, dynamically typed language. Tcl is a weakly, dynamically typed language. But beware that some people incorrectly use the term strongly typed to mean strongly, statically typed, or, even more confusingly, to mean simply statically typed--in the latter usage, C would be called strongly typed, despite the fact that C doesn't catch that many type errors and that it's both trivial and common to defeat its type system (even accidentally). Aside from when and how the correspondence between expressions and types is determined, there's also the crucial question of what types the language defines at all, and what types it allows as the values of expressions (expressed values) and as named values (denoted values). Low-level languages like C typically allow programs to name memory locations, regions of memory, and compile-time constants, while allowing expressions to return values that fit into machine registers; ANSI C extended this by allowing expressions to return struct values as well (see record). Functional languages often restrict names to denoting run-time computed values directly, instead of naming memory locations where values may be stored, and in some cases refuse to allow the value denoted by a name to be modified at all. Languages that use garbage collection are free to allow arbitrarily complex data structures as both expressed and denoted values. Finally, in some languages, procedures are allowed only as denoted values (they cannot be returned by expressions or bound to new names); in others, they can be passed as parameters to routines, but cannot otherwise be bound to new names; in others, they are as freely usable as any expressed value, but new ones cannot be created at run-time; and in still others, they are first-class values that can be created at run-time.

Data structures

Most languages also provide ways to assemble complex data structures from built-in types and to associate names with these new combined types (using arrays, lists, stacks, files). Object oriented languages allow the programmer to define data-types called "Objects" which have their own intrinsic functions and variables (called methods and attributes respectively). A program containing objects allows the objects to operate as independent but interacting sub-programs: this interaction can be designed at coding time to model or simulate real-life interacting objects. This is a very useful, and intuitive, functionality. Languages such as Python and Ruby have developed as OO (Object oriented) languages. They are comparatively easy to learn and to use, and are gaining popularity in professional programming circles, as well as being accessible to non-professionals. It is commonly thought that object-orientation makes languages more intuitive, increasing the public availability and power of customized computer applications.

Instruction and control flow

Once data has been specified, the machine must be instructed how to perform operations on the data. Elementary statements may be specified using keywords or may be indicated using some well-defined grammatical structure. Each language takes units of these well-behaved statements and combines them using some ordering system. Depending on the language, differing methods of grouping these elementary statements exist. This allows one to write programs that are able to cover a variety of input, instead of being limited to a small number of cases. Furthermore, beyond the data manipulation instructions, other typical instructions in a language are those used for control flow (branches, definitions by cases, loops, backtracking, functional composition).

Design philosophy

For the above-mentioned purposes, each language has been developed using a special design or philosophy. Some aspect or another is particularly stressed by the way the language uses data structures, or by which its special notation encourages certain ways of solving problems or expressing their structure. Since programming languages are artificial languages, they require a high degree of discipline to accurately specify which operations are desired. Programming languages are not error tolerant; however, the burden of recognizing and using the special vocabulary is reduced by help messages generated by the programming language implementation. There are a few languages which offer a high degree of freedom in allowing self-modification in which a program re-writes parts of itself to handle new cases. Typically, only machine language, Prolog, PostScript, and the members of the Lisp family (Common Lisp, Scheme) provide this capability. In MUMPS language this technique is called dynamic recompilation; emulators and other virtual machines exploit this technique for greater performance.

Compilation and interpretation

There are, broadly, two approaches to execute a program written in a given language. These approaches are known as compilation, done by a program known as a compiler; and interpretation, done by an interpreter. Some programming language implementations support both interpretation and compilation. An interpreter parses a computer program and executes it directly. One can imagine this as following the instructions of the program line-by-line. In contrast, a compiler translates the program into machine code -- the native instructions understood by the computer's processor. The compiled program can then be run by itself. Compiled programs usually run faster than interpreted ones, because the overhead of understanding and translating the programming language syntax has already been done. However, interpreters are frequently easier to write than compilers, and can more easily support interactive debugging of a program.

History of programming languages

The development of programming languages, unsurprisingly, follows closely the development of the physical and electronic processes used in today's computers. Programming languages have been under development for years and will remain so for many years to come. They got their start with a list of steps to wire a computer to perform a task. These steps eventually found their way into software and began to acquire newer and better features. The first major languages were characterized by the simple fact that they were intended for one purpose and one purpose only, while the languages of today are differentiated by the way they are programmed in, as they can be used for almost any purpose. And perhaps the languages of tomorrow will be more natural with the invention of quantum and biological computers. Charles Babbage is often credited with designing the first computer-like machines, which had several programs written for them (in the equivalent of assembly language) by Ada Lovelace. In the 1940s the first recognizably modern, electrically powered computers were created. Some military calculation needs were a driving force in early computer development, such as encryption, decryption, trajectory calculation and massive number crunching needed in the development of atomic bombs. At that time, computers were extremely large, slow and expensive: advances in electronic technology in the post-war years led to the construction of more practical electronic computers. At that time only Konrad Zuse imagined the use of a programming language (developed eventually as Plankalkül) like those of today for solving problems. Subsequent breakthroughs in electronic technology (transistors, integrated circuits, and chips) drove the development of increasingly reliable and more usable computers. The first widely used high level programming language was Fortran, developed during 1954–57 by an IBM team led by John W. Backus. It is still widely used for numerical work, with the latest international standard released in 2004. A [http://www.levenez.com/lang/history.html Computer Languages History] graphic shows a timeline from Fortran in 1954. Dennis Ritchie and Brian Kernighan developed the C programming language, initially for DEC PDP-11 in 1970. Later with lead of Bjarne Stroustrup the programming language C++ appeared in 1985 as an Object oriented language vertically compatible with C. Sun Microsystems released Java in 1995 which became very popular as an introductory programming language taught in universities. Microsoft presented the C# programming language in 2001 which is very similar to C++ and Java. There are many, many other languages (cf. List of programming languages).

Classifications of programming languages


- Array
- Aspect-oriented
- Assembly
- Concatenative
- Concurrent
- Curly-bracket
- Data-structured
- Dataflow
- Declarative
- Domain-specific
- Dynamic
- Educational
- Esoteric
- Functional
- General-purpose
- Imperative
- Interface description
- Logic
- Multiparadigm
- Object-oriented
  - Prototype-based
- Pattern directed invocation
- Procedural
- Quantum
- Reflective
- Scripting
- Synchronous
- Visual
- Lists of all programming languages
  - Alphabetical
  - Categorical
  - Chronological
  - Generational

Formal semantics

The rigorous definition of the meaning of programming languages is the subject of formal semantics.

See also


- Computer language
- Compiler
- Interpreter
- Binding
- Hello world program, examples of a simple program in many different programming languages
- Software engineering and List of software engineering topics
- Lists of computer syntax patterns
- Reserved word
- Keyword (Computer)
- Programming language dialect
- :Category:Programming languages

External links


- [http://merd.sourceforge.net/pixel/language-study/syntax-across-languages/ Syntax Patterns for Various Languages]
- Wikisource Source Code Examples
- [http://www.99-bottles-of-beer.net/ 99 Bottles of Beer] - One program written in 813 different programming languages
- [http://dmoz.org/Computers/Programming/Languages/ Open Directory - Computer Programming Languages]
- [http://ixpubs.com/ixg/comp_lang_quik_ref.html Computer Languages Quick Reference Chart]
- [http://www.levenez.com/lang/history.html Computer Languages History graphical chart]
- [http://ixpubs.com/ixg/comp_lang_ref.html Instant Expert - Computer Language Reference]
- [http://cgibin.erols.com/ziring/cgi-bin/cep/cep.pl Dictionary of Programming Languages]
- [http://www.techbookreport.com/ProgIndex.html TechBookReport - Programming] - Book and software reviews on all aspects of programming and programming languages.
- [http://www.computer-books.us/ Computer-Books.us] - A collection of programming books available for free download.
- [http://people.ku.edu/~nkinners/LangList/Extras/langlist.htm The Language List] - A catalog of claimed about 2 500 language entries
-
Category:Computer languages ja:プログラミング言語 th:ภาษาโปรแกรม

Fraction (mathematics)

: In mathematics, a fraction is a way of expressing a quantity based on an amount that is divided into a number of equal-sized parts. For example, each part of a cake split into four equal parts is called a quarter (and represented numerically as 14); two quarters is half the cake, and eight quarters would make two cakes. Mathematically, a fraction is a quotient of numbers, like 34, or more generally, an element of a quotient field. In our cake example above, where a quarter is represented numerically as 14 the bottom number, (called the denominator) is the total number of equal parts making up the cake as a whole, and the top number (called the numerator) is the number of these parts we have. For example, the fraction 34 represents three quarters. The numerator and denominator are the terms of the fraction. The word "numerator" is related to the word "enumerate." To enumerate means to "tell how many"; thus the numerator tells us how many fractional parts we have in the indicated fraction. To denominate means to "give a name" or "tell what kind"; thus the denominator tells us what kind of parts we have (halves, thirds, fourths, etc.). The word is also used in related expressions, like continued fraction, see Special cases below.

Arithmetic

There are four basic arithmetic operations, which in order of simplicity for fractions, includes (1) Multiplication (2) Addition (3) Subtraction (4) Division.

Addition

Adding Fractions

Adding fractions can be a little tricky, since you cannot simply add the numerators and denominators. For example, if we had a cake divided into three pieces, each piece would be 1/3. Then, if we try to add one piece from the cake divided into four pieces, and one piece from the cake divided into three pieces, what would be have? Well, we would have, um, 1/4 + 1/3 = ??? You can see this is NOT equal to 1/7 or 2/7 !! To add fractions together, they must be changed to equivalent values having the same fractional unit -- the same denominator -- in this case 1/12. How do we do this? By multiplying each fraction by 1. By one? Yes. 1 = 3/3 and 1 = 4/4. Now watch: 1/4 = 1/4 x 1 = 1/4 x 3/3 = 3/12. And 1/3 = 1/3 x 1 = 1/3 x 4/4 = 4/12. So now 1/4 + 1/3 = 3/12 + 4/12 = 7/12 and we have the correct result. Notice that we only add the numerators together. The denominator does not change, since we are working with the same fractional unit. Another way to see this is: 1/4 + 1/3 = 3/12 + 4/12 = 1/12 x (3 + 4) = 1/12 x 7 = 7/12. Lets take another example. If you add a half dollar to a quarter, what will you get? You know it's 75 cents, right? When we say 75 cents we have automatically, in our mind, changed each coin into cents (pennies): One half dollar = 50 cents; one quarter = 25 cents; so 1/2 + 1/4 = 50/100 + 25/100 = 75/100 or 75 cents. Of course, we could use a smaller denominator since we know one half dollar equals two quarters. I.e., 1/2 + 1/4 = 2/4 + 1/4 = 3/4. In words, one half plus one quarter equals two quarters plus one quarter equals three quarters, or 75 cents. So the trick is to find a common fractional unit -- a common denominator -- that will let us simply add the numerators together. Let's take one more example. Find 2/3 + 1/2. We see that the denominators are 3 and 2. We need to find a value that each denominator can be multiplied by to give a common value. Well, it's easy to see that we can multiply 3 by 2, and 2 by 3, to give a common denominator of 6. But remember, you cannot change the value of each fraction, so we must multiply both numerator and denominator by the same number. We now have: 2/3 + 1/2 = 2/2 x 2/3 + 3/3 x 1/2 = 4/6 + 3/6 = 7/6 or 1 + 1/6.

Multiplication

By whole numbers

If you consider the cake example above, if you have a quarter of the cake, and you multiple the amount by three, then you end up with three quarters. We can write this numerically as follows: :3 \times = As another example, suppose that five people work for three hours out of a seven hour day (ie. for three seventh of the work day). In total, they will have worked for 15 hours (5 x 3 hours each), or 15 sevenths of a day. Since 7 seventh of a day is a whole day, 14 sevenths is two days, then in total, they will have worked for 2 days and a seventh of day. Numerically: :5 \times = = 2

By fractions

If you consider the cake example above, if you have a quarter of the cake, and you multiple the amount by a third, then you end up with a twelfth of the cake. In other words, a third of a quarter (or a third times a quarter), is a twelfth. Why? Because we are splitting each quarter into three pieces, and four quarters times three makes 12 parts (or twelfths). We can write this numerically as follows: : \times = As another example, suppose that five people do an equal amount work that totals three hours out of a seven hour day. Each person will have done a fifth of the work, so they will have worked for a fifth of three sevenths of a day. Numerically: : \times =

General rule

You may have noticed that when we multiply fractions, we simply multiply the two numerators (the top numbers), and multiply the two denominators) (the bottom numbers). For example: : \times = =

By mixed whole number/fractions

If we are multiplying fractions that include a whole number component, then it is best to convert the whole number into a fraction. For example: :3 \times 2 = 3 \times \left ( \right ) = 3 \times = = 8 In other words, 2 is the same as \left ( \right ), making 11 quarters in total (because 2 cakes, each split into quarters makes 8 quarters total). And 33 quarters is 8 since 8 cakes, each made of quarters, is 32 quarters in total.

Commutativity

It is also worth recalling that multiplication is commutative which just means that the order of the numbers we are multiplying does not matter. In other words, three lots of a quarters is equivalent to a quarter of three; numerically: :3 \times = \times 3 = Note that when talking, we say "three times a quarter", but "a quarter of three", the implication being that in the latter example, we are talking about a fractional part of a larger number.

Special cases


- A vulgar fraction (or common fraction) is a rational number written as one integer (the numerator) divided by a non-zero integer (the denominator). The line that separates the numerator and the denominator is called the vinculum. Rational numbers are the quotient field of integers.

Particular vulgar fractions


- irreducible fraction: a vulgar fraction "in lowest terms", where the numerator is an integer, the denominator is a positive integer, and the highest common factor of the numerator and the denominator is 1;
- proper fraction: a vulgar fraction with (absolute) value between 0 and 1;
- improper fraction: a vulgar fraction with a (absolute) value greater than 1;
- unit fraction: a vulgar fraction with a numerator of 1;
- Egyptian fraction: the sum of distinct unit fractions;
- decimal fraction: a vulgar fraction where the denominator is a power of 10;
- dyadic fraction: a vulgar fraction in which the denominator is a power of two.

Other fractions


- A mixed fraction: A mixed fraction is an integer plus a proper fraction.
- A compound fraction is a fraction where the numerator or denominator (or both) contain fractions.
- Rational functions are the quotient field of polynomials (over some integral domain). Let us end with the only example on this page where the "fraction" is not an element of a quotient field:
- A continued fraction is an expression such as a_0 + \frac , where the ai are integers. The term partial fraction is used in algebra, when decomposing rational functions. However, a partial fraction is an expression of a particular decomposition, and so is more than just an element of a quotient field. The term irrational fraction is sometimes used to indicate a magnitude whose quotient with another fixed magnitude is irrational, e.g. "1 is an irrational fraction of 2π". "Fraction", in this sense, simply means "a part of the whole", not a strict ratio in the mathematical sense. Taking the latter meaning, the term is an oxymoron.

Pedagogical tools

In Primary Schools, fractions have been demonstrated through Cuisenaire rods. See also the external links below.

See also


- For basic arithmetic with fractions, see vulgar fraction
- For other meanings of the word 'fraction', see fraction (disambiguation)

External links


- [http://www.mathfactcafe.com Curricula for Creating Fractions]
- [http://www.ericdigests.org/2000-2/fractions.htm Curricula for Teaching about Fractions]
- [http://www.ericdigests.org/2004-1/fractions.htm Teaching Fractions: New Methods, New Resources]
- [http://www.kwiznet.com/p/takeQuiz.php?ChapterID=1551&CurriculumID=4&Method=Worksheet Worksheets: Identifying Fractions]
- [http://www.kwiznet.com/p/takeQuiz.php?ChapterID=1364&CurriculumID=4&Method=Worksheet Worksheets: Improper Fractions to Mixed Numbers]
- [http://www.math-lessons.ca Curricula for Teaching about Equivalent Fractions]
- [http://www.quiz-tree.com/Fractions_Practice_main.html Free online quizzes about Fractions]
-
Category:Mathematical disambiguation Category:Elementary arithmetic Category:Numbers ja:分数

Obelus

:The word "obelus" is also an alternate name for the dagger () symbol. An obelus is a symbol consisting of a line with dots above and below, \div, used to represent the mathematical division operation. This symbol is also known as a division sign. Originally this sign (or a plain line) was used in ancient manuscripts to mark passages which were suspected of being corrupted or spurious. The word "obelus" comes from the Greek word for a sharpened stick, spit, or pointed pillar. This is same root as that of the word "obelisk". The obelus was first used as a symbol for division in 1659 in the algebra book Teutsche Algebra by Johann Rahn. Some think that John Pell, who edited the book, may have been responsible for this use of the symbol. The obelus had been used by some writers to represent subtraction, and that usage continued in some parts of Europe (including, until fairly recently, Denmark). Today the obelus remains in occasional use, primarily as a standalone symbol for the division operation itself (as on a calculator), or as an operator in elementary arithmetic. In most contexts division is now signified in other ways, usually by writing the operands one above the other separated by a line, or on the same line with the slash (or solidus) as the symbol signifying division. In the Unicode character set, the obelus is known as a "division sign" and has the code point U+00F7. In HTML, it can be encoded as &divide; (at HTML level 3.2) or &#xF7;.

External links


- [http://members.aol.com/jeff570/operation.html Jeff Miller: Earliest Uses of Various Mathematical Symbols]
- [http://www.worldwidewords.org/articles/signs.htm Michael Quinion: Where our arithmetic symbols come from] Category:Mathematical notation Category:Typography

Calculator

A calculator is a device for performing numerical calculations. The type is considered distinct from both a calculating machine and a computer in that the calculator is a special-purpose device that may not qualify as a Turing machine. Although modern calculators often incorporate a general purpose computer, the device as a whole is designed for ease of use to perform specific operations, rather than for flexibility. The complexity of calculators varies with the intended purpose. A simple one with only four functions (addition, subtraction, multiplication and division and perhaps a single-number memory) may be useful for everyday activities such as shopping or checking a bill. More complex ones may include complex mathematical functions suitable to engineering or accounting as well as a substantial memory and the ability to execute moderately complex programs. Since the late-1980's, it has become common to incorporate simple calculators in other small devices, such as mobile phones, pagers or wrist watches. In most developed countries, students use calculators for schoolwork. There was some initial resistance to the idea out of fear that basic arithmetic skills would suffer. There remains disagreement about the importance of the ability to perform calculations by hand or "in the head", with some curricula restricting calculator use until a certain level of proficiency has been obtained, while others concentrate more on teaching estimation techniques and problem-solving.

Overview

Modern calculators are electrically powered, most often by battery, and are made by numerous manufacturers, in countless shapes and sizes varying from cheap, give-away, credit-card sized models to more sturdy adding machine-like models with built-in printers. Only a very few companies develop and make modern professional engineering and finance calculators: The most well-known are Casio, Sharp, Hewlett-Packard (HP) and Texas Instruments (TI). Such calculators are good examples of embedded systems. They are also often complex enough to be programmed; calculator applications include algebraic equation solvers, financial models and even games. In the near past, mechanical and clerical aids such as abacuses, comptometers, Napier's bone