Can someone explain to me what a function arrow is?

In summary, a "function arrow" is just a notation used to show the domain and range of a function. The domain is the set of inputs and the range is the set of possible outputs. It is also possible to have a co-domain, which is a larger set that the range is a subset of. This notation is commonly used in mathematics to describe functions and their corresponding sets.
  • #1
IntegrateMe
217
1
Can someone explain to me what a "function arrow" is?

In particular, what this may mean:

I = [a, b]
f : I --> R

I'm just trying to understand what the arrow means.

Or if we have R --> R what that would mean.

Thank you!
 
Physics news on Phys.org
  • #2


The thing to the left of the arrow is the domain of the map f and the thing to the right is the range.
As an example a map which returns the square of all real numbers would be
[tex] f: \mathbb{R} \longrightarrow \mathbb{R} [/tex]
A map which multiplies natural numbers by [itex]\frac{12}{7}[/itex] would be
[tex] f: \mathbb{N} \longrightarrow \mathbb{R} [/tex]
And a map which takes a number from 1 to 4 and returns a complex number would be
[tex] f: [1, 4] \longrightarrow \mathbb{R}^2 [/tex]
 
  • #3


It is just notation. It means that the map entails some correspondence between sets. In English, the arrow points to the possible set of outputs of the map. If your map takes as its domain some set and "points" to the set of complex numbers, then your map is "complex valued," meaning that it takes inputs that are elements of the set at the beginning of the arrow, and outputs elements of the complex numbers (i.e. numbers of the form a+ib).

For example, if f: R^2 --> C is defined by f(x,y)=x+iy then f turns elements of R^2 into "high school" complex numbers.
 
  • #4


JHamm,

If we use the example of:

f: R --> R

You said that it would return the square of all real numbers. But wouldn't it just return all real numbers, since the range, which is to the right, is R? The second one which involves 12/7 is also confusing me. Can you, or anyone for that matter, please clarify this for me.

Thanks for the help, guys, greatly appreciated.

Edit: Is this how you're describing the function f? For example, could I have said that f(x) = x^3 so that f: R --> R would actually return the cube of all real numbers?
 
Last edited:
  • #5


the usual notation is:

[tex]f: A \to B[/tex]

what is meant by this is:

for any element a in the set A, f(a) is defined, and is an element of the set B. B is called the "co-domain" of f, and is not to be confused with the "range" of f (or the image set), which is f(A). f(A) is always a subset of B, it may not be all of B itself.

for example, if we have:

[tex]f:\mathbb{R} \to \mathbb{R}, f(x) = x^2[/tex]

then we are saying f (the "squaring function") is defined for every real number x, and that x2 is also a real number. as it turns out, x2 is always non-negative, so in this case, the range of f is considerably smaller than the co-domain.

in general, you can always make the domain (the set A) smaller (this is called a restriction), and the co-domain bigger. in calculus, it is common to choose the entire real numbers as the co-domain, rather than trying to figure out ahead of time what the actual range is. often, we are only concerned with the behavior of f on a particular kind of subset of R, an interval (usally denoted I, or [a,b] or (a,b) if we wish to specify whether the interval includes the boundary points).

often, A is called "the source (or start) set", and B the "target set" (and the arrow is suggestive of some kind of motion, or action, or transformation).
 
  • #6


IntegrateMe said:
JHamm,

If we use the example of:

f: R --> R

You said that it would return the square of all real numbers. But wouldn't it just return all real numbers, since the range, which is to the right, is R? The second one which involves 12/7 is also confusing me. Can you, or anyone for that matter, please clarify this for me.

Thanks for the help, guys, greatly appreciated.

Edit: Is this how you're describing the function f? For example, could I have said that f(x) = x^3 so that f: R --> R would actually return the cube of all real numbers?

Exactly, the bit with the arrow doesn't tell you what the function really does, it just tells you the set of its domain and the set of its range.
 

Related to Can someone explain to me what a function arrow is?

1. What is a function arrow?

A function arrow, also known as an arrow function, is a shorthand syntax in programming languages that allows for the creation of anonymous functions. It is commonly used in functional programming and is denoted by the use of "=>".

2. How is a function arrow different from a regular function?

A function arrow is a more concise way of writing a function, as it does not require the use of the "function" keyword or curly braces. It also has implicit return, meaning the return value is automatically determined based on the expression following the arrow.

3. Can you give an example of a function arrow?

Yes, an example of a function arrow in JavaScript would be: (x) => x * 2. This function takes in a parameter "x" and returns the value of "x" multiplied by 2.

4. What are the advantages of using function arrows?

Function arrows allow for more concise and readable code, especially when dealing with one-line functions. They also have lexical scoping, meaning they have access to variables in the outer scope, making them more flexible and powerful.

5. Are there any limitations or downsides to using function arrows?

One limitation of function arrows is that they cannot be used as constructors, meaning they cannot be used to create new objects. Additionally, they may not be supported in older browsers, so compatibility should be considered when using them.

Similar threads

  • Calculus and Beyond Homework Help
Replies
3
Views
1K
  • Calculus and Beyond Homework Help
Replies
2
Views
509
  • Calculus and Beyond Homework Help
Replies
17
Views
2K
  • Calculus and Beyond Homework Help
Replies
6
Views
472
  • Calculus and Beyond Homework Help
Replies
2
Views
328
  • Calculus and Beyond Homework Help
Replies
4
Views
502
  • Calculus and Beyond Homework Help
Replies
8
Views
1K
  • Calculus and Beyond Homework Help
Replies
26
Views
978
  • Calculus and Beyond Homework Help
Replies
3
Views
874
Replies
14
Views
1K
Back
Top