|
-
Apr 14th, 2001, 12:06 PM
#1
Thread Starter
Frenzied Member
Here i am again. Can someone solve this equation. For which values of x the equation is correct. I solvd like a million of this, but this one is a small problem.
Code:
sin2x = sinx + 1 - cosx
-
Apr 14th, 2001, 12:42 PM
#2
Fanatic Member
More Info?
For what range of values do you want solutions of x for? i.e. -180 < x < 180 etc? I'm assuming this is a trig-equation...?
Does sin 2x mean (sin (x))^2 (sin of x, squared) or sin(2x) (sin of 2*x)? Sorry for the confusion, i just want to get it straight.
Later
Digital-X-Treme
Contact me on MSN Messenger: [email protected]
[VBCODE]Debug.Print Round(((1097) - ((55 ^ 5 + 311 ^ 3 - 11 ^ 3) _
/ (68 ^ 5))) ^ (1 / 7), 13)[/VBCODE]
-
Apr 14th, 2001, 01:04 PM
#3
Banned
In the first case given by [Digital-X-Treme] I end up with:
cos(x) + tan(x) = 1
From here I'm stuck.
-
Apr 14th, 2001, 02:00 PM
#4
Thread Starter
Frenzied Member
No, sin2x = sin(2x), if it was square i would have said it.
-
Apr 14th, 2001, 02:42 PM
#5
Frenzied Member
If I wasn't feeling quite so lazy, I'd (try to) solve this Instead I'll suggest you try using one of the formulae that looks like:
Sin(A + B) = Sin(A)Cos(B) + Cos(A)Sin(B)
I've fogotten if that's correct, but there are 4 trig identities that are a bit like that, for Sin(A+B), Sin(A-B), Cos(A+B) and Cos(A-B). I think you might find your answer there.
You can substitute something like Sin(0) or Cos(90) (that's in degrees not radians obviously) for zero.
Harry.
"From one thing, know ten thousand things."
-
Apr 14th, 2001, 03:14 PM
#6
Banned
So far I have got x >= 90º
Not much but...
-
Apr 14th, 2001, 04:02 PM
#7
Frenzied Member
Try newton-Raphson
There might be some analytical way to solve this, but brute force Newton-Raphson will find roots if there are any. Do successive approximations on the Lastx formula until the result does not change much.
Function(x) = sin(2x) - sin(x) + cos(x) - 1
Derivative(x) = 2cos(2x) - cos(x) -sin(x)
Nextx = Lastx - Function(Lastx) / Derivative(Lastx)
I used MathCad7 to work on the above, getting, 45 & 225 degrees as solutions.
It seems as though adding multiples of 360 to the above solutions would give other trivial solutions.
Knowing the roots suggests that a little manipulation might have yielded those roots without using Newton-Raphson.
Whenever I can find the derivative and have my MathCad7 software available, I go for this method. Even writing a VB program is not tuff for something like the above.
Even if you do not know anything about derivatives (calculus is the name of the general subject), you can use a table from a handbook and work it out for a lot of functions.
Live long & prosper.
The Dinosaur from prehistoric era prior to computers.
Eschew obfuscation!
If a billion people believe a foolish idea, it is still a foolish idea!
VB.net 2010 Express
64Bit & 32Bit Windows 7 & Windows XP. I run 4 operating systems on a single PC.
-
Apr 14th, 2001, 04:57 PM
#8
trying
ive never had trigo... but is that possible?:
1. sin2A = 2*sinA*cosA
2. 1 = sinA*sinA + cosA*cosA
wich means:
sin2A = sinA + 1 - cosA is the same like
2*sinA*cosA = sinA + (sinA*sinA + cosA*cosA) - cosA
then
cosA-sinA = (sinA*sinA + cosA*cosA) - 2*sinA*cosA
or
cosA-sinA = (sinA - cosA)^2 or
cosA-sinA = (cosA - sinA)^2 .. so
either
cosA - sinA = 1 or
cosA - sinA = 0
reply
-
Apr 14th, 2001, 04:59 PM
#9
further
-1<sinA,cosA<1, so the first cannot be
so: sinA = cosA -> A = 45° ?
-
Apr 14th, 2001, 05:01 PM
#10
2nd
180 + 45 = 225, that would be the 2nd solution..
*feelgood*
laterz
-
Apr 14th, 2001, 06:00 PM
#11
Fanatic Member
Infinite Number of Solutions
romanize, there are an infinite number of solutions for trigonometric equations like these. That is why you specify a range, such as -360º < x < 360º.
e.g. Solve
f(x) = sin(2x) - sin(x) + cos(x) - 1 for 0º < x < 720º
Laterz
Digital-X-Treme
Contact me on MSN Messenger: [email protected]
[VBCODE]Debug.Print Round(((1097) - ((55 ^ 5 + 311 ^ 3 - 11 ^ 3) _
/ (68 ^ 5))) ^ (1 / 7), 13)[/VBCODE]
-
Apr 14th, 2001, 06:06 PM
#12
thx
yeah, if that's what i think, that's clear .. i just wanted to link to Guv's reply&MathCad7..
bye
-
Apr 15th, 2001, 06:02 PM
#13
Frenzied Member
Well done!
Romanize: A job well done! Your manipulation of the equation led to correct solutions.
Contrary to other posts, (cosA - sinA) can be equal to one.
cosA - sinA = 1 when A = -90 degrees. (cos-90 = 0 & sin-90 = -1)
Hence there are three basic solutions: 45, 225, & -90 (or +270). A myriad more can be found by adding 360 to one of the basic solutions.
I did not find the one at -90 degrees. Newton-Raphson would have founds it if I had made a guess closer to -90(or +270), but the initial guesses I used were closer to the other soultions.
Live long & prosper.
The Dinosaur from prehistoric era prior to computers.
Eschew obfuscation!
If a billion people believe a foolish idea, it is still a foolish idea!
VB.net 2010 Express
64Bit & 32Bit Windows 7 & Windows XP. I run 4 operating systems on a single PC.
-
Apr 15th, 2001, 06:22 PM
#14
ok
u r right there..
i'm going 2 install w95 now on my old machine for assembly programming only *s*,
laterz
-
Apr 15th, 2001, 06:23 PM
#15
Thread Starter
Frenzied Member
Thanks for the fast (and correct) replies, guys.
-
Apr 15th, 2001, 06:25 PM
#16
vb7
u have the vb7 installed, he (not qb7, i think)? how is it ?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|