Skip to main content
GameDev.net gamedev.net
🔒 Locked

sin^n(x)

Started by moagstar Jan 12, 2005 at 11:16 AM 21 replies 4k views
Original Post
moagstar
moagstar
I have seen the symbol sin2(x) sin3(x) ... sin5(x) where the numbers are superscripted like power of, what function is this and how do I evaluate it?
SiCrane
SiCrane
sinn x = (sin x)n

Basically, it saves you from having to type out extra parenthesis.
furby100
furby100
With the sole exception of sin-1(x), which means the inverse sine, or arc sine, and NOT the cosecant.
Dmytry
Dmytry
sin2 x usually stands for (sin(x))2
and same for 3, 5, etc.

It oddly "contradicts" with other notation where sin-1 x = arcsin(x)

Obviously, it is bad and confusing.

Personally, i find "sin-1 x = arcsin(x)" to be more logical and useful, (so if I would be defining notation, sin2 would mean sin(sin(x)). But i'm is not a president of the Earth yet, so i currently can not enforce such change...[grin]).
higherspeed
higherspeed
It's written like that because writing it the other way would be sheer lunacy.

sin^2(x) is clearly (sin(x))^2, sin(x)^2 is ambiguous, it could be (sin(x))^2, or it could be sin(x^2).

The concept of sin(sin(x)) rarely arises, due to the nature of the origins of sin and cos. Off the top of my head it would be needed when iterations are involved. Then it's the realm of contraction mappings and such like, so different notation is used, as often a different domain is chosen.
Dmytry
Dmytry
Quote:
Original post by higherspeed
It's written like that because writing it the other way would be sheer lunacy.

sin^2(x) is clearly (sin(x))^2, sin(x)^2 is ambiguous, it could be (sin(x))^2, or it could be sin(x^2).

The concept of sin(sin(x)) rarely arises, due to the nature of the origins of sin and cos. Off the top of my head it would be needed when iterations are involved. Then it's the realm of contraction mappings and such like, so different notation is used, as often a different domain is chosen.

yes, sin(sin(x)) is rarely used, but asin(x) is used pretty often, and is written as sin-1 , that logically comes from sin(sin(x)) idea.

If you need squared sine, it is not hard to write (sin x)2 , that I consider the only logical way to write squared sine.
sin2 x instead of (sin x)2 is no more logical than writing a +2 b instead of (a+b)2 and a +-1 b instead of a-b . Fact that i or you can remember some oddity doesn't make it less odd.
b2b3
b2b3
You can also use sin-1(x) for arcsin(x). This won't cause so much confusion, but I haven't seen this too much.
Dmytry
Dmytry
Quote:
Original post by b2b3
You can also use sin-1(x) for arcsin(x). This won't cause so much confusion, but I haven't seen this too much.

Good idea.
Staffan E
Staffan E
It's not very hard to write arcsin(x) and it cannot be misunderstood.
Hack my projects! Oh Yeah! Use an SVN client to check them out.BlockStacker
Dmytry
Dmytry
Quote:
Original post by staaf
It's not very hard to write arcsin(x) and it cannot be misunderstood.

agreed. Same for (sin x)2
Staffan E
Staffan E
Quote:
Original post by Dmytry
agreed. Same for (sin x)2


Exactly. As long you remember the parenthesis but that isn't very hard either.
Hack my projects! Oh Yeah! Use an SVN client to check them out.BlockStacker
higherspeed
higherspeed
There's a widely used convention that is agreed on by the vast majority of mathematicians, I would really advise that you use it. As for Dmytry's a + b example, I'd say that it's completely different as + is a binary operator. Anyway as previously said trigonometric functions are the exception to the rule, due to complications that arise when applying the rule.

Writing (sin x)^2 is fine, but is easily miswritten or understood as sin x^2=sin(x^2). By all means write what you want, making sure it's not ambiguous, but don't claim the other way is ambiguous, it is not.
Dmytry
Dmytry
I'm kinda pedantic about math, and prefer when certain expression either have clear, well defined meaning, or have well-defined sintax error and no meaning.
I prefer to have _formal_ way to identify certain expression as ambiguous or containing sintax error. Not some fuzzy logic.
For simplest example of ambiguous thing, i don't really sure what's
sin-2 sin2 1
equals to. Sure , only bad people would write something like that, but can you please give me some *formal* way to say that certain expression is "bad"? "If it can be interpreted in several ways" is not formal, because finding *all* ways how certain expression could be interpreted is not a formal operation.

Simplest interpretation:
sin-2 sin2 1 = cosec2 sin2 1 ,it would be the only answer if not existence of special case sin-1, and fact that we don't need any negative powers of trigs because we can just write "cosec" or something instead. So negative powers may mean completely different things.

Or maybe
sin-2 sin2 1 = (arcsin sin2 1 )2 ?

or maybe
sin-2 sin2 1 = arcsin sqrt(sin2 1) = 1 ?
(note that
sin-1 sin1 1 = arcsin sin 1 = 1
)
.
Also, what does f2 x mean? What about f-1 x ? Or f-2 x ?

Really, if we "raise function to power" , we do
fn=f(f(f(...x...))) .
f0 x = x
f-1 x = inverse_f(x)
f-n x = inverse_f(inverse_f(...x...))
If we raise function's result to power, we get things like
(f x)2
(f x)-1
(f x)-2
but when notations is mixed depending to sign, it is certanly not a very good thing.
b2b3
b2b3
For powers of general function i use f2(x). I never use f-1(x) for inverse function, because it can be easily confused with 1/f(x). Instead I use f-1(x) for inverse or sometimes more complicated form when you say that g(x) is function such g(f(x))=x (but this is rare :).
higherspeed
higherspeed
Well b2b3, you're syntax is wrong, f^2(x) = f(f(x)) in the general case. There is no ambiguity in general.

Dmytry, you seem to be looking for a way to determine ill-defined statements. When someone makes a mistake then you just have to use common sense and look at the context. There can be no laws for working out badly written statements, just guidelines.
b2b3
b2b3
Quote:
Original post by higherspeed
Well b2b3, you're syntax is wrong, f^2(x) = f(f(x)) in the general case. There is no ambiguity in general.


That's interesting. I always thought that fn(x) is n-th power of f(x).
higherspeed
higherspeed
I probably shouldn't say 'you're wrong' in such certain terms, it's only notation. Most mathematicians would interpret it differently though. If it's just for your own working, etc then it doesn't matter. Still it's nice to be consistent with everyone else.
GameCat
GameCat
Also, f^(-1) is *widely* used for the inverse of f, NOT to mean 1/f(x) so you're actually using notation that is completely opposite to most of mathematics :)
Dmytry
Dmytry
Quote:
Original post by higherspeed
I probably shouldn't say 'you're wrong' in such certain terms, it's only notation. Most mathematicians would interpret it differently though. If it's just for your own working, etc then it doesn't matter. Still it's nice to be consistent with everyone else.

It is even nicer to use notation that is consistant with itself. I mean, where sin2 and f2 have same meaning.
Way Walker
Way Walker
Most of the time, the parentheses around a trignometric function's argument are omitted, so the sin2x notation is used to remove ambiguity. It is a special case, but it can really increase the readability of complex statements.

Also note that it's common for f(n)(x) to mean the nth derivative of f wrt x. I don't think I've ever seen fn(x) to mean (f(x))n or f(f(...f(x)...)). However, my not having seen it doesn't mean anything.

The problem is, mathematical notation can vary a lot. A wedge can mean "wedge product" when working with tensors or "meet" when working in lattice theory or "and" in symbolic logic (although the latter two are related). It's not uncommon for a text book or paper to define the meaning of the notation it'll be using and point out where different notation has been used with the same meaning or the same notation has been used with a different meaning. It's also not uncommon for texts and published papers to use imprecise notation, especially ellipses (...). The lack of precision is paid for by the increased clarity.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.