Chebyshev–Markov–Stieltjes inequalities: Difference between revisions

From formulasearchengine
Jump to navigation Jump to search
en>Sodin
m Formulation: tex->html
 
en>Yobot
m References: WP:CHECKWIKI error fixes - Replaced endash with hyphen in sortkey per WP:MCSTJR using AWB (9100)
Line 1: Line 1:
Ed is what people call me and my wife doesn't like it at all. The favorite pastime for him and his kids is to play lacross and he would by no means give it up. Invoicing is what I do. Some time ago he chose to live in North Carolina and he doesn't strategy on changing it.<br><br>Here is my webpage :: [https://www-ocl.gist.ac.kr/work/xe/?document_srl=605236 psychic readings]
In [[programming language theory]], '''parametricity''' is an abstract uniformity property enjoyed by [[Parametric polymorphism|parametrically polymorphic]] functions, which captures the intuition that all instances of a polymorphic function act the same way.  It is closely related to the concept of [[natural transformation]] in [[category theory]].
 
== Idea ==
 
Consider this example, based on a set ''X'' and the type ''T''(''X'') = [''X'' → ''X''] of functions from ''X'' to itself.  The higher-order function ''twice''<sub>''X''</sub> : ''T''(''X'') → ''T''(''X'') given by ''twice''<sub>''X''</sub>(''f'') = ''f'' ∘ ''f'', is intuitively independent of the set ''X''. The family of all such functions ''twice''<sub>''X''</sub>, parametrized by sets ''X'', is called a "[[Parametric polymorphism|parametrically polymorphic function]]"  We simply write '''twice''' for the entire family of these functions and write its type as <math>\forall</math>''X''. ''T''(''X'') → ''T''(''X'').  The individual functions ''twice''<sub>''X''</sub> are called the ''components'' or ''instances'' of the polymorphic function.  Notice that all the component functions ''twice''<sub>''X''</sub> act "the same way" because they are given by the same rule.  Other families of functions obtained by picking one arbitrary function from each ''T''(''X'') → ''T''(''X'') would not have such uniformity.  They are called [[Ad hoc polymorphism|"''ad hoc'' polymorphic functions"]].  ''Parametricity'' is the abstract property enjoyed by the uniformly acting families such as '''twice''', which distinguishes them from ''ad hoc'' families.  With an adequate formalization of parametricity, it is possible to prove that the parametrically polymorphic functions of type <math>\forall</math>''X''. ''T''(''X'') → ''T''(''X'') are one-to-one with natural numbers.  The function corresponding to the natural number ''n'' is given by the rule ''f'' <math>\mapsto</math> ''f''<sup>''n''</sup>, i.e., the polymorphic [[Church encoding|Church numeral]] for ''n''.  In contrast, the collection of all ''ad hoc'' families would be too large to be a set.
 
== History ==
The ''parametricity theorem'' was originally stated by [[John C. Reynolds]], who called it the ''abstraction theorem''.<ref>{{cite conference
  | first = J.C.
  | last = Reynolds
  | title = Types, abstraction, and parametric polymorphism
  | booktitle = Information Processing
  | pages = 513–523
  | url = ftp://ftp.cs.cmu.edu/user/jcr/typesabpara.pdf
  | year = 1983
  | location = North Holland, Amsterdam }}</ref> In his paper "Theorems for free!",<ref>{{cite conference
  | first = Philip
  | last = Wadler
  | url = http://citeseer.ist.psu.edu/viewdoc/summary?doi=10.1.1.38.9875
  | title = Theorems for free!
  | booktitle = 4th Int'l Conf. on Functional Programming and Computer Architecture
  | date = September 1989
  | location = London }}</ref> [[Philip Wadler]] described an application of parametricity to derive theorems about [[Parametric polymorphism|parametrically polymorphic]] functions based on their types.
 
{{Expand section|date=June 2008}}
 
== Parametricity and programming language implementation ==
 
Parametricity is the basis for many [[program transformation]]s implemented in compilers for the [[Haskell programming language]]. These transformations were traditionally thought to be correct in Haskell because of Haskell's [[non-strict]] semantics. Despite being a [[Lazy evaluation|lazy]] programming language, Haskell does support certain primitive operations — such as the operator <code>seq</code> — that enable so-called "selective strictness", allowing the programmer to force the evaluation of certain expressions. In their paper "Free theorems in the presence of ''seq''",<ref>{{cite conference
  | first = Patricia
  | last = Johann
  | coauthors = Janis Voigtlaender
  | title = Free theorems in the presence of ''seq''
  | url = http://citeseer.ist.psu.edu/johann04free.html
  | booktitle = Proc., Principles of Programming Languages
  | date = January 2004
  | pages = 99–110}}</ref> [[Patricia Johann]] and [[Janis Voigtlaender]] showed that because of the presence of these operations, the general parametricity theorem does not hold for Haskell programs; thus, these transformations are unsound in general.
 
== Parametricity and dependent types ==
{{Expand section|date=June 2013}}
 
== See also ==
* [[Parametric polymorphism]]
* [[Non-strict programming language]]
 
== References ==
{{reflist|2}}
 
[[Category:Programming language topics]]
[[Category:Type theory]]
[[Category:Polymorphism (computer science)]]

Revision as of 15:25, 20 April 2013

In programming language theory, parametricity is an abstract uniformity property enjoyed by parametrically polymorphic functions, which captures the intuition that all instances of a polymorphic function act the same way. It is closely related to the concept of natural transformation in category theory.

Idea

Consider this example, based on a set X and the type T(X) = [XX] of functions from X to itself. The higher-order function twiceX : T(X) → T(X) given by twiceX(f) = ff, is intuitively independent of the set X. The family of all such functions twiceX, parametrized by sets X, is called a "parametrically polymorphic function" We simply write twice for the entire family of these functions and write its type as X. T(X) → T(X). The individual functions twiceX are called the components or instances of the polymorphic function. Notice that all the component functions twiceX act "the same way" because they are given by the same rule. Other families of functions obtained by picking one arbitrary function from each T(X) → T(X) would not have such uniformity. They are called "ad hoc polymorphic functions". Parametricity is the abstract property enjoyed by the uniformly acting families such as twice, which distinguishes them from ad hoc families. With an adequate formalization of parametricity, it is possible to prove that the parametrically polymorphic functions of type X. T(X) → T(X) are one-to-one with natural numbers. The function corresponding to the natural number n is given by the rule f fn, i.e., the polymorphic Church numeral for n. In contrast, the collection of all ad hoc families would be too large to be a set.

History

The parametricity theorem was originally stated by John C. Reynolds, who called it the abstraction theorem.[1] In his paper "Theorems for free!",[2] Philip Wadler described an application of parametricity to derive theorems about parametrically polymorphic functions based on their types.

Template:Expand section

Parametricity and programming language implementation

Parametricity is the basis for many program transformations implemented in compilers for the Haskell programming language. These transformations were traditionally thought to be correct in Haskell because of Haskell's non-strict semantics. Despite being a lazy programming language, Haskell does support certain primitive operations — such as the operator seq — that enable so-called "selective strictness", allowing the programmer to force the evaluation of certain expressions. In their paper "Free theorems in the presence of seq",[3] Patricia Johann and Janis Voigtlaender showed that because of the presence of these operations, the general parametricity theorem does not hold for Haskell programs; thus, these transformations are unsound in general.

Parametricity and dependent types

Template:Expand section

See also

References

43 year old Petroleum Engineer Harry from Deep River, usually spends time with hobbies and interests like renting movies, property developers in singapore new condominium and vehicle racing. Constantly enjoys going to destinations like Camino Real de Tierra Adentro.

  1. 55 years old Systems Administrator Antony from Clarence Creek, really loves learning, PC Software and aerobics. Likes to travel and was inspired after making a journey to Historic Ensemble of the Potala Palace.

    You can view that web-site... ccleaner free download
  2. 55 years old Systems Administrator Antony from Clarence Creek, really loves learning, PC Software and aerobics. Likes to travel and was inspired after making a journey to Historic Ensemble of the Potala Palace.

    You can view that web-site... ccleaner free download
  3. 55 years old Systems Administrator Antony from Clarence Creek, really loves learning, PC Software and aerobics. Likes to travel and was inspired after making a journey to Historic Ensemble of the Potala Palace.

    You can view that web-site... ccleaner free download