What's the difference between arccos(x) and sec(x)
My question might sound dumb, but I don't really see why the graphics of arccos(x) and sec(x) are different, because as far as I know arccos is the inverse cosine function (cos(x)^-1) and sec equals 1/cos (source Wolfram|Alpha). Then why aren't they equal?
Thanks in advance.
$\arccos x$ means the angle $\alpha$ in the interval $[0,\pi]$ such that
$$ \cos\alpha=x $$
while
$$ \sec x=\frac{1}{\cos x} $$
So $\arccos0=\pi/2$, while $\sec0=1$.
I believe you're misled by the $\cos^{-1}$ notation somebody uses for $\arccos$.
From a "function theory" point of view, the notation $\cos^2 x$ is inappropriate, because it should mean $\cos(\cos x)$; however, $\cos^2x=(\cos x)^2$ has been used for centuries because it's practical and in many formulas you need the cosine squared, while the cosine of the cosine is rarely needed.
Mixing the two notations, that is using $\cos^{-1}$ for the "inverse function of the cosine" is, at the least, confusing.
That's a problem of notation and probably a lack of definitions. We define $\sec x$ as the multiplicative inverse of $\cos x$, in other words, fixed $a \in \mathbb{R}$, $\sec a$ is the number such that $\sec a \cos a = 1$. Now $\arccos x$ is a little different thing: it's the inverse function of $\cos x$.
I don't know if you've learned this but the formal definition of a function is that of a collection of ordered pairs. In other words, since a function from a set $A$ to a set $B$ should be a rule assigning for each $a \in A$ some $b \in B$ we can simply define a function as the set of all ordered pairs of elements in $a$ together with related elements in $b$. However, we require the additional property that if $(a,b) \in f$ and if $(a,c)\in f$ then $b = c$ and this is just the formal way to state the "vertical line rule". Since the second element in each pair is unique we give it a name: if $(a,b) \in f$ then $b = f(a)$. Also to state starting and ending sets we write functions from $A$ to $B$ as $f: A \to B$.
Now, if you have a function you have a collection of ordered pairs right? So, you can create a new set of ordered pairs by reversing the pairs. So if $f : A \to B$ is a function from $A$ to $B$ we define the inverse $f^{-1}$ by the property that $(a,b) \in f^{-1}$ when $(b,a)\in f$. Now it's not at all clear when $f^{-1}$ is a function. Just to show you that consider the following function that maps naturals to naturals:
$$f = \{(1,2), (3,2), (4,1)\}\subset \mathbb{N}\times \mathbb{N}$$
This is a function by our definition. Now the inverse is $f^{-1} = \{(2,1), (2,3), (1,4)\}$, now this isn't a function because $(2,1)\in f^{-1}$ and $(2,3)\in f^{-1}$. So $f^{-1}$ will be a function if the original function also satisfies $f(x) = f(y)$ implying $x = y$. This kind of function is called one-one, and so if $f$ is one-one, $f^{-1}$ will be a function called then inverse function.
Also, if $f: \mathbb{R} \to \mathbb{R}$ has an inverse function $f^{-1}:\mathbb{R} \to \mathbb{R}$ then $f(f^{-1}(x)) = x$ and $f^{-1}(f(x)) = x$. So $\arccos$ is defined precisely this way: fixing one interval where $\cos$ is one-one, you define $\arccos$ in that interval by the property that $\arccos x$ is the number $y$ such that $\cos y = x,$ in other words, it returns you the value of angle whose cosine is $x$.
Just a reference to finish: you can find treatments like this in books like Spivak's Calculus or Apostol's Calculus Vol. 1. I hope the way I exposed this helps you a little. Good luck!
EDIT: The problem of notation I've mentioned and forgot talking about is that both the multiplicative inverse and the inverse function are in some contexts denoted by $\cos^{-1}$ and this usually happens to all trigonometric functions. So to avoid confusion, I recommend writing $\arccos$, $\arcsin$ and so on for the inverse functions.