I have stuck out with trying to figure this out. Its for a machine at work. I get two measurements off a laser sensor and I need to know how to calculate the angle circled in red. The machine rotates so I have the angle that the machine is currently rotated (70 deg in the drawing) I can draw this up in solidworks (like here) and get the angle with the information provided, but I need to know how to calculate it on the fly using formulas. The first line at 70 degrees, the other two lines are perpendicular to the 70 degree line. The measurement of the two perpendicular lines are the ones measured with the sensors, and finally I need to know the angle of the far left line. I tried posting this to fiverr in hopes that a math / trig tutor would help, but they are not taking the job.
If anyone has any ideas on how to solve this or where I might be able to find someone to solve it I would appreciate suggestions This project has me using all kinds of trig and its been fun, but this one I canât seem to find a way todo it.
Whatâs the length of the first leg off of the âfulcrumâ? That smells like an interesting, if not important datum. Then start breaking things into trianglesâŠ
I redrew in an autocad clone & did the math in openscad to get the equations. Here is what I came up with.
Here is the math in openscad and I attached an image showing the variables. I had to solve for angle X in this image. The angle X (22.6449) is added to the 70 to get the 92.6449
ANG1 = 70.0;
A = 2.0;
B = A * cos(70);
echo ("B = ",B);
D = 1.9 - B;
echo("D = ",D);
C = A * sin(70);
echo("C = ",C);
E = 2.0 - D;
echo("E = ", E);
X = atan(E / C);
echo("X = ", X);
ANG = 70 + X;
echo("ang = ",ANG);
Î and Îâ are in degrees, not radians, obviouslyâŠ
Is that what youâre saying? Where the 0.1 is the difference of the parallel segments, specifically, the upper/outer segment minus the lower/inner segment. And if they are kept parallel, then my concerns about the segment length from the âfulcrumâ to the lower segment is moot, I thinkâŠ
Every number that isnât circled can change. I want to calculate the circled angle out of those not circled values. Here is another example keeping the 70 the same.
Thank you so much for this. I paid someone to do this on Fiverr and didnât get an answer. Also thank you for such detail in your answer. Once you drew out the triangles I got it! I checked it with some other values and the math matches what the cad shows so its perfect.
One thing I donât understand is what you meant by doing the math in openscad? Did you figure out the A,B,C,D,E and X by drawing all the triangles, or did Openscad do that for you somehow?
When I do this I get 111.478. I see you and K Cummins have a very similar answer with slight variations in the order of operations. I tried it both ways with the addition before the division and the addition after the division but neither answer matched the 92.6649. Do you have a picture showing the triangles you drew for this math. I want to understand it as much as I can.
I tried your formula, but I donât get the correct answer. Using your formula I came up with 94.8899. You and Nicholas have very similar formulas so I am curious what triangles you guys drew to come up with these. Thank you for your input!
when back check my equation with the numbers from your original post, I get 92.64488 (rounded). I did my dwg and trig by hand, and I also combined constants in my equation where possible so it might not translate directly with new numbers.
Bear in mind your answer is what I have as theta plus the 70 degrees that references the horizontal dotted line (ignore the far left vertical dotted line)
I drew up your problem in CMS IntelliCAD (an AutoCAD clone) so I knew what numbers I was looking for and could check my math graphically. I broke the problem down into right triangles and went from there. I just used OpenSCAD because I am familiar with it. That is not really what OpenSCAD is normally used for. I could have done the math in a spreadsheet and would have had the same result. The one advantage to using OpenSCAD here is not having to worry about radians.
I liked @kvcummins method of getting it all into one equation.
Thank you to everyone who took the time to look at this. You guys are really amazing. There is so much intelligence and wisdom on this forum. This math is needed to line up a vacuum gripper to its target.