Jump to content

Tilde: Difference between revisions

From Wikipedia, the free encyclopedia
Content deleted Content added
No edit summary
Undid revision 193427803 by Dallassoukup (talk)
Line 3: Line 3:


The '''tilde''' (~) is a [[grapheme]] with several uses. The name of the character comes from [[Spanish language|Spanish]], from the [[Latin]] ''titulus'' meaning a title or superscription, and is pronounced '''''til-de'''''. It was originally written over a letter as a mark of [[abbreviation]], but has since acquired a number of other uses as a [[diacritic]] mark or a character in its own right. In the latter capacity (especially in [[lexicography]]), a tilde is sometimes confused with a '''swung dash''' (usually lengthened to {{Unicode|~}}) which is used in dictionaries to indicate the omission of a word<ref>http://wordnet.princeton.edu/perl/webwn?s=swung%20dash</ref>.
The '''tilde''' (~) is a [[grapheme]] with several uses. The name of the character comes from [[Spanish language|Spanish]], from the [[Latin]] ''titulus'' meaning a title or superscription, and is pronounced '''''til-de'''''. It was originally written over a letter as a mark of [[abbreviation]], but has since acquired a number of other uses as a [[diacritic]] mark or a character in its own right. In the latter capacity (especially in [[lexicography]]), a tilde is sometimes confused with a '''swung dash''' (usually lengthened to {{Unicode|~}}) which is used in dictionaries to indicate the omission of a word<ref>http://wordnet.princeton.edu/perl/webwn?s=swung%20dash</ref>.

JUDY APPROVES OF THIS WEBPAGE LA~!
==Diacritical use==
==Diacritical use==



Revision as of 04:34, 23 February 2008

The tilde (~) is a grapheme with several uses. The name of the character comes from Spanish, from the Latin titulus meaning a title or superscription, and is pronounced til-de. It was originally written over a letter as a mark of abbreviation, but has since acquired a number of other uses as a diacritic mark or a character in its own right. In the latter capacity (especially in lexicography), a tilde is sometimes confused with a swung dash (usually lengthened to ~) which is used in dictionaries to indicate the omission of a word[1].

Diacritical use

In languages, the tilde is a diacritical mark (~) placed over a letter to indicate a change in pronunciation, such as nasalization.

It was first used in the polytonic orthography of Ancient Greek, as a variant of the circumflex accent, representing a rise in pitch followed by a return to standard pitch.

Later, it was used to make abbreviations in medieval Latin documents. When an "n" or "m" followed a vowel, it was often omitted, and a tilde (i.e. a small "n") was placed over the preceding vowel to indicate the missing letter. This is the origin of the use of tilde to indicate nasalization. The practice of using the tilde over a vowel to indicate omission of an "n" or "m" continued in printed books in French as a means of reducing text length until the 17th century. It was also used in Spanish and Portuguese. The tilde was also used occasionally to make other abbreviations, such as over the letter "q" to signify the word que ("that").

The tilded "n" ("ñ") developed from the digraph "nn" in Spanish. It is usually regarded as a separate letter called eñe (IPA ['eɲe]), rather than a letter-diacritic combination. In addition, the word tilde can refer to any diacritic in this language; for example, the acute accent in José is also called a tilde in Spanish. Current languages in which the tilded "n" ("ñ") is used for the palatal nasal consonant /ɲ/ include:

It is also as a small "n" that the tilde originated when written above another letters, marking a Latin "n" which had been elided in old Galician-Portuguese. It indicates nasalization of the base vowel: mão "hand", from Lat. manu-; razões "reasons", from Lat. rationes. Current languages and alphabets in which the tilde is used as a sign of nasalization include:

Languages and alphabets that use the tilde for other purposes:

Lexicography

The tilde is often used in dictionaries to save space

In dictionaries, both bilingual and monolingual, the tilde is often referred to as a swung dash. It is often used to replace the headword of an entry when it occurs within the entry, in order to save space. For example, "~ enough" would represent "ironically enough" at the entry for "ironically".

Logic

In written mathematical logic, it represents negation (e.g. "~p" equals "not p".) Modern use has been replacing the tilde with the exclamation mark (!) for this purpose, to avoid confusion with equivalence relations.

Electronics

It can approximate the sine wave symbol (∿, U+223F), which is used in electronics to indicate alternating current, in place of +, −, or ⎓ for direct current.

Punctuation

The Spanish language motto of the Catholic Monarchs, tanto monta is written in this inscription as tãto mõta.

In some languages (though not English), a tilde-like wavy dash may be used as punctuation (instead of an unspaced hyphen or en-dash) between two numbers, to indicate a range rather than subtraction or a hyphenated number (such as a part number or model number). Japanese and other East Asian languages almost always use this convention, but it is often done for clarity in some other languages as well. For example, 12~15 means "12 to 15", ~3 means "up to three" and 100~ means "100 and greater." In English, the tilde is often used to express ranges and model numbers in electronics but rarely in formal grammar or type-set documents, as a wavy dash preceding a number sometimes represents an approximation (see the following section).

In Japanese, the tilde is also used to separate a title and a subtitle in the same line. A colon is usually used in English for this purpose.

When used in conversations via email or instant messenger it might have been intended as a sarcasm mark or, in Asian cultures, as an extension of the final syllable to produce the same effect as "whyyyyyy" with "why~~". Used at the end of a word or sentence in text communications, it often denotes something said in a sing-song voice, or similar to the use in instant messengers and email, depending on context.

Mathematics

In mathematics, the tilde, sometimes pronounced "twiddle," is often used to denote an equivalence relation between two objects. Thus "x ~ y" means "x is equivalent to y". (Note that this is usually quite different from stating that x equals y.) The expression "x ~ y" is sometimes read aloud as "x twiddles y," perhaps as an analogue to the verbal expression of "x = y."

There are two common contexts in which "~" is used to denote particular equivalence relations: It can be used to denote the asymptotical equality of two functions. For example, f(x) ~ g(x), means that limx→∞ f(x)/g(x) = 1. Additionally, in statistics and probability theory, ~ means "is distributed as." See random variable.

There is also a triple-tilde (), which is often used to show congruence, an equivalence relation in geometry.

A tilde can also be used to represent Similarity. In modern Geometry, polygons can be similar to one another, and similarity can be expressed as (e.g. Triangle ABC ~ (is similar to) Triangle DEF.) This is often used to relate polygons that have a geometric similarity to others, such as when using ratios and proportions to compare polygons.

In English it is sometimes used to represent approximation, for example ~10 would mean "approximately 10." Similar symbols are used in mathematics, such as in π ≈ 3.14, "π is about equal to 3.14." Since the double-tilde () is not available from the keyboard except on the Macintosh (where it is Option-x on English layouts), the tilde (~) became a substitute for use in typed entry.

A tilde is also used to indicate "approximately equal to" (e.g. 1.902 ~= 2). This usage probably developed as a typed alternative to the libra symbol used for the same purpose in written mathematics, which is an equal sign (=) with the upper bar replaced by a bar with an upward hump or loop in the middle or, sometimes, a tilde. [Also see Approximation]. The symbol "≈" is also used for this purpose.

A tilde placed below a letter in mathematics can represent a vector quantity.

Computing

Directories and URLs

In Unix shells, the tilde indicates the current user's home directory (e.g., /home/username). When prepended to a particular username, it indicates that user's home directory (e.g., ~janedoe for the home directory of user janedoe, typically /home/janedoe). When some Unix shell commands overwrite a file, they can be made to keep a backup by renaming the original file as filename~.

Used in URLs on the World Wide Web, it often denotes a personal website on a Unix-based server. For example, http://www.example.com/~johndoe/ might be the personal web site of John Doe. This mimics the Unix shell usage of the tilde. However, when accessed from the web, file access is usually directed to a subdirectory in the user's home directory, such as /home/username/public_html or /home/username/www.

In URLs, the characters %7E (or %7e) may substitute a tilde if an input device lacks a tilde key. Thus, http://www.example.com/~johndoe/ and http://www.example.com/%7Ejohndoe/ are essentially the same URL.

Computer languages

The tilde is used in the Awk programming language as part of the pattern match operators for regular expressions:

  • variable ~ /regex/ returns true if the variable is matched.
  • variable !~ /regex/ returns false if the variable is matched.

A variant of this, with the plain tilde replaced with =~, was adopted in Perl, and this semi-standardization has led to the use of these operators in other programming languages, such as Ruby or the SQL variant of the database PostgreSQL.

In the C and C++ programming languages, the tilde character is used as an operator to invert all bits of an integer (bitwise NOT), following the notation in logic (an ! causes a logical NOT, instead). In C++, the tilde is also used as the first character in a class's method name (where the rest of the name must be the same name as the class) to indicate a destructor - a special method which is called at the end of the object's life.

In the D programming language, the tilde is used as an array concatenation operator, as well as to indicate an object destructor.

In the CSS stylesheet language, the tilde is used for the indirect adjacent combinator as part of a selector.

In the Inform programming language, the tilde is used to indicate a quotation mark inside a quoted string.

In Max/MSP, a tilde is used to denote objects that process at the computer's sampling rate, i.e. mainly those that deal with sound.

In "text mode" of the LaTeX typesetting language a stand-alone tilde can be obtained with \~{} and for use as a diacritics, e.g., like \~{n} rendering "ñ". In "math mode" a stand-alone tilde can be written as \tilde{~} and as diacritics, e.g., \tilde{x}. For a wider tilde the \widetilde can be used. The \sim command produce a tilde-like character that is often used in probability mathematical equations, and the double-tilde is obtained with \approx. In both text and math mode a tilde on its own (~) is rendering a white space with no line breaking.

The Emacs text editor forms the names used for backup files by appending a tilde to the original file name.

Microsoft filenames

The tilde was part of Microsoft's filename mangling scheme when it developed the VFAT file system. This upgrade introduced long filenames to Microsoft Windows, and permitted additional characters (such as the space) to be part of filenames, which were prohibited in previous versions. Programs written prior to this development could only access filenames in the so-called 8.3 format—the filenames consisted of a maximum of eight alphanumeric characters, followed by a period, followed by three more alphanumeric characters. In order to permit these legacy programs to access files in the VFAT file system, each file had to be given two names—one long, more descriptive one, and one that conformed to the 8.3 format. This was accomplished with a name-mangling scheme in which the first six characters of the filename are followed by a tilde and a digit. For example, "Program Files" becomes "PROGRA~1".

Also, the tilde symbol is used to prefix hidden temporary files that are created when a document is opened in Windows. For example, when you open a Word document called "Document1.doc," a file called "~ocument1.doc" will be created in the same directory. This file contains information about which user has the file open, to prevent multiple users from attempting to change a document at the same time.

Games

In many games, the tilde key is used to open the developer console, this is evident in games such as Quake, Half-Life 2, and Unreal.

Other uses

Computer programmers use the tilde in various ways and often call the symbol (as opposed to the diacritic) a squiggle or a twiddle. According to the Jargon File, other synonyms sometimes used in programming include not, approx, wiggle, enyay (after eñe) and (humorously) sqiggle (Template:PronEng).

In Google search, the tilde entered before a search query word displays listings with that word and synonyms of it.[2]

In MediaWiki, three consecutive tildes (~~~) create a "signature" (which can be customised by the user), five consecutive tildes (~~~~~) result the time in UTC, and four consecutive tildes (~~~~) result in signature followed by the time in UTC.

The tilde following a word or sentence is an increasing popular[citation needed] way of indicating sarcasm in online communication. For example, "I really love the way that I look in lime green~", should be read as a sarcastic or derisive statement indicating the speaker's dislike of lime green. In this context, the tilde can be referred to as the note of sarcasm.

Another recent use of the tilde is to indicate either a "melodic" pronunciation, or a commonly recognized vocal inflection by enclosing a word or entire phrase between a pair of tilde (similar to the use of quotation marks) which indicates that such word or phrase is to be either sung as a tune, ~Happy birthday to you...~, pronounced as a jeer or taunt, ~Nyah, nyah!~, or with a common change in pitch, ~What-EVER!~.[citation needed]

Juggling notation

In the juggling notation system beatmap, tilde can be added to either "hand" in a pair of fields to say "cross the arms with this hand on top". Mills Mess is thus represented as (~2x,1)(1,2x)(2x,~1)*.[3]

Vertical tilde

Unicode has a combining vertical tilde character, at U+033E  ̾. It is used to indicate middle tone in the Lithuanian language[4] and for transliteration of the Cyrillic palatalization sign (U+484   ҄)[citation needed].

Tilde with keyboards

Where a tilde is on the keyboard depends on the computer's language settings according to the following chart. If the keyboard does not have the Alt Gr key it is the right Alt key, and with Macintosh either of Alt/Option keys.

Country A single tilde ~ Tilde over a letter, for example ã
English (Australia) Shift + `
English (Canada) Shift + `
English (UK) Shift + #
English (US) Shift + `
French (Canada) Alt Gr + ç, after them space bar (for two tildes at once Alt Gr + two times ç ). Alt Gr + ç, after them the letter.
French (France) Alt Gr + é, after them space bar (for two tildes at once Alt Gr + two times é ). Alt Gr + é, after them the letter.
French (Switzerland) Alt Gr + ^, after them space bar (for two tildes at once Alt Gr + two times ^ ). Alt Gr + ^, after them the letter.
German (Germany) Alt Gr + +
German (Switzerland) Alt Gr + ^, after them space bar (for two tildes at once Alt Gr + two times ^ ). Alt Gr + ^, after them the letter.
Hindi (India) Shift + Alt Gr + the key on the left from 1 .
Icelandic Alt Gr + ' (same key as ?).
Italian Alt Gr + ì, the first key on the left from backspace.
Norwegian Alt Gr + ¨, after them space bar (for two tildes at once Alt Gr + two times ¨ ). Alt Gr + ¨, after them the letter.
Spanish Alt Gr + 4, after them space bar (for two tildes at once Alt Gr + two times 4 ). Alt Gr + 4, after them the letter.
Swedish Alt Gr + ¨, after them space bar (for two tildes at once Alt Gr + two times ¨ ). Alt Gr + ¨, after them the letter.

See also

References