what's the difference here?

allegansveritatem

Full Member
Joined
Jan 10, 2018
Messages
962
What is the difference between these two expressions. Is this just two different ways of referring to the same thing?
12631
 
Not at all.

The first says that you first apply the function f, and then take the absolute value of the result.

The second says that you first take the absolute value of x, then apply f to the result.

For example, if we take f(x) = 3x + 2, then
  • |f(x)| = |3x + 2|, and |f(-1)| = |-1| = 1; but
  • f(|x|) = 3|x| + 2, and f(|-1|) = f(1) = 3(1) + 2 = 5.
The two functions are compositions of f(x) and abs(x), and composition is not commutative: Changing the order results in different functions.
 
Not at all.

The first says that you first apply the function f, and then take the absolute value of the result.

The second says that you first take the absolute value of x, then apply f to the result.

For example, if we take f(x) = 3x + 2, then
  • |f(x)| = |3x + 2|, and |f(-1)| = |-1| = 1; but
  • f(|x|) = 3|x| + 2, and f(|-1|) = f(1) = 3(1) + 2 = 5.
The two functions are compositions of f(x) and abs(x), and composition is not commutative: Changing the order results in different functions.
I will have to go over this a few times to get exactly what you are saying here. When you say "apply the function" I guess you mean perform the operations inside the abs value symbol and then take the positive of the result?So the first applies to the whole function and the second only to the x element?
 
Consider the function \(\displaystyle y=f(x)=(x^3-1)\).
\(\displaystyle f(-2)=(-2)^3-1=-8-1=-9\) so \(\displaystyle |f(-2)|=9\) BUT

\(\displaystyle f(|x|)=(|x|^3-1)\) so \(\displaystyle f(|-2|)=(|-2|^3-1)=7\)
I am having my nightly near-death experience but in the morning I will go over your post and parse it. I think it will help clarify the situation. Thanks.
 
I will have to go over this a few times to get exactly what you are saying here. When you say "apply the function" I guess you mean perform the operations inside the abs value symbol and then take the positive of the result?So the first applies to the whole function and the second only to the x element?
Apply the function (namely, f) means "do what it says". The function f in my example says, "triple the input and add 2". So when we apply the function to the input -1, we triple it (-3) and add 2 (making -1): f(-1) = -1.
 
Apply the function (namely, f) means "do what it says". The function f in my example says, "triple the input and add 2". So when we apply the function to the input -1, we triple it (-3) and add 2 (making -1): f(-1) = -1.
Got it. I think my problem had something to do with the way my book refers to functions as f(x) no matter what the actual function may be. I am not used to that convention.
 
… book refers to functions as f(x) no matter what the actual function may be …
That's common. Your book probably refers to inputs as x, too, no matter what the actual input may be.

Symbols x and f(x) are generic names for discussing arbitrary functions. Those symbols represent a function's input and output, respectively.

f(|x|) means we input the absolute value of x.

|f(x)| means we input x and then take the absolute value of the output.

?
 
Top