Expression simplification

  • Thread starter mikeley
  • Start date
7
0

Main Question or Discussion Point

Can you please tell me how theta1 was obtained from this system:

Px=C1(a2*C2+d4*S23)-d2*S1
Py=S1(a2*C2+d4*S23)+d2*C1

theta1=atan((Py*sqrt(Px^2+Py^2-d2^2)-d2*Px)/(Px*sqrt(Px^2+Py^2-d2^2)+d2*Py))

theta1=atan((-Py*sqrt(Px^2+Py^2-d2^2)-d2*Px)/(-Px*sqrt(Px^2+Py^2-d2^2)+d2*Py))
 

Answers and Replies

AKG
Science Advisor
Homework Helper
2,559
3
Please use [itex]\LaTeX[/itex]. Also, it might help to explain what Px, C1, C2, a2, etc.. are. Also, [itex]\theta[/itex] doesn't occur in your first two equations, so I have no idea how it was found, unless you explain what your symbols represent.
 
Fermat
Homework Helper
872
1
since S1 and C1 don't appear in the two final expressions, then perhaps S1 is sin(theta) and C1 is cos(theta) ??

Latex would be nicer.
 
Last edited:
7
0
Sorry AKG and Fermat. Here is my post modified:

a2, d4, Px, Py are all constants

[tex]

Px=\cos(\theta1)*(a2*\cos(\theta2)+d4*\sin(\theta2+\theta3))-d2*\sin(\theta1) [/tex]

[tex]
Py=\sin(\theta1)*(a2*\cos(\theta2)+d4*\sin(\theta2+\theta3))+d2*\cos(\theta1) [/tex]

[tex]
\theta1=\arctan((Py*\sqrt(Px^2+Py^2-d2^2)-d2*Px)/(Px*\sqrt(Px^2+Py^2-d2^2)+d2*Py)) [/tex]

[tex]
\theta1=\arctan((-Py*\sqrt(Px^2+Py^2-d2^2)-d2*Px)/(-Px*\sqrt(Px^2+Py^2-d2^2)+d2*Py)) [/tex]
 
AKG
Science Advisor
Homework Helper
2,559
3
Are you sure this is right. Before I do anything, it looks strange that [itex]d4,\, \theta _2,\mbox{ and }\theta _3[/itex] don't appear anywhere in your second pair of equations. Also, just for clarity, use subscripts, so you probably want to write [itex]d4[/itex] as [itex]d_4[/itex] unless you mean the fourth power of d, [itex]d^4[/itex]. Anyways, take the first equation for [itex]\theta _1[/itex] and plug in Px and Py, and see if the equations are even correct. If not, then we need not go any further. If they are, then perhaps in working backwards you can see a general method to go "forwards" if they started you off with a slightly different Px and Py.
 
AKG
Science Advisor
Homework Helper
2,559
3
Also, you're telling us that you wrote "S23" and expected that anyone would understand that you meant [itex]\sin (\theta _2 + \theta _3)[/itex]? What were you thinking?
 
7
0
AKG said:
Also, you're telling us that you wrote "S23" and expected that anyone would understand that you meant [itex]\sin (\theta _2 + \theta _3)[/itex]? What were you thinking?
Would you like some salt and pepper to go with that :wink:

in my equations I have only d4 not dA, and d2 is not d^2 and d4 is not d^4. d2 and d4 are two constants raised to the first degree. And yes, I checked my equations before posting, and they are ok. So some how in the result, t1=..., the expression containing d4 was canceled.
 
Fermat
Homework Helper
872
1
Here are some pointers for a solution.

Multiply Px by sinθ and Py by cosθ. subtract Pxsinθ from Pycosθ to get rid of the bracketed term.
You should end up with Pycosθ - Pxsinθ = d2.
Divide both sides by cosθ.
Square both sides and get a quadratic in tanθ.
Solve ...

I ended up with a simpler form for tanθ.

[tex]tan\theta = \left(P_xP_y \pm d_2\sqrt{P_x^2 + P_y^2 - d_2^2}\right) / (P_x^2 - d_2^2)[/tex]

I manipulated your expression(s) for tanθ and ended up with my expression, so I suppose it could be done backwards - get your expression from mine - but it was a wee bit tedious.
Do you need to use the original form(s)?
 
7
0
Thank you very much Fermat. No, I don't have to use the original form.
 

Related Threads for: Expression simplification

Replies
4
Views
1K
Replies
2
Views
1K
  • Last Post
Replies
1
Views
1K
  • Last Post
Replies
10
Views
2K
  • Last Post
Replies
4
Views
508
  • Last Post
Replies
4
Views
601
Replies
5
Views
5K
Top