
This article needs additional citations for verification.(February 2024) |
In mathematics, function application is the act of applying a function to an argument from its domain so as to obtain the corresponding value from its range. In this sense, function application can be thought of as the opposite of function abstraction.
Representation
Function application is usually depicted by juxtaposing the variable representing the function with its argument encompassed in parentheses. For example, the following expression represents the application of the function ƒ to its argument x.
In some instances, a different notation is used where the parentheses aren't required, and function application can be expressed just by juxtaposition. For example, the following expression can be considered the same as the previous one:
The latter notation is especially useful in combination with the currying isomorphism. Given a function , its application is represented as
by the former notation and
(or
with the argument
written with the less common angle brackets) by the latter. However, functions in curried form
can be represented by juxtaposing their arguments:
, rather than
. This relies on function application being left-associative.
U+2061 FUNCTION APPLICATION (⁡, ⁡) — a contiguity operator indicating application of a function; that is an invisible zero width character intended to distinguish concatenation meaning function application from concatenation meaning multiplication.
Set theory
In axiomatic set theory, especially Zermelo–Fraenkel set theory, a function is often defined as a relation (
) having the property that, for any
there is a unique
such that
.
One is usually not content to write "" to specify that
, and usually wishes for the more common function notation "
", thus function application, or more specifically, the notation "
", is defined by an axiom schema. Given any function
with a given domain
and codomain
:
Stating "For all in
and
in
,
is equal to
if and only if there is a unique
in
such that
is in
and
is in
". The notation
here being defined is a new functional predicate from the underlying logic, where each y is a term in x. Since
, as a functional predicate, must map every object in the language, objects not in the specified domain are chosen to map to an arbitrary object, suct as the empty set.
As an operator
Function application can be trivially defined as an operator, called apply or , by the following definition:
The operator may also be denoted by a backtick (`).
If the operator is understood to be of low precedence and right-associative, the application operator can be used to cut down on the number of parentheses needed in an expression. For example;
can be rewritten as:
However, this is perhaps more clearly expressed by using function composition instead:
or even:
if one considers to be a constant function returning
.
Other instances
Function application in the lambda calculus is expressed by β-reduction.
The Curry–Howard correspondence relates function application to the logical rule of modus ponens.
See also
References
- Alama, Jesse; Korbmacher, Johannes (2023), "The Lambda Calculus", in Zalta, Edward N.; Nodelman, Uri (eds.), The Stanford Encyclopedia of Philosophy (Winter 2023 ed.), Metaphysics Research Lab, Stanford University, retrieved 2024-02-29
- Suppes, Patrick (1972). Axiomatic set theory. Internet Archive. New York, Dover Publications. p. 87. ISBN 978-0-486-61630-8.
- Mendelson, Elliott (1964). Introduction to mathematical logic. Internet Archive. Princeton, N.J., Van Nostrand. p. 82. ISBN 978-0-442-05300-0.
- Lévy, Azriel (1979). Basic set theory. Berlin; New York: Springer-Verlag. p. 27. ISBN 978-0-387-08417-6.
- Lévy, Azriel (1979). Basic set theory. Berlin; New York: Springer-Verlag. p. 15. ISBN 978-0-387-08417-6.
This article needs additional citations for verification Please help improve this article by adding citations to reliable sources Unsourced material may be challenged and removed Find sources Function application news newspapers books scholar JSTOR February 2024 Learn how and when to remove this message In mathematics function application is the act of applying a function to an argument from its domain so as to obtain the corresponding value from its range In this sense function application can be thought of as the opposite of function abstraction RepresentationFunction application is usually depicted by juxtaposing the variable representing the function with its argument encompassed in parentheses For example the following expression represents the application of the function ƒ to its argument x f x displaystyle f x In some instances a different notation is used where the parentheses aren t required and function application can be expressed just by juxtaposition For example the following expression can be considered the same as the previous one fx displaystyle f x The latter notation is especially useful in combination with the currying isomorphism Given a function f X Y Z displaystyle f X times Y to Z its application is represented as f x y displaystyle f x y by the former notation and f x y displaystyle f x y or f x y displaystyle f langle x y rangle with the argument x y X Y displaystyle langle x y rangle in X times Y written with the less common angle brackets by the latter However functions in curried form f X Y Z displaystyle f X to Y to Z can be represented by juxtaposing their arguments fxy displaystyle f x y rather than f x y displaystyle f x y This relies on function application being left associative U 2061 FUNCTION APPLICATION amp af amp ApplyFunction a contiguity operator indicating application of a function that is an invisible zero width character intended to distinguish concatenation meaning function application from concatenation meaning multiplication Set theoryIn axiomatic set theory especially Zermelo Fraenkel set theory a function f X Y displaystyle f X mapsto Y is often defined as a relation f X Y displaystyle f subseteq X times Y having the property that for any x X displaystyle x in X there is a unique y Y displaystyle y in Y such that x y f displaystyle x y in f One is usually not content to write x y f displaystyle x y in f to specify that y displaystyle y and usually wishes for the more common function notation f x y displaystyle f x y thus function application or more specifically the notation f x displaystyle f x is defined by an axiom schema Given any function f displaystyle f with a given domain X displaystyle X and codomain Y displaystyle Y x X y Y f x y displaystyle forall x in X forall y in Y f x y iff z Y x z f x y f displaystyle exists z in Y x z in f land x y in f Stating For all x displaystyle x in X displaystyle X and y displaystyle y in Y displaystyle Y f x displaystyle f x is equal to y displaystyle y if and only if there is a unique z displaystyle z in Y displaystyle Y such that x z displaystyle x z is in f displaystyle f and x y displaystyle x y is in f displaystyle f The notation f x displaystyle f x here being defined is a new functional predicate from the underlying logic where each y is a term in x Since f displaystyle f as a functional predicate must map every object in the language objects not in the specified domain are chosen to map to an arbitrary object suct as the empty set As an operatorFunction application can be trivially defined as an operator called apply or displaystyle by the following definition f x f x displaystyle f mathop x f x The operator may also be denoted by a backtick If the operator is understood to be of low precedence and right associative the application operator can be used to cut down on the number of parentheses needed in an expression For example f g h j x displaystyle f g h j x can be rewritten as f g h j x displaystyle f mathop g mathop h mathop j mathop x However this is perhaps more clearly expressed by using function composition instead f g h j x displaystyle f circ g circ h circ j x or even f g h j x displaystyle f circ g circ h circ j circ x if one considers x displaystyle x to be a constant function returning x displaystyle x Other instancesFunction application in the lambda calculus is expressed by b reduction The Curry Howard correspondence relates function application to the logical rule of modus ponens See alsoPolish notationReferencesAlama Jesse Korbmacher Johannes 2023 The Lambda Calculus in Zalta Edward N Nodelman Uri eds The Stanford Encyclopedia of Philosophy Winter 2023 ed Metaphysics Research Lab Stanford University retrieved 2024 02 29 Suppes Patrick 1972 Axiomatic set theory Internet Archive New York Dover Publications p 87 ISBN 978 0 486 61630 8 Mendelson Elliott 1964 Introduction to mathematical logic Internet Archive Princeton N J Van Nostrand p 82 ISBN 978 0 442 05300 0 Levy Azriel 1979 Basic set theory Berlin New York Springer Verlag p 27 ISBN 978 0 387 08417 6 Levy Azriel 1979 Basic set theory Berlin New York Springer Verlag p 15 ISBN 978 0 387 08417 6 This mathematical analysis related article is a stub You can help Wikipedia by expanding it vte