HOME

TheInfoList



OR:

The tilde (, also ) is a
grapheme In linguistics, a grapheme is the smallest functional unit of a writing system. The word ''grapheme'' is derived from Ancient Greek ('write'), and the suffix ''-eme'' by analogy with ''phoneme'' and other emic units. The study of graphemes ...
or with a number of uses. The name of the character came into English from
Spanish Spanish might refer to: * Items from or related to Spain: **Spaniards are a nation and ethnic group indigenous to Spain **Spanish language, spoken in Spain and many countries in the Americas **Spanish cuisine **Spanish history **Spanish culture ...
, which in turn came from the
Latin Latin ( or ) is a classical language belonging to the Italic languages, Italic branch of the Indo-European languages. Latin was originally spoken by the Latins (Italic tribe), Latins in Latium (now known as Lazio), the lower Tiber area aroun ...
, meaning 'title' or 'superscription'. Its primary use is as a
diacritic A diacritic (also diacritical mark, diacritical point, diacritical sign, or accent) is a glyph added to a letter or to a basic glyph. The term derives from the Ancient Greek (, "distinguishing"), from (, "to distinguish"). The word ''diacrit ...
(accent) in combination with a base letter. Its freestanding form is used in modern texts mainly to indicate
approximation An approximation is anything that is intentionally similar but not exactly equal to something else. Etymology and usage The word ''approximation'' is derived from Latin ''approximatus'', from ''proximus'' meaning ''very near'' and the prefix ...
.


History


Use by medieval scribes

The tilde was originally one of a variety of marks written over an omitted letter or several letters as a
scribal abbreviation Scribal abbreviations, or sigla (grammatical number, singular: siglum), are abbreviations used by ancient and medieval scribes writing in various languages, including Latin, Greek language, Greek, Old English and Old Norse. In modern Textua ...
(a "mark of contraction"). Thus, the commonly used words ''
Anno Domini The terms (AD) and before Christ (BC) are used when designating years in the Gregorian calendar, Gregorian and Julian calendar, Julian calendars. The term is Medieval Latin and means "in the year of the Lord" but is often presented using "o ...
'' were frequently abbreviated to ''Ao Dñi'', with an elevated terminal with a contraction mark placed over the "n". Such a mark could denote the omission of one letter or several letters. This saved on the expense of the scribe's labor and the cost of vellum and ink. Medieval European charters written in Latin are largely made up of such abbreviated words with contraction marks and other abbreviations; only uncommon words were given in full. The text of the
Domesday Book Domesday Book ( ; the Middle English spelling of "Doomsday Book") is a manuscript record of the Great Survey of much of England and parts of Wales completed in 1086 at the behest of William the Conqueror. The manuscript was originally known by ...
of 1086, relating for example, to the
manor of Molland The Manor of Molland was a Middle Ages, medieval manor house, manor in North Devon, England. It was largely co-terminous with the parish of Molland, where it was situated the village of Molland. More accurately, it consisted of two separate ma ...
in
Devon Devon ( ; historically also known as Devonshire , ) is a ceremonial county in South West England. It is bordered by the Bristol Channel to the north, Somerset and Dorset to the east, the English Channel to the south, and Cornwall to the west ...
(see adjacent picture), is highly
abbreviated An abbreviation () is a shortened form of a word or phrase, by any method including shortening, contraction, initialism (which includes acronym), or crasis. An abbreviation may be a shortened form of a word, usually ended with a trailing per ...
as indicated by numerous tildes. The text with abbreviations expanded is as follows: :


Role of mechanical typewriters

On
typewriter A typewriter is a Machine, mechanical or electromechanical machine for typing characters. Typically, a typewriter has an array of Button (control), keys, and each one causes a different single character to be produced on paper by striking an i ...
s designed for languages that routinely use
diacritic A diacritic (also diacritical mark, diacritical point, diacritical sign, or accent) is a glyph added to a letter or to a basic glyph. The term derives from the Ancient Greek (, "distinguishing"), from (, "to distinguish"). The word ''diacrit ...
s (accent marks), there are two possible solutions. Keys can be dedicated to
precomposed character A precomposed character (alternatively composite character or decomposable character) is a Unicode entity that can also be defined as a sequence of one or more other characters. A precomposed character may typically represent a letter with a diac ...
s or alternatively a
dead key A dead key is a special kind of modifier key on a mechanical typewriter, or computer keyboard, that is typically used to attach a specific diacritic to a base letter (alphabet), letter. The dead key does not generate a (complete) grapheme, charact ...
mechanism can be provided. With the latter, a mark is made when a dead key is typed, but unlike normal keys, the paper carriage does not move on and thus the next letter to be typed is printed under that accent. Typewriters for
Spanish Spanish might refer to: * Items from or related to Spain: **Spaniards are a nation and ethnic group indigenous to Spain **Spanish language, spoken in Spain and many countries in the Americas **Spanish cuisine **Spanish history **Spanish culture ...
typically have a dedicated key for Ñ/ñ but, as Portuguese uses Ã/ã and Õ/õ, a single dead-key (rather than take two keys to dedicate) is the most practical solution. The tilde symbol did not exist independently as a
movable type Movable type (US English; moveable type in British English) is the system and technology of printing and typography that uses movable Sort (typesetting), components to reproduce the elements of a document (usually individual alphanumeric charac ...
or hot-lead printing character since the
type case A type case is a compartmentalized wooden box used to store movable type used in letterpress printing.Williams, Fred (1992). "Origin of the California Job Case". ''Type & Press'', fall 1992. http://www.apa-letterpress.com/T%20&%20P%20ARTICLES/T ...
s for Spanish or Portuguese would include sorts for the accented forms.


The centralized ASCII tilde

The first
ASCII ASCII ( ), an acronym for American Standard Code for Information Interchange, is a character encoding standard for representing a particular set of 95 (English language focused) printable character, printable and 33 control character, control c ...
standard (X3.64-1963) did not have a tilde. Like Portuguese and Spanish, the French, German and Scandinavian languages also needed symbols in excess of the basic 26 needed for English. The ASA worked with and through the
CCITT The International Telecommunication Union Telecommunication Standardization Sector (ITU-T) is one of the three Sectors (branches) of the International Telecommunication Union (ITU). It is responsible for coordinating standards for telecommunicat ...
to internationalize the code-set, to meet the basic needs of at least the Western European languages. Thus ISO646 was born (and the ASCII standard updated to X3.64-1967), providing the tilde and other symbols as optional characters. ISO646 and ASCII incorporated many of the overprinting lower-case diacritics from typewriters, including tilde. Overprinting was intended to work by putting a
backspace Backspace (, ⌫) is the keyboard key that in typewriters originally pushed the carriage one position backwards, and in modern computer systems typically moves the display cursor one position backwards,The meaning of "backwards" depends on the dir ...
code between the codes for letter and diacritic. The free-standing tilde is at code 126 in ASCII, where it was inherited into Unicode as U+007E. A similar shaped mark () is known in typography and
lexicography Lexicography is the study of lexicons and the art of compiling dictionaries. It is divided into two separate academic disciplines: * Practical lexicography is the art or craft of compiling, writing and editing dictionaries. * Theoretical le ...
as a swung dash: these are used in dictionaries to indicate the omission of the entry word.


Connection to Spanish

As indicated by the etymological origin of the word "tilde" in English, this symbol has been closely associated with the
Spanish language Spanish () or Castilian () is a Romance languages, Romance language of the Indo-European languages, Indo-European language family that evolved from the Vulgar Latin spoken on the Iberian Peninsula of Europe. Today, it is a world language, gl ...
. The connection stems from the use of the tilde above the letter to form the (different) letter in Spanish, a feature shared by only a few other languages, most of which are historically connected to Spanish. This peculiarity can help non-native speakers quickly identify a text as being written in Spanish with little chance of error. Particularly during the 1990s, Spanish-speaking intellectuals and news outlets demonstrated support for the language and the culture by defending this letter against
globalisation Globalization is the process of increasing interdependence and integration among the economies, markets, societies, and cultures of different countries worldwide. This is made possible by the reduction of barriers to international trade, th ...
and
computer A computer is a machine that can be Computer programming, programmed to automatically Execution (computing), carry out sequences of arithmetic or logical operations (''computation''). Modern digital electronic computers can perform generic set ...
isation trends that threatened to remove it from keyboards and other standardised products and codes. The
Instituto Cervantes Instituto Cervantes (, the Cervantes Institute) is a worldwide nonprofit organization created by the Spanish government in 1991. It is named after Miguel de Cervantes (1547–1616), the author of ''Don Quixote'' and perhaps the most important fi ...
, founded by Spain's government to promote the Spanish language internationally, chose as its logo a highly stylised with a large tilde. The 24-hour news channel
CNN Cable News Network (CNN) is a multinational news organization operating, most notably, a website and a TV channel headquartered in Atlanta. Founded in 1980 by American media proprietor Ted Turner and Reese Schonfeld as a 24-hour cable ne ...
in the US later adopted a similar strategy on its existing logo for the launch of its Spanish-language version, therefore being written as CN͠N. And similarly to the
National Basketball Association The National Basketball Association (NBA) is a professional basketball league in North America composed of 30 teams (29 in the United States and 1 in Canada). The NBA is one of the major professional sports leagues in the United States and Ca ...
(NBA), the
Spain men's national basketball team The Spain men's national basketball team () represents Spain in international basketball competitions. They are managed by the Spanish Basketball Federation, the governing body for basketball in Spain. Spain is the current European champion. Sp ...
is nicknamed "ÑBA". In Spanish itself the word is used more generally for diacritics, including the stress-marking acute accent. The diacritic is more commonly called or , and is not considered an accent mark in Spanish, but rather simply a part of the letter (much like the dot over makes an character that is familiar to readers of English).


Usage


Common use in English

The
English language English is a West Germanic language that developed in early medieval England and has since become a English as a lingua franca, global lingua franca. The namesake of the language is the Angles (tribe), Angles, one of the Germanic peoples th ...
does not use the tilde as a diacritic, though it is used in some
loanword A loanword (also a loan word, loan-word) is a word at least partly assimilated from one language (the donor language) into another language (the recipient or target language), through the process of borrowing. Borrowing is a metaphorical term t ...
s. The standalone form of the symbol is used more widely. Informally, it means "approximately", "about", or "around", such as "~30 minutes before", meaning "''approximately'' 30 minutes before". It may also mean "similar to", including "of the same
order of magnitude In a ratio scale based on powers of ten, the order of magnitude is a measure of the nearness of two figures. Two numbers are "within an order of magnitude" of each other if their ratio is between 1/10 and 10. In other words, the two numbers are ...
as", such as "" meaning that and are of the same order of magnitude. Another approximation symbol is the double tilde , meaning "approximately/almost equal to". The tilde is also used to indicate congruence of shapes by placing it over an symbol, thus . In more recent digital usage, tildes on either side of a word or phrase have sometimes come to convey a particular tone that "let the enclosed words perform both sincerity and irony", which can pre-emptively defuse a negative reaction. For example,
BuzzFeed BuzzFeed, Inc. is an American Internet mass media, media, news and entertainment company with a focus on digital media. Based in New York City, BuzzFeed was founded in 2006 by Jonah Peretti and John Seward Johnson III, John S. Johnson III to ...
journalist Joseph Bernstein interprets the tildes in the following tweet:
in the ~ spirit of the season ~ will now link to some of the (imho) #Bestof2014 sports reads. if you hate nice things, mute that hashtag.
as a way of making it clear that both the author and reader are aware that the enclosed phrase – "spirit of the season" – "is cliche and we know this quality is beneath our author, and we don't want you to think our author is a cliche person generally". Among other uses, the symbol has been used on
social media Social media are interactive technologies that facilitate the Content creation, creation, information exchange, sharing and news aggregator, aggregation of Content (media), content (such as ideas, interests, and other forms of expression) amongs ...
to indicate sarcasm. It may also be used online, especially in informal writing such as
fanfiction Fan fiction or fanfiction, also known as fan fic, fanfic, fic or FF, is fiction typically written in an amateur capacity by fans as a form of fan labor, unauthorized by, but based on, an existing work of fiction. The author uses copyrighted ...
, to convey a cutesy, playful, or flirtatious tone.


Diacritical use

In some languages, the tilde is a
diacritic A diacritic (also diacritical mark, diacritical point, diacritical sign, or accent) is a glyph added to a letter or to a basic glyph. The term derives from the Ancient Greek (, "distinguishing"), from (, "to distinguish"). The word ''diacrit ...
mark placed over a letter to indicate a change in its pronunciation:


Pitch

The tilde was firstly used in the
polytonic orthography Greek orthography has used a variety of diacritics starting in the Hellenistic period. The more complex polytonic orthography (), which includes five diacritics, notates Ancient Greek phonology. The simpler monotonic orthography (), introduce ...
of
Ancient Greek Ancient Greek (, ; ) includes the forms of the Greek language used in ancient Greece and the classical antiquity, ancient world from around 1500 BC to 300 BC. It is often roughly divided into the following periods: Mycenaean Greek (), Greek ...
, as a variant of the
circumflex The circumflex () is a diacritic in the Latin and Greek scripts that is also used in the written forms of many languages and in various romanization and transcription schemes. It received its English name from "bent around"a translation of ...
, representing a rise in pitch followed by a return to standard pitch.


Abbreviation

Later, it was used to make
abbreviations An abbreviation () is a shortened form of a word or phrase, by any method including shortening, contraction, initialism (which includes acronym), or crasis. An abbreviation may be a shortened form of a word, usually ended with a trailing per ...
in medieval
Latin Latin ( or ) is a classical language belonging to the Italic languages, Italic branch of the Indo-European languages. Latin was originally spoken by the Latins (Italic tribe), Latins in Latium (now known as Lazio), the lower Tiber area aroun ...
documents. When an or followed a vowel, it was often omitted, and a tilde (physically, a small ) was placed over the preceding vowel to indicate the missing letter; this is the origin of the use of tilde to indicate nasalization (compare the development of the umlaut as an abbreviation of .) A tilde represented an omitted or a syllable containing it. The practice of using the tilde over a vowel to indicate omission of an or continued in printed books in French as a means of reducing text length until the 17th century. It was also used in Portuguese and
Spanish Spanish might refer to: * Items from or related to Spain: **Spaniards are a nation and ethnic group indigenous to Spain **Spanish language, spoken in Spain and many countries in the Americas **Spanish cuisine **Spanish history **Spanish culture ...
. The tilde was also used occasionally to make other abbreviations, such as over the letter , making , to signify the word ''que'' ("that"). It also appears for ''qua'' and together with the letter to form for ''pra''.


Nasalization

It is also as a small that the tilde originated when written above other letters, marking a
Latin Latin ( or ) is a classical language belonging to the Italic languages, Italic branch of the Indo-European languages. Latin was originally spoken by the Latins (Italic tribe), Latins in Latium (now known as Lazio), the lower Tiber area aroun ...
which had been elided in old Galician-Portuguese. In modern Portuguese it indicates
nasalization In phonetics, nasalization (or nasalisation in British English) is the production of a sound while the velum is lowered, so that some air escapes through the nose during the production of the sound by the mouth. An archetypal nasal sound is . ...
of the base vowel: "hand", from Lat. ''manu-''; "reasons", from Lat. . This usage has been adopted in the orthographies of several native languages of South America, such as Guarani and Nheengatu, as well as in the
International Phonetic Alphabet The International Phonetic Alphabet (IPA) is an alphabetic system of phonetic notation based primarily on the Latin script. It was devised by the International Phonetic Association in the late 19th century as a standard written representation ...
(IPA) and many other phonetic alphabets. For example, is the IPA transcription of the pronunciation of the French place-name ''
Lyon Lyon (Franco-Provençal: ''Liyon'') is a city in France. It is located at the confluence of the rivers Rhône and Saône, to the northwest of the French Alps, southeast of Paris, north of Marseille, southwest of Geneva, Switzerland, north ...
''. In Breton, the symbol after a vowel means that the letter serves only to give the vowel a nasalised pronunciation, without being itself pronounced, as it normally is. For example, gives the pronunciation whereas gives . In the
DMG DMG may refer to: Organizations Entertainment * DMG Clearances, music licensor in Delaware, USA * DMG Entertainment, a Chinese-based film production and distribution company * DMG Nashville, a brand of Hollywood Records specializing in country musi ...
romanization of
Tunisian Arabic Tunisian Arabic, or simply Tunisian (), is a Varieties of Arabic, variety of Arabic spoken in Tunisia. It is known among its 13 million speakers as ''Tūnsi'', "Tunisian" or ''Maghrebi Arabic, Derja'' (; meaning "common or everyday dialect") t ...
, the tilde is used for nasal vowels õ and ṏ.


Palatal n

The tilded (, ) developed from the digraph in Spanish. In this language, is considered a separate letter called '' eñe'' (), rather than a letter-diacritic combination; it is placed in Spanish dictionaries between the letters and . In Spanish, the word ''tilde'' actually refers to diacritics in general, e.g. the acute accent in ''José'', while the diacritic in is called "virgulilla" () ( yeísta) or () (non-yeísta). Current languages in which the tilded () is used for the
palatal nasal The voiced palatal nasal is a type of consonant used in some spoken languages. The symbol in the International Phonetic Alphabet that represents this sound is , a lowercase letter ''n'' with a leftward-pointing tail protruding from the bottom ...
consonant include * Asturian * Aymara *
Basque Basque may refer to: * Basques, an ethnic group of Spain and France * Basque language, their language Places * Basque Country (greater region), the homeland of the Basque people with parts in both Spain and France * Basque Country (autonomous co ...
* Chamorro * Filipino * Galician * Guaraní * Iñupiaq *
Mapudungun Mapuche ( , ; from 'land' and 'people', meaning 'the people of the land') or Mapudungun (from 'land' and 'speak, speech', meaning 'the speech of the land'; also spelled Mapuzugun and Mapudungu) is either a language isolate or member of the s ...
*
Papiamento Papiamento () or Papiamentu (; ) is a Portuguese-based creole language spoken in the Dutch Caribbean. It is the most widely spoken language on Aruba, Bonaire, and Curaçao ( ABC Islands). The language, spelled in Aruba and in Bonaire and ...
* Quechua *
Spanish Spanish might refer to: * Items from or related to Spain: **Spaniards are a nation and ethnic group indigenous to Spain **Spanish language, spoken in Spain and many countries in the Americas **Spanish cuisine **Spanish history **Spanish culture ...
*
Tetum Tetum may refer to: * Tetum language, an Austronesian language ** Tetum alphabet, used to write the Tetum language * Tetum people, an ethnic group of East Timor and Indonesia {{disambiguation Language and nationality disambiguation pages ...
* Wolof


Tone

In Vietnamese, a tilde over a vowel represents a creaky rising
tone Tone may refer to: Visual arts and color-related * Tone (color theory), a mix of tint and shade, in painting and color theory * Tone (color), the lightness or brightness (as well as darkness) of a color * Toning (coin), color change in coins * ...
(''ngã''). Letters with the tilde are not considered separate letters of the
Vietnamese alphabet The Vietnamese alphabet (, ) is the modern writing script for the Vietnamese language. It uses the Latin script based on Romance languages like French language, French, originally developed by Francisco de Pina (1585–1625), a missionary from P ...
.


International Phonetic Alphabet

In
phonetics Phonetics is a branch of linguistics that studies how humans produce and perceive sounds or, in the case of sign languages, the equivalent aspects of sign. Linguists who specialize in studying the physical properties of speech are phoneticians ...
, a tilde is used as a diacritic that is placed above a letter, below it or
superimpose Superimposition is the placement of one thing over another, typically so that both are still evident. Superimpositions are often related to the mathematical procedure of superposition. Audio Superimposition (SI) during sound recording and repro ...
d onto the middle of it: * A tilde above a letter indicates
nasalization In phonetics, nasalization (or nasalisation in British English) is the production of a sound while the velum is lowered, so that some air escapes through the nose during the production of the sound by the mouth. An archetypal nasal sound is . ...
, e.g. . * A tilde superimposed onto the middle of a letter indicates
velarization Velarization merican spelling/small> or velarisation ritish spelling/sup> is a secondary articulation of consonants by which the back of the tongue is raised toward the velum during the articulation of the consonant. In the International Ph ...
or
pharyngealization Pharyngealization is a secondary articulation of consonants or vowels by which the pharynx or epiglottis is constricted during the articulation of the sound. IPA symbols In the International Phonetic Alphabet, pharyngealization can be indicate ...
, e.g. . If no precomposed
Unicode Unicode or ''The Unicode Standard'' or TUS is a character encoding standard maintained by the Unicode Consortium designed to support the use of text in all of the world's writing systems that can be digitized. Version 16.0 defines 154,998 Char ...
character exists, the Unicode character can be used to generate one. * A tilde below a letter indicates laryngealisation, e.g. . If no precomposed Unicode character exists, the Unicode character can be used to generate one. A tilde between two
phoneme A phoneme () is any set of similar Phone (phonetics), speech sounds that are perceptually regarded by the speakers of a language as a single basic sound—a smallest possible Phonetics, phonetic unit—that helps distinguish one word fr ...
s indicates optionality, or "alternates with". E.g. could indicate that the sounds may alternate depending on context (
free variation In linguistics, free variation is the phenomenon of two (or more) sounds or forms appearing in the same environment without a change in meaning and without being considered incorrect by native speakers. Sociolinguists argue that describing such ...
), or that they vary based on region or speaker, or some other variation.


Letter extension

In
Estonian Estonian may refer to: * Something of, from, or related to Estonia, a country in the Baltic region in northern Europe * Estonians, people from Estonia, or of Estonian descent * Estonian language * Estonian cuisine * Estonian culture See also

...
, the symbol stands for the
close-mid back unrounded vowel The close-mid back unrounded vowel, or high-mid back unrounded vowel, is a type of vowel sound, used in some spoken languages. Its symbol in the International Phonetic Alphabet is , called "ram's horn." This symbol is distinct from the symbol ...
, and it is considered an independent letter.


Other uses

Some languages and alphabets use the tilde for other purposes, such as: *
Arabic script The Arabic script is the writing system used for Arabic (Arabic alphabet) and several other languages of Asia and Africa. It is the second-most widely used alphabetic writing system in the world (after the Latin script), the second-most widel ...
: A symbol resembling the tilde () is used over the letter () to become , denoting a long sound. * Guaraní: The tilded (note that with tilde is not available as a precomposed glyph in
Unicode Unicode or ''The Unicode Standard'' or TUS is a character encoding standard maintained by the Unicode Consortium designed to support the use of text in all of the world's writing systems that can be digitized. Version 16.0 defines 154,998 Char ...
) stands for the
velar nasal The voiced velar nasal, also known as eng, engma, or agma (from Greek 'fragment'), is a type of consonantal sound used in some spoken languages. It is the sound of ''ng'' in English ''sing'' as well as ''n'' before velar consonants as in ''E ...
consonant. Also, the tilded () stands for the nasalized upper central rounded vowel .
Munduruku The Munduruku, also known as Mundurucu or Wuy Jugu, are an indigenous people of Brazil living in the Amazon River basin. Some Munduruku communities are part of the Coatá-Laranjal Indigenous Land. They had an estimated population in 2014 of 13 ...
, Parintintín, and two older spellings of Filipino words also use . *
Syriac script The Syriac alphabet ( ) is a writing system primarily used to write the Syriac language since the 1st century. It is one of the Semitic languages, Semitic abjads descending from the Aramaic alphabet through the Palmyrene alphabet, and shares sim ...
: A tilde (~) under the letter ''
Kaph Kaph (also spelled kaf) is the eleventh letter of the Semitic abjads, including Phoenician ''kāp'' 𐤊, Hebrew ''kāp̄'' , Aramaic ''kāp'' 𐡊, Syriac ''kāp̄'' ܟ, and Arabic ''kāf'' (in abjadi order). It is also related to the Anc ...
'' represents a sound, transliterated as ''ch'' or ''č''. *
Estonian Estonian may refer to: * Something of, from, or related to Estonia, a country in the Baltic region in northern Europe * Estonians, people from Estonia, or of Estonian descent * Estonian language * Estonian cuisine * Estonian culture See also

...
and Võro use the tilde above the letter o (õ) to indicate the vowel , a rare sound among languages. *
Unicode Unicode or ''The Unicode Standard'' or TUS is a character encoding standard maintained by the Unicode Consortium designed to support the use of text in all of the world's writing systems that can be digitized. Version 16.0 defines 154,998 Char ...
has a combining vertical tilde character: . It is used to indicate middle tone in linguistic transcription of certain dialects of the
Lithuanian language Lithuanian (, ) is an East Baltic languages, East Baltic language belonging to the Baltic languages, Baltic branch of the Indo-European language family. It is the language of Lithuanians and the official language of Lithuania as well as one of t ...
, and was also used historically in the letter х̾, which was part of the Polish Cyrillic alphabet of the late 19th century. * Resurrección María de Azkue's 1906 Basque dictionary used an idiosyncratic spelling including .


Punctuation

The tilde is used in various ways in punctuation, including: In some languages (such as in French), a tilde or a tilde-like wave dash (Unicode: ) may be used as a
punctuation Punctuation marks are marks indicating how a piece of writing, written text should be read (silently or aloud) and, consequently, understood. The oldest known examples of punctuation marks were found in the Mesha Stele from the 9th century BC, c ...
mark (instead of an unspaced
hyphen The hyphen is a punctuation mark used to join words and to separate syllables of a single word. The use of hyphens is called hyphenation. The hyphen is sometimes confused with dashes (en dash , em dash and others), which are wider, or with t ...
,
en dash The dash is a punctuation mark consisting of a long horizontal line. It is similar in appearance to the hyphen but is longer and sometimes higher from the baseline. The most common versions are the endash , generally longer than the hyphen ...
or
em dash The dash is a punctuation mark consisting of a long horizontal line. It is similar in appearance to the hyphen but is longer and sometimes higher from the baseline. The most common versions are the endash , generally longer than the hyphen ...
) between two
number A number is a mathematical object used to count, measure, and label. The most basic examples are the natural numbers 1, 2, 3, 4, and so forth. Numbers can be represented in language with number words. More universally, individual numbers can ...
s, to indicate a
range Range may refer to: Geography * Range (geographic), a chain of hills or mountains; a somewhat linear, complex mountainous or hilly area (cordillera, sierra) ** Mountain range, a group of mountains bordered by lowlands * Range, a term used to i ...
. Doing so avoids the risk of confusion with
subtraction Subtraction (which is signified by the minus sign, –) is one of the four Arithmetic#Arithmetic operations, arithmetic operations along with addition, multiplication and Division (mathematics), division. Subtraction is an operation that repre ...
or a hyphenated number (such as a part number or model number). For example, "12~15" means "12 to 15", "~3" means "up to three", and "100~" means "100 and greater".
East Asian languages The East Asian languages are a language family (alternatively '' macrofamily'' or ''superphylum'') proposed by Stanley Starosta in 2001. The proposal has since been adopted by George van Driem and others. Classifications Early proposals Early ...
almost always use this convention, but it is sometimes done for clarity in some other languages as well. Chinese uses the wave dash and
full-width In CJK (Chinese, Japanese, and Korean) computing, graphic characters are traditionally classed into fullwidth and halfwidth characters. Unlike monospaced fonts, a halfwidth character occupies half the width of a fullwidth character, hence the na ...
em dash interchangeably for this purpose. In English, the tilde is often used to express ranges and model numbers in
electronics Electronics is a scientific and engineering discipline that studies and applies the principles of physics to design, create, and operate devices that manipulate electrons and other Electric charge, electrically charged particles. It is a subfield ...
, but rarely in formal grammar or in type-set documents, as a wavy dash preceding a number sometimes represents an approximation (see below). The range tilde is used for various purposes in French, but only to denote ranges of numbers (e.g., " means "21 to 32 degrees Celsius"). (The symbol (a double tilde) is also used in French, for example, means "approximately 400 meters".)


Approximation

Before a number, the tilde can mean "approximately": e.g., "~42" means "approximately 42". When used with
currency symbol A currency symbol or currency sign is a graphic symbol used to denote a currency unit. Usually it is defined by a monetary authority, such as the national central bank for the currency concerned. A symbol may be positioned in various ways, acc ...
s that precede the number (national conventions differ), the tilde precedes the symbol, thus for example "~$10" means "about ten dollars". The symbols (almost equal to) and (approximately equal to) are among the other symbols used to express approximation.


Japanese

The is used for various purposes in Japanese, including to denote ranges of numbers (e.g., ''5〜10'' means between 5 and 10) in place of dashes or brackets, and to indicate origin. The wave dash is also used to separate a title and a subtitle in the same line, as a colon is used in English. When used in conversations via email or instant messenger it may be used as a sarcasm mark. The sign is used as a replacement for the , katakana character, in Japanese, extending the final syllable.


Chinese

WeChat WeChat or Weixin in Chinese ( zh, c=微信, p=Wēixìn , l=micro-message) is an instant messaging, social media, and mobile payment mobile app, app developed by Tencent. First released in 2011, it became the world's largest standalone mobile a ...
users frequently replace final punctuation with tildes in messages. An analysis of such "innovative uses" of tildes found that final tildes are most used to make the message friendlier and polite. They make expressives more sincere and directives less abrupt. Less commonly, final tildes imply sounds, i.e. otomatopeas and sound extensions. This use is compared to ''sajiao'' (), a child-like acting seen in East Asian cultures that are also vocalized by raising or extending tone.


Mathematics


As a unary operator

A tilde in front of a single quantity can mean "approximately", "about" or "of the same
order of magnitude In a ratio scale based on powers of ten, the order of magnitude is a measure of the nearness of two figures. Two numbers are "within an order of magnitude" of each other if their ratio is between 1/10 and 10. In other words, the two numbers are ...
as." In written
mathematical logic Mathematical logic is the study of Logic#Formal logic, formal logic within mathematics. Major subareas include model theory, proof theory, set theory, and recursion theory (also known as computability theory). Research in mathematical logic com ...
, the tilde represents
negation In logic, negation, also called the logical not or logical complement, is an operation (mathematics), operation that takes a Proposition (mathematics), proposition P to another proposition "not P", written \neg P, \mathord P, P^\prime or \over ...
: "~''p''" means "not ''p''", where "''p''" is a
proposition A proposition is a statement that can be either true or false. It is a central concept in the philosophy of language, semantics, logic, and related fields. Propositions are the object s denoted by declarative sentences; for example, "The sky ...
. Modern use often replaces the tilde with the negation symbol (¬) for this purpose, to avoid confusion with
equivalence relation In mathematics, an equivalence relation is a binary relation that is reflexive, symmetric, and transitive. The equipollence relation between line segments in geometry is a common example of an equivalence relation. A simpler example is equ ...
s.


As a relational operator

In
mathematics Mathematics is a field of study that discovers and organizes methods, Mathematical theory, theories and theorems that are developed and Mathematical proof, proved for the needs of empirical sciences and mathematics itself. There are many ar ...
, the tilde operator (which can be represented by a tilde or the dedicated character ), sometimes called "twiddle", is often used to denote an
equivalence relation In mathematics, an equivalence relation is a binary relation that is reflexive, symmetric, and transitive. The equipollence relation between line segments in geometry is a common example of an equivalence relation. A simpler example is equ ...
between two objects. Thus "" means " is
equivalent Equivalence or Equivalent may refer to: Arts and entertainment *Album-equivalent unit, a measurement unit in the music industry *Equivalence class (music) *'' Equivalent VIII'', or ''The Bricks'', a minimalist sculpture by Carl Andre *'' Equiva ...
to ". It is a weaker statement than stating that equals . The expression "" is sometimes read aloud as " twiddles ", perhaps as an analogue to the verbal expression of "". The tilde can indicate approximate equality in a variety of ways. It can be used to denote the asymptotic equality of two functions. For example, means that \lim_ \frac = 1. 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, bump, or loop in the middle (︍︍♎︎) or, sometimes, a tilde (≃). The symbol "≈" is also used for this purpose. In
physics Physics is the scientific study of matter, its Elementary particle, fundamental constituents, its motion and behavior through space and time, and the related entities of energy and force. "Physical science is that department of knowledge whi ...
and
astronomy Astronomy is a natural science that studies celestial objects and the phenomena that occur in the cosmos. It uses mathematics, physics, and chemistry in order to explain their origin and their overall evolution. Objects of interest includ ...
, a tilde can be used between two expressions (e.g. ) to state that the two are of the same
order of magnitude In a ratio scale based on powers of ten, the order of magnitude is a measure of the nearness of two figures. Two numbers are "within an order of magnitude" of each other if their ratio is between 1/10 and 10. In other words, the two numbers are ...
. In
statistics Statistics (from German language, German: ', "description of a State (polity), state, a country") is the discipline that concerns the collection, organization, analysis, interpretation, and presentation of data. In applying statistics to a s ...
and
probability theory Probability theory or probability calculus is the branch of mathematics concerned with probability. Although there are several different probability interpretations, probability theory treats the concept in a rigorous mathematical manner by expre ...
, the tilde means "is distributed as"; see
random variable A random variable (also called random quantity, aleatory variable, or stochastic variable) is a Mathematics, mathematical formalization of a quantity or object which depends on randomness, random events. The term 'random variable' in its mathema ...
(e.g. for a
binomial distribution In probability theory and statistics, the binomial distribution with parameters and is the discrete probability distribution of the number of successes in a sequence of statistical independence, independent experiment (probability theory) ...
). A tilde can also be used to represent geometric similarity (e.g. , meaning
triangle A triangle is a polygon with three corners and three sides, one of the basic shapes in geometry. The corners, also called ''vertices'', are zero-dimensional points while the sides connecting them, also called ''edges'', are one-dimension ...
is similar to ). A triple tilde (≋) is often used to show congruence, an equivalence relation in geometry. In
graph theory In mathematics and computer science, graph theory is the study of ''graph (discrete mathematics), graphs'', which are mathematical structures used to model pairwise relations between objects. A graph in this context is made up of ''Vertex (graph ...
, the tilde can be used to represent adjacency between vertices. The edge (x,y) connects vertices x and y which can be said to be adjacent, and this adjacency can be denoted x \sim y.


As a diacritic

The symbol "\tilde" is pronounced as "eff tilde" or, informally, as "eff twiddle". This can be used to denote the
Fourier transform In mathematics, the Fourier transform (FT) is an integral transform that takes a function as input then outputs another function that describes the extent to which various frequencies are present in the original function. The output of the tr ...
of ''f'', or a
lift Lift or LIFT may refer to: Physical devices * Elevator, or lift, a device used for raising and lowering people or goods ** Paternoster lift, a type of lift using a continuous chain of cars which do not stop ** Patient lift, or Hoyer lift, mobile ...
of ''f'', and can have a variety of other meanings depending on the context. A tilde placed below a letter in mathematics can represent a
vector Vector most often refers to: * Euclidean vector, a quantity with a magnitude and a direction * Disease vector, an agent that carries and transmits an infectious pathogen into another living organism Vector may also refer to: Mathematics a ...
quantity (e.g. (x_1, x_2, x_3, \ldots, x_n) = \underset). In
statistics Statistics (from German language, German: ', "description of a State (polity), state, a country") is the discipline that concerns the collection, organization, analysis, interpretation, and presentation of data. In applying statistics to a s ...
and
probability theory Probability theory or probability calculus is the branch of mathematics concerned with probability. Although there are several different probability interpretations, probability theory treats the concept in a rigorous mathematical manner by expre ...
, a tilde placed on top of a variable is sometimes used to represent the
median The median of a set of numbers is the value separating the higher half from the lower half of a Sample (statistics), data sample, a statistical population, population, or a probability distribution. For a data set, it may be thought of as the “ ...
of that variable; thus \tilde would indicate the median of the variable \mathbf y. A tilde over the letter n (\tilde) is sometimes used to indicate the
harmonic mean In mathematics, the harmonic mean is a kind of average, one of the Pythagorean means. It is the most appropriate average for ratios and rate (mathematics), rates such as speeds, and is normally only used for positive arguments. The harmonic mean ...
. In machine learning, a tilde may represent a candidate value for a cell state in GRUs or
LSTM Long short-term memory (LSTM) is a type of recurrent neural network (RNN) aimed at mitigating the vanishing gradient problem commonly encountered by traditional RNNs. Its relative insensitivity to gap length is its advantage over other RNNs, hi ...
units. (e.g. c̃)


Physics

Often in
physics Physics is the scientific study of matter, its Elementary particle, fundamental constituents, its motion and behavior through space and time, and the related entities of energy and force. "Physical science is that department of knowledge whi ...
, one can consider an equilibrium solution to an equation, and then a perturbation to that equilibrium. For the variables in the original equation (for instance X) a substitution X\to x+\tilde can be made, where x is the equilibrium part and \tilde is the perturbed part. A tilde is also used in
particle physics Particle physics or high-energy physics is the study of Elementary particle, fundamental particles and fundamental interaction, forces that constitute matter and radiation. The field also studies combinations of elementary particles up to the s ...
to denote the hypothetical supersymmetric partner. For example, an
electron The electron (, or in nuclear reactions) is a subatomic particle with a negative one elementary charge, elementary electric charge. It is a fundamental particle that comprises the ordinary matter that makes up the universe, along with up qua ...
is referred to by the letter ''e'', and its
superpartner In particle physics, a superpartner (also sparticle) is a class of hypothetical elementary particles predicted by supersymmetry, which, among other applications, is one of the well-studied ways to extend the Standard Model of high-energy physics. ...
the selectron is written ''ẽ''. In multibody mechanics, the tilde operator maps three-dimensional vectors \boldsymbol\in\mathbb^3 to skew-symmetrical matrices \tilde=\begin0&-\omega_3& \omega_2\\ \omega_3& 0& -\omega_1\\ -\omega_2&\omega_1&0\end (see or ).


Economics

For relations involving preference,
economist An economist is a professional and practitioner in the social sciences, social science discipline of economics. The individual may also study, develop, and apply theories and concepts from economics and write about economic policy. Within this ...
s sometimes use the tilde to represent indifference between two or more bundles of goods. For example, to say that a consumer is indifferent between bundles ''x'' and ''y'', an economist would write ''x'' ~ ''y''.


Electronics

It can approximate the sine wave symbol (∿, U+223F), which is used in
electronics Electronics is a scientific and engineering discipline that studies and applies the principles of physics to design, create, and operate devices that manipulate electrons and other Electric charge, electrically charged particles. It is a subfield ...
to indicate
alternating current Alternating current (AC) is an electric current that periodically reverses direction and changes its magnitude continuously with time, in contrast to direct current (DC), which flows only in one direction. Alternating current is the form in w ...
, in place of +, −, or ⎓ for
direct current Direct current (DC) is one-directional electric current, flow of electric charge. An electrochemical cell is a prime example of DC power. Direct current may flow through a conductor (material), conductor such as a wire, but can also flow throug ...
.


Linguistics

The tilde may indicate alternating
allomorph In linguistics, an allomorph is a variant phonetic form of a morpheme, or in other words, a unit of meaning that varies in sound and spelling without changing the meaning. The term ''allomorph'' describes the realization of phonological variatio ...
s or morphological alternation, as in for ''kneel~knelt'' (the
plus sign The plus sign () and the minus sign () are mathematical symbols used to denote positive and negative functions, respectively. In addition, the symbol represents the operation of addition, which results in a sum, while the symbol represents ...
'+' indicates a morpheme boundary). The tilde may represent some sort of phonetic or phonemic variation between two sounds, which might be
allophone In phonology, an allophone (; from the Greek , , 'other' and , , 'voice, sound') is one of multiple possible spoken soundsor '' phones''used to pronounce a single phoneme in a particular language. For example, in English, the voiceless plos ...
s or in
free variation In linguistics, free variation is the phenomenon of two (or more) sounds or forms appearing in the same environment without a change in meaning and without being considered incorrect by native speakers. Sociolinguists argue that describing such ...
. For example, can represent "either or ". In formal semantics, it is also used as a notation for the '' squiggle operator'' which plays a key role in many theories of
focus Focus (: foci or focuses) may refer to: Arts * Focus or Focus Festival, former name of the Adelaide Fringe arts festival in East Australia Film *Focus (2001 film), ''Focus'' (2001 film), a 2001 film based on the Arthur Miller novel *Focus (2015 ...
. In
interlinear gloss In linguistics and pedagogy, an interlinear gloss is a gloss (series of brief explanations, such as definitions or pronunciations) placed between lines, such as between a line of original text and its translation into another language. When gloss ...
, a tilde sets off an element added to a word by
reduplication In linguistics, reduplication is a Morphology (linguistics), morphological process in which the Root (linguistics), root or Stem (linguistics), stem of a word, part of that, or the whole word is repeated exactly or with a slight change. The cla ...
; were a hyphen or double hyphen used instead, confusion would arise because that element would be notated in the same way as an independent morpheme requiring an independent gloss.


Computing

Computer programmers A programmer, computer programmer or coder is an author of computer source code someone with skill in computer programming. The professional titles ''software developer'' and ''software engineer'' are used for jobs that require a progr ...
use the tilde in various ways and sometimes call the symbol (as opposed to the diacritic) a squiggle, squiggly, swiggle, or twiddle. According to the
Jargon File The Jargon File is a glossary and usage dictionary of slang used by computer programmers. The original Jargon File was a collection of terms from technical cultures such as the MIT Computer Science and Artificial Intelligence Laboratory, MIT AI Lab ...
, other synonyms sometimes used in programming include not, approx, wiggle, enyay (after '' eñe'') and (humorously) sqiggle .


Directories and URLs

On
Unix Unix (, ; trademarked as UNIX) is a family of multitasking, multi-user computer operating systems that derive from the original AT&T Unix, whose development started in 1969 at the Bell Labs research center by Ken Thompson, Dennis Ritchie, a ...
-like
operating system An operating system (OS) is system software that manages computer hardware and software resources, and provides common daemon (computing), services for computer programs. Time-sharing operating systems scheduler (computing), schedule tasks for ...
s (including
AIX Aix or AIX may refer to: Computing * AIX, a line of IBM computer operating systems *Alternate index, for an IBM Virtual Storage Access Method key-sequenced data set * Athens Internet Exchange, a European Internet exchange point Places Belg ...
,
BSD The Berkeley Software Distribution (BSD), also known as Berkeley Unix or BSD Unix, is a discontinued Unix operating system developed and distributed by the Computer Systems Research Group (CSRG) at the University of California, Berkeley, beginni ...
,
Linux Linux ( ) is a family of open source Unix-like operating systems based on the Linux kernel, an kernel (operating system), operating system kernel first released on September 17, 1991, by Linus Torvalds. Linux is typically package manager, pac ...
and
macOS macOS, previously OS X and originally Mac OS X, is a Unix, Unix-based operating system developed and marketed by Apple Inc., Apple since 2001. It is the current operating system for Apple's Mac (computer), Mac computers. With ...
), tilde normally indicates the current user's
home directory A home directory is a directory (file systems), file system directory on a multi-user operating system containing computer file, files for a given user (computing), user of the system. The specifics of the home directory (such as its name and loc ...
. For example, if the current user's home directory is , then the command is equivalent to , , or . This convention derives from the
Lear-Siegler Lear Siegler Incorporated (LSI) is a diverse American corporation established in 1962. Its products range from car seats and brakes to weapons control systems for military fighter planes. The company's more than $2 billion-a-year annual sales come ...
ADM-3A The ADM-3A is an early influential video display terminal, introduced in 1976. It was manufactured by Lear Siegler and has a 12-inch screen displaying 12 or 24 lines of 80 characters. It set a new industry low single unit price of $995. Its ...
terminal in common use during the 1970s, which happened to have the tilde symbol and the word "Home" (for moving the cursor to the upper left) on the same key. When prepended to a particular username, the tilde indicates that user's home directory (e.g., for the home directory of user , such as ). Used in URLs on the
World Wide Web The World Wide Web (WWW or simply the Web) is an information system that enables Content (media), content sharing over the Internet through user-friendly ways meant to appeal to users beyond Information technology, IT specialists and hobbyis ...
, it often denotes a personal website on a
Unix Unix (, ; trademarked as UNIX) is a family of multitasking, multi-user computer operating systems that derive from the original AT&T Unix, whose development started in 1969 at the Bell Labs research center by Ken Thompson, Dennis Ritchie, a ...
-based server. For example, might be the personal website 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 computing, a directory is a file system cataloging structure that contains references to other computer files, and possibly other directories. On many computers, directories are known as folders or drawers, analogous to a workbench or the t ...
in the user's home directory, such as or . In URLs, the characters (or ) may substitute for a tilde if an input device lacks a tilde key. Thus, and will behave in the same manner.


Computer languages


= Regex

= The tilde is used in the AWK
programming language A programming language is a system of notation for writing computer programs. Programming languages are described in terms of their Syntax (programming languages), syntax (form) and semantics (computer science), semantics (meaning), usually def ...
as part of the pattern match operators for
regular expression A regular expression (shortened as regex or regexp), sometimes referred to as rational expression, is a sequence of characters that specifies a match pattern in text. Usually such patterns are used by string-searching algorithms for "find" ...
s: *''variable'' ~ /''regex''/ returns true if the variable is matched. *''variable'' !~ /''regex''/ returns false if the variable is matched. The operators are also used in the
SQL Structured Query Language (SQL) (pronounced ''S-Q-L''; or alternatively as "sequel") is a domain-specific language used to manage data, especially in a relational database management system (RDBMS). It is particularly useful in handling s ...
variant of the database
PostgreSQL PostgreSQL ( ) also known as Postgres, is a free and open-source software, free and open-source relational database management system (RDBMS) emphasizing extensibility and SQL compliance. PostgreSQL features transaction processing, transactions ...
. A variant of this, with the plain tilde replaced with =~, was adopted in
Perl Perl is a high-level, general-purpose, interpreted, dynamic programming language. Though Perl is not officially an acronym, there are various backronyms in use, including "Practical Extraction and Reporting Language". Perl was developed ...
.
Ruby Ruby is a pinkish-red-to-blood-red-colored gemstone, a variety of the mineral corundum ( aluminium oxide). Ruby is one of the most popular traditional jewelry gems and is very durable. Other varieties of gem-quality corundum are called sapph ...
also uses this variant without the negated operator.


= Negation

= In APL and
MATLAB MATLAB (an abbreviation of "MATrix LABoratory") is a proprietary multi-paradigm programming language and numeric computing environment developed by MathWorks. MATLAB allows matrix manipulations, plotting of functions and data, implementat ...
, tilde represents the monadic logical function NOT. and in APL it additionally represents the dyadic
multiset In mathematics, a multiset (or bag, or mset) is a modification of the concept of a set that, unlike a set, allows for multiple instances for each of its elements. The number of instances given for each element is called the ''multiplicity'' of ...
function ''without'' (
set difference In set theory, the complement of a set , often denoted by A^c (or ), is the set of elements not in . When all elements in the universe, i.e. all elements under consideration, are considered to be members of a given set , the absolute complement ...
). In C the tilde character is used as
bitwise NOT In computer programming, a bitwise operation operates on a bit string, a bit array or a binary numeral (considered as a bit string) at the level of its individual bits. It is a fast and simple action, basic to the higher-level arithmetic operatio ...
unary operator, following the notation in logic (an ! causes a logical NOT, instead). This is also used by many languages based on or influenced by C, such as C++, C#, D,
Java Java is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea (a part of Pacific Ocean) to the north. With a population of 156.9 million people (including Madura) in mid 2024, proje ...
,
JavaScript JavaScript (), often abbreviated as JS, is a programming language and core technology of the World Wide Web, alongside HTML and CSS. Ninety-nine percent of websites use JavaScript on the client side for webpage behavior. Web browsers have ...
,
Perl Perl is a high-level, general-purpose, interpreted, dynamic programming language. Though Perl is not officially an acronym, there are various backronyms in use, including "Practical Extraction and Reporting Language". Perl was developed ...
,
PHP PHP is a general-purpose scripting language geared towards web development. It was originally created by Danish-Canadian programmer Rasmus Lerdorf in 1993 and released in 1995. The PHP reference implementation is now produced by the PHP Group. ...
, and Python. The MySQL database also use tilde as bitwise invert as does Microsoft's SQL Server Transact-SQL (T-SQL) language.


~~ cast

JavaScript JavaScript (), often abbreviated as JS, is a programming language and core technology of the World Wide Web, alongside HTML and CSS. Ninety-nine percent of websites use JavaScript on the client side for webpage behavior. Web browsers have ...
also uses tilde as bitwise NOT. Because bitwise operators work on integers, and numbers in JavaScript are 64 bit floating point numbers, the operator converts numbers to a 32-bit signed integer before it performing the negation. The conversion truncates the fractional part and most significant bits. This lets two tildes ~~x to be used as a short syntax to cast to integer. However, it is not recommended as use for truncation. In contrast, it does not truncate BigInts, which are arbitrarily large integers.


=Other uses

= In C++ and C#, the tilde is also used as the first character in a
class Class, Classes, or The Class may refer to: Common uses not otherwise categorized * Class (biology), a taxonomic rank * Class (knowledge representation), a collection of individuals or objects * Class (philosophy), an analytical concept used d ...
's
method Method (, methodos, from μετά/meta "in pursuit or quest of" + ὁδός/hodos "a method, system; a way or manner" of doing, saying, etc.), literally means a pursuit of knowledge, investigation, mode of prosecuting such inquiry, or system. In re ...
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 ASP.NET applications, tilde ('~') is used as a shortcut to the root of the application's virtual directory. In the CSS stylesheet language, the tilde finds the element selected by the right-hand side that shares the parent with an element selected by the left-hand side. In the
D programming language D, also known as dlang, is a multi-paradigm system programming language created by Walter Bright at Digital Mars and released in 2001. Andrei Alexandrescu joined the design and development effort in 2007. Though it originated as a re-enginee ...
, the tilde is used as bitwise not operator,
concatenation In formal language theory and computer programming, string concatenation is the operation of joining character strings end-to-end. For example, the concatenation of "snow" and "ball" is "snowball". In certain formalizations of concatenati ...
operator such as those of
arrays An array is a systematic arrangement of similar objects, usually in rows and columns. Things called an array include: {{TOC right Music * In twelve-tone and serial composition, the presentation of simultaneous twelve-tone sets such that the ...
, and to indicate an object destructor. Tilde operator can be overloaded for user types, and binary tilde operator is mostly used to merging two objects, or adding some objects to set of objects. It was introduced because plus operator can have different meaning in many situations. For example, "120" + "14" may produce "134" (addition of two numbers), "12014" (concatenation of strings), or something else. D disallows + operator for arrays (and strings), and provides separate operator for concatenation (similarly
PHP PHP is a general-purpose scripting language geared towards web development. It was originally created by Danish-Canadian programmer Rasmus Lerdorf in 1993 and released in 1995. The PHP reference implementation is now produced by the PHP Group. ...
programming language solved this problem by using dot operator for concatenation, and + for number addition, which will also work on strings containing numbers). In Eiffel, the tilde is used for object comparison. If ''a'' and ''b'' denote objects, the Boolean expression ''a'' ~ ''b'' has value true if and only if these objects are equal, as defined by the applicable version of the library routine ''is_equal'', which by default denotes field-by-field object equality but can be redefined in any class to support a specific notion of equality. If ''a'' and ''b'' are references, the object equality expression ''a'' ~ ''b'' is to be contrasted with ''a'' = ''b'' which denotes reference equality. Unlike the call ''a''.''is_equal'' (''b''), the expression ''a'' ~ ''b'' is type-safe even in the presence of
covariance In probability theory and statistics, covariance is a measure of the joint variability of two random variables. The sign of the covariance, therefore, shows the tendency in the linear relationship between the variables. If greater values of one ...
. In the Apache Groovy programming language the tilde character overloaded as a bitwise binary negation operation, and as the "pattern operator" that creates a
regular expression A regular expression (shortened as regex or regexp), sometimes referred to as rational expression, is a sequence of characters that specifies a match pattern in text. Usually such patterns are used by string-searching algorithms for "find" ...
pattern object. =~ and

~
can in Groovy be used to match a regular expression. In
Haskell Haskell () is a general-purpose, statically typed, purely functional programming language with type inference and lazy evaluation. Designed for teaching, research, and industrial applications, Haskell pioneered several programming language ...
, the tilde is used in type constraints to indicate type equality. Also, in pattern-matching, the tilde is used to indicate a lazy pattern match. In the
Inform Inform is a programming language and design system for interactive fiction originally created in 1993 by Graham Nelson. Inform can generate programs designed for the Z-machine, Z-code or Glulx virtual machines. Versions 1 through 5 were released ...
6 programming language, the tilde is used to indicate a quotation mark inside a quoted string. Tilde itself is created by @@126. In "text mode" of the
LaTeX Latex is an emulsion (stable dispersion) of polymer microparticles in water. Latices are found in nature, but synthetic latices are common as well. In nature, latex is found as a wikt:milky, milky fluid, which is present in 10% of all floweri ...
typesetting language a tilde diacritic can be obtained using, e.g., \~, yielding "ñ". A stand-alone tilde can be obtained by using \textasciitilde or \string~. In "math mode" a tilde diacritic can be written as, e.g., \tilde. For a wider tilde \widetilde can be used. The \sim command produce a tilde-like binary relation symbol that is often used in mathematical expressions, and the double-tilde is obtained with \approx.In both text and math mode, a tilde on its own (~) renders a white space with no line breaking.In both text and math mode, a tilde on its own (~) renders a white space with no line breaking. The url package also supports entering tildes directly, e.g., \url. In
MediaWiki MediaWiki is free and open-source wiki software originally developed by Magnus Manske for use on Wikipedia on January 25, 2002, and further improved by Lee Daniel Crocker,mailarchive:wikipedia-l/2001-August/000382.html, Magnus Manske's announc ...
syntax, four tildes are a shortcut for a user's signature. Three and five tildes puts the signature without timestamp and only the timestamp, respectively. In
Common Lisp Common Lisp (CL) is a dialect of the Lisp programming language, published in American National Standards Institute (ANSI) standard document ''ANSI INCITS 226-1994 (S2018)'' (formerly ''X3.226-1994 (R1999)''). The Common Lisp HyperSpec, a hyperli ...
, the tilde is used as the prefix for format specifiers in format strings. In
Max/MSP Max, also known as Max/MSP/Jitter, is a visual programming language for music and multimedia developed and maintained by San Francisco-based software company Cycling '74. Over its more than thirty-year history, it has been used by composers, pe ...
, MSP objects have names ending with a tilde. MSP objects process at the computer's sampling rate and mainly deal with sound. In
Standard ML Standard ML (SML) is a General-purpose programming language, general-purpose, High-level programming language, high-level, Modular programming, modular, Functional programming, functional programming language with compile-time type checking and t ...
, the tilde is used as the prefix for negative numbers and as the unary negation operator. In
OCaml OCaml ( , formerly Objective Caml) is a General-purpose programming language, general-purpose, High-level programming language, high-level, Comparison of multi-paradigm programming languages, multi-paradigm programming language which extends the ...
, the tilde is used to specify the label for a labeled parameter. In R, the tilde operator is used to separate the left- and right-hand sides in a model formula. In
Object REXX Object REXX is a high-level, general-purpose, interpreted, object-oriented ( class-based) programming language. Today it is generally referred to as ooRexx (short for "Open Object Rexx"), which is the maintained and direct open-source success ...
, the twiddle is used as a "message send" symbol. For example, Employee.name~lower() would cause the lower() method to act on the object Employee's name attribute, returning the result of the operation. ~~ returns the object that received the method rather than the result produced. Thus, it can be used when the result need not be returned or when cascading methods are to be used. team~~insert("Jane")~~insert("Joe")~~insert("Steve") would send multiple concurrent insert messages, thus invoking the insert method three consecutive times on the team object. In Raku, a prefixing tilde
converts Conversion or convert may refer to: Arts, entertainment, and media * ''The Convert'', a 2023 film produced by Jump Film & Television and Brouhaha Entertainment * "Conversion" (''Doctor Who'' audio), an episode of the audio drama ''Cyberman'' * ...
a value to a string. An infix tilde
concatenate In formal language theory and computer programming, string concatenation is the operation of joining character strings end-to-end. For example, the concatenation of "snow" and "ball" is "snowball". In certain formalizations of concatenati ...
s strings, taking place of the dot operator in Perl, as the dot is used for member access instead of . is called "the smartmatch operator" and its semantics depend on the type of the right-side argument. Namely, it checks numeric and string equalities, performs
regular expression A regular expression (shortened as regex or regexp), sometimes referred to as rational expression, is a sequence of characters that specifies a match pattern in text. Usually such patterns are used by string-searching algorithms for "find" ...
match tests (as opposed to in Perl), and
type checking In computer programming, a type system is a logical system comprising a set of rules that assigns a property called a ''type'' (for example, integer, floating point, string) to every '' term'' (a word, phrase, or other set of symbols). Usu ...
. my $concatResult = "Hello " ~ "world!"; $concatResult ~~ /<, w>< ..Z< ..z*<, w>/; say $/; # outputs "Hello" # the $/ variable holds the last regex match result In
YAML YAML ( ) is a human-readable data serialization language. It is commonly used for configuration files and in applications where data is being stored or transmitted. YAML targets many of the same communications applications as Extensible Marku ...
, the "Core schema," a set of aliases that processors are recommended to use, resolves a tilde as null.


Keyboards

The presence (or absence) of a tilde engraved on the keyboard depends on the territory where it was sold. In either case, computer's system settings determine the
keyboard mapping A keyboard layout is any specific physical, visual, or functional arrangement of the keys, legends, or key-meaning associations (respectively) of a computer keyboard, mobile phone, or other computer-controlled typographic keyboard. Standard keybo ...
and the default setting will match the engravings on the keys. Even so, it certainly possible to configure a keyboard for a different locale than that supplied by the retailer. On American and British keyboards, the tilde is a standard keytop and pressing it produces a free-standing "ASCII Tilde". To generate a letter with a tilde diacritic requires the
US international QWERTY ( ) is a keyboard layout for Latin-script alphabets. The name comes from the order of the first six Computer keyboard keys#Types, keys on the top letter row of the keyboard: . The QWERTY design is based on a layout included in the Sh ...
or UK extended keyboard setting. * With US-international, the key is a
dead key A dead key is a special kind of modifier key on a mechanical typewriter, or computer keyboard, that is typically used to attach a specific diacritic to a base letter (alphabet), letter. The dead key does not generate a (complete) grapheme, charact ...
: pressing that key and then a letter produces the tilde-accented form of that letter. (For example, produces .) With this setting active, an ASCII tilde can be inserted with the dead key followed by the space bar, or alternatively by striking the dead key twice in a row. * With UK-extended, the key works normally but becomes a 'dead key' when combined with AltGr. Thus followed by a letter produces the accented form of that letter. * With a
Mac Mac or MAC may refer to: Common meanings * Mac (computer), a line of personal computers made by Apple Inc. * Mackintosh, a raincoat made of rubberized cloth * Mac, a prefix to surnames derived from Gaelic languages * McIntosh (apple), a Canadi ...
either of the Alt/ Option keys function similarly. * With
Linux Linux ( ) is a family of open source Unix-like operating systems based on the Linux kernel, an kernel (operating system), operating system kernel first released on September 17, 1991, by Linus Torvalds. Linux is typically package manager, pac ...
, the
compose key A compose key (sometimes called multi key) is a key on a computer keyboard that indicates that the following (usually 2 or more) keystrokes trigger the insertion of an alternate character, typically a precomposed character or a symbol. For insta ...
facility is used. Instructions for other national languages and keyboards are beyond the scope of this article.


Backup filenames

The dominant
Unix Unix (, ; trademarked as UNIX) is a family of multitasking, multi-user computer operating systems that derive from the original AT&T Unix, whose development started in 1969 at the Bell Labs research center by Ken Thompson, Dennis Ritchie, a ...
convention for naming backup copies of files is appending a tilde to the original file name. It originated with the
Emacs Emacs (), originally named EMACS (an acronym for "Editor Macros"), is a family of text editors that are characterized by their extensibility. The manual for the most widely used variant, GNU Emacs, describes it as "the extensible, customizable, s ...
text editor and was adopted by many other editors and some command-line tools. Emacs also introduced an elaborate numbered backup scheme, with files named , and so on. It didn't catch on, as the rise of
version control Version control (also known as revision control, source control, and source code management) is the software engineering practice of controlling, organizing, and tracking different versions in history of computer files; primarily source code t ...
software eliminates the need for this usage.


Microsoft filenames

The tilde was part of
Microsoft Microsoft Corporation is an American multinational corporation and technology company, technology conglomerate headquartered in Redmond, Washington. Founded in 1975, the company became influential in the History of personal computers#The ear ...
's filename mangling scheme when it extended the
FAT In nutrition science, nutrition, biology, and chemistry, fat usually means any ester of fatty acids, or a mixture of such chemical compound, compounds, most commonly those that occur in living beings or in food. The term often refers specif ...
file system standard to support long filenames for
Microsoft Windows Windows is a Product lining, product line of Proprietary software, proprietary graphical user interface, graphical operating systems developed and marketed by Microsoft. It is grouped into families and subfamilies that cater to particular sec ...
. 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 characters from a restricted character set (e.g. no spaces), followed by a period, followed by three more characters. In order to permit these legacy programs to access files in the FAT 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, "" might become "". The tilde symbol is also often used to prefix hidden temporary files that are created when a document is opened in Windows. For example, when a document "Document1.doc" is opened in Word, a file called "~$cument1.doc" is 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.


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)*.


Unicode encoding


Letters with tilde

Unicode encodes a number of cases of "letter with tilde" as
precomposed character A precomposed character (alternatively composite character or decomposable character) is a Unicode entity that can also be defined as a sequence of one or more other characters. A precomposed character may typically represent a letter with a diac ...
s and these are displayed below. In addition, many more symbols may be composed using the
combining character In digital typography, combining characters are Character (computing), characters that are intended to modify other characters. The most common combining characters in the Latin script are the combining diacritic, diacritical marks (including c ...
facility (, and others) that may be used with any letter or other diacritic to create a customised symbol but this does not mean that the result has any real-world application and are not shown in the table. A tilde diacritic can be added to almost any character by using a combining tilde. Greek and Cyrillic letters with tilde ( Α͂ᾶ, Η͂ῆ, Ι͂ῖ, ῗ, Υ͂ῦ, ῧ and А̃а̃, Ә̃ ә̃, Е̃е̃, И̃и̃, О̃о̃, У̃у̃, Ј̃j̃) are formed using this method.


Unicode and Shift JIS encoding of wave dash

In practice the (Unicode ), is often used instead of the (Unicode ), because the
Shift JIS Shift JIS (also SJIS, MIME name Shift_JIS, known as PCK in Solaris contexts) is a character encoding for the Japanese language, originally developed by the Japanese company ASCII Corporation in conjunction with Microsoft and standardized as JIS ...
code for the wave dash, 0x8160, which should be mapped to U+301C, is instead mapped to U+FF5E in Windows code page 932 (
Microsoft Microsoft Corporation is an American multinational corporation and technology company, technology conglomerate headquartered in Redmond, Washington. Founded in 1975, the company became influential in the History of personal computers#The ear ...
's
code page In computing, a code page is a character encoding and as such it is a specific association of a set of printable character (computing), characters and control characters with unique numbers. Typically each number represents the binary value in a s ...
for Japanese), a widely used extension of Shift JIS. This decision avoided a shape definition error in the original (6.2) Unicode code charts:. the wave dash reference glyph in JIS / Shift JIS matches the Unicode reference glyph for U+FF5E , while the original reference glyph for U+301C was reflected, incorrectly, when Unicode imported the JIS wave dash. In other platforms such as the
classic Mac OS Mac OS (originally System Software; retronym: Classic Mac OS) is the series of operating systems developed for the Mac (computer), Macintosh family of personal computers by Apple Computer, Inc. from 1984 to 2001, starting with System 1 and end ...
and
macOS macOS, previously OS X and originally Mac OS X, is a Unix, Unix-based operating system developed and marketed by Apple Inc., Apple since 2001. It is the current operating system for Apple's Mac (computer), Mac computers. With ...
, 0x8160 is correctly mapped to U+301C. It is generally difficult, if not impossible, for users of Japanese Windows to type U+301C, especially in legacy, non-Unicode applications. A similar situation exists regarding the Korean
KS X 1001 KS X 1001, "''Code for Information Interchange (Hangul and Hanja)''", formerly called KS C 5601, is a South Korean coded character set standard to represent Hangul and Hanja characters on a computer. KS X 1001 is encoded by the most common leg ...
character set, in which Microsoft maps the
EUC-KR Extended Unix Code (EUC) is a multibyte character encoding system used primarily for Japanese language, Japanese, Korean language, Korean, and simplified Chinese characters, simplified Chinese (characters). The most commonly used EUC codes are va ...
or UHC code for the wave dash (0xA1AD) to , while
IBM International Business Machines Corporation (using the trademark IBM), nicknamed Big Blue, is an American Multinational corporation, multinational technology company headquartered in Armonk, New York, and present in over 175 countries. It is ...
and
Apple An apple is a round, edible fruit produced by an apple tree (''Malus'' spp.). Fruit trees of the orchard or domestic apple (''Malus domestica''), the most widely grown in the genus, are agriculture, cultivated worldwide. The tree originated ...
map it to U+301C. Microsoft also uses U+FF5E to map the KS X 1001 raised tilde (0xA2A6), while Apple uses . The current Unicode reference glyph for U+301C has been corrected to match the JIS standard in response to a 2014 proposal, which noted that while the existing Unicode reference glyph had been matched by fonts from the discontinued
Windows XP Windows XP is a major release of Microsoft's Windows NT operating system. It was released to manufacturing on August 24, 2001, and later to retail on October 25, 2001. It is a direct successor to Windows 2000 for high-end and business users a ...
, all other major platforms including later versions of Microsoft Windows shipped with fonts matching the JIS reference glyph for U+301C. The JIS / Shift JIS wave dash is still formally mapped to U+301C as of
JIS X 0213 JIS X 0213 is a Japanese Industrial Standard defining coded character sets for encoding the characters used in Japan. This standard extends JIS X 0208. The first version was published in 2000 and revised in 2004 (JIS2004) and 2012. As well as ad ...
, whereas the
WHATWG The Web Hypertext Application Technology Working Group (WHATWG) is a community of people interested in evolving HTML and related technologies. The WHATWG was founded by individuals from Apple Inc., the Mozilla Foundation and Opera Software, ...
Encoding Standard used by
HTML5 HTML5 (Hypertext Markup Language 5) is a markup language used for structuring and presenting hypertext documents on the World Wide Web. It was the fifth and final major HTML version that is now a retired World Wide Web Consortium (W3C) recommend ...
follows Microsoft in mapping 0x8160 to U+FF5E. These two code points have a similar or identical glyph in several computer fonts, reducing the confusion and incompatibility.


See also

* * ** * * *


Notes


References

{{Navbox punctuation Greek-script diacritics Latin-script diacritics Letters with tilde, * Logic symbols Mathematical symbols Punctuation Typographical symbols