What's new

New Version of the 4 Link Calculator

Done with the math portion of link sizing. Feeling lazy and don't feel like explaining equations much right now. So, gonna go over a few basic formulas then paste in the equations for the stuff that we want to look at. If you want more details, there's plenty of stuff on beams and columns online.

The math is based on two values: cross sectional area and the moment of inertia.

Cross sectional area is pi*radius^2. If its not solid we subtract out the area that is missing.

Moment of inertia for a rod along it axis is pi*diameter^4/64. If its not solid we subtract out the moment of inertia for the area that is missing.

Link weights are straight forward. Cross sectional area times length times density. For the total weight of a link we add the weight of the rod ends. This does technically predict a higher weight than reality since we are not accounting for the rod ends reducing the length of the link.

We have 4 factor of safeties and dent resistance to calculate.

Yield strength, modulus of elasticity, and density are all properties of the link material.
Link force is the maximum force going through the link that we calculated earlier.
Bending is the weight of the vehicle pushing down on the mid point of the link.
Dent resistance is a ratio comparing a panel that is the same thickness as the link wall to a panel of 1080 steel that is 1/4" thick. It is based on a formula from here: Dent Resistance of Automotive Panelling.
Dent resistance constant is the dent resistance of 1080 steel that is 1/4" thick. The value of k does not matter since it divides out when we find the ratio. In number form it is: 53700^2*0.25^4
  1. Yield: abs(yield strength * cross sectional area/ force on link)
  2. Buckling: abs(pi^2 * modulus of elasticity * moment of inertia / (link length^2) / link force)
  3. Bending: abs(yield strength * moment of inertia / (0.125 * link diameter * link length) / (.5 * vehicle weight))
  4. Rod end: abs(rod end rating / link force)
  5. Dent resistance: yield strength^2 * link wall thickness^4 / dent resistance constant
 
Got lazy and distracted again. Anyway, driveshafts. As a note this is for CV style driveshafts and will not work for slip yoke style driveshafts though it can estimate the needed slip yoke travel.


Movement through travel is easy. Say thing we did for wheel centers, panhards, and probably one or two other things. Only thing interesting here is the two different ways to get the pinion location at ride. The straight forward measure it approach with some rotation math to allow for a new pinion angle to be used. And hypoid offset and pinion length rotated from level by ride pinion angle. See rotation formulas in post 105 for both cases.

Driveshaft length is easy. That formula was already done in post #105.

Pinion and caster angle are as easy as adding the ride height value to the value at any given travel point.

That leaves u-joint angles. Hope you payed attention in 3d calculus. There is a handy formula we can use:

COS(angle between two vectors) = dot product of the two vectors / length of the vectors multiplied together.

It is important to note that the values of X, Y, and Z are lengths not coordinates for this section

Dot product is easy: x1*x2 + y1*y2 + z1*z2

We already have the formula for the lengths. See post 105. But without the subtraction

Now its a matter of determining the vectors. There are three we will need: driveshaft, pinion, t-case.

Driveshaft vector: component distances of the driveshaft. So subtract the axle yoke center point from the t-case yoke center point.

Pinion vector: We set the X length to 1. This simplifies math later on. Y is 0 since the pinion doesn't have an angle in top view. Z is the tangent of the pinion angle times the X component, so just the tangent.

T-case vector: X length is 1. Y is tangent of the angle in top view. Z is tangent of the angle from horizontal in side view.

There is attention needed when it comes to the signs on the vectors. All three vectors need to have the same X sign. So all positive or all negative.


Next post will be shocks. Likely to be split into 3 sections: movement, install ratios, spring stuff.
 
Finally got around to working on this some more. As promised, shock movement.

For shocks there is 3 main parts. The first is determining where lower end of the shock is. There are three options for this: On axle, lower link, upper link.

On axle is the easiest. We have done that math numerous times already.

On link is a little trickier. The rotation formula is used. The 2 points are easy. Point being rotated is the shock end, point being rotated about is the frame end of the link. The angle is the harder part. But a little bit of trig can find the value.

Repeat for up to four shocks.

As part of movement we can check how far apart the shocks are. The method for finding the distance between 2 line segments was in Post 105. The only value we care about is the lowest distance.
 
hi.. where can i dowload the latest version?

Read the first post of this thread.
w.bingeclock.com%2Fmemes%2Fsimpsons___facepalm_doh.jpg
 
Finally getting around to making progress on this again. No real excuse for not working on it. Just been lazy and distracted by video games. I hope to get to the spring portion soon. The math for it is not bad. However the available spring rate tables may be interesting.

So, onto shocks. The math is the same for coilovers and bypasses, and in some cases we can reuse part for both. Before getting into the install ratio math, I want to discuss the ways to do this and why it is done the way it is.

This portion of the calc is what probably needs the most review and input. The more feedback I can get on this section the better. I do ask that you read the last section, even if you skip reading the math portion.

One way to do it is to is to compare the travel position of the wheel to the shock. This works great in CAD, or the real world where we can use the limits of the shock to get the limits of wheel travel. This is something we can do, since shock lengths are inputs. However, doing this means more inputs are required. And pulling ratios from this may be difficult.

Another approach is to use the differences in change in length for the install ratios to get the ratio. But this only gives us info between the points of measurement not at the points.

These two approaches do not break down the components of the installation ratio.

This brings us to the third approach. Using an imaginary force input of 1 at each stage and seeing what the resulting force is. Multiply them all together for the result.

All 3 methods have a similar fault. They do not account for rotation of a link when a shock is mounted to it. In theory, the spring will attempt to rotate the link through travel.

MATH

An important part is that we care about the vertical force at the wheel, I think. Not the total force at the axle. This will come back up at the end.

Because angles and distances change throughout travel, the ratio needs to be calculated at every point. The other interesting part is that at any given point the wheel and everything else on the axle is moving along a circular path centered at the instant center at that point of travel. And the IC moves.


Starting at the shock and moving through the various factors towards the wheel.

The first factor is inboarding. This is the leaning in (or out) of the shock. From a math standpoint, this is the difference in Y values of the shock ends.

This is done by taking the dot product of the force of the shock and the unit vector of its side view projection. However, since we are projecting a vector onto a projection of itself, it simplifies to dividing the length of the side view projection by the length in 3d.​


Next factor is the link factor. This is the lever arm if the lower end of the shock is mounted to the upper or lower link. If it is on the axle, it is 1. Good news is that this one is constant throughout travel.

The math is pretty easy. It is the side view distance of frame mount to shock end divided by link length.​


Third is the distance ratio factor. This is the ratio between the distance to the wheel and the distance to where the shock’s force is applied to the axle. Whether the point is the shock end or the link point. And the pivot point for this lever is the IC.

The math for this is find the distance between the IC and the force point and the IC and the wheel center. And divide the Force point distance by the wheel center distance. It is possible for this part to have a ratio over 1 in the event that the shock is mounted behind the axle.​


The next one up is the shock angle factor. This is the angle between the shock and a line from the where the shock end is rotating about and the end of the shock. In the event of the shock being mounted on a link, rotation point is the frame end of the link. In axle mounted applications, it is the IC.

So, the easiest way to do this is through law of cosines to get the angle between the shock and the rotation point. We take the sine of the angle to get the factor.​


And the last of the factors is correcting for vertical force. Since the wheel moves on a circular path, it’s true force is tangential to the circle. We use the angle formed by the shock to IC line and a horizontal line.

Just like the previous factor, we use the law of cosines to get the angle. But this time we use take the cosine of the angle instead of the sine. The 3 points we use are the wheel center, the instant center, and a point level with the IC above the wheel center.​

Multiply all of the factors together to get the install ratio.

The last factor is one of the parts I am not so sure about. Measuring the wheel rate at the wheel makes sense. But at the same time, I wonder if it should be measured at the bottom of the tire since that’s what contacts the ground. Based on Milliken and Milliken’s book, it would be the first option, since the tire acts as a spring system as well. But on something where the IC is closer to the axle instead of a fair bit out it can make a big difference in the installation ratio. What does everyone think?
 
No new updates on version 7. Maybe this weekend I will get back to working on it.

Thanks to gobi_rubi for pointing out an issue with the change in length of the front driveshaft.

Also had to change some stuff with the version number input and use since it turns out 6.9 is greater than 6.10.
 
Now for the spring stuff. The math is easy, but there is a bit of setup stuff that needs to happen for the closest spring rates. Only planning to cover the math here.

We get a bit of a break here. We don’t have to do math at every travel step, and we do the bulk of the math twice per end. Once for the closest matching springs and again for the springs in use.

Before we can analyze the springs, we need to find the ideal spring rates.

At the time of writing this, there are two main approaches to selecting springs. The first approach is the method is frequency based as was used in the Coilover Bible written by Billavista on the Pirate4x4 forum. The other method is to target a spring preload. I will not get into which method is better or preferred in this thread. I intend to only go into as much detail as is needed for the calculator for either method. Along these lines, the calculator is able to switch between methods. Math wise the two approaches converge at the targeted spring rate of the wheel.



One thing to note before we go into the math, there are two spots where stuff is measured. The first is at the spring. The other is at the wheel. This is what the installation ratio is used for.



The frequency method is first. This method works by targeting a natural frequency of the undamped spring mass system. There are three sub approaches to this method: choosing the front frequency, choosing the front and rear frequency, and choosing the rear frequency. In the methods where only one end is chosen, the other end is determined as a function of speed and wheelbase.

The first step is to find the period of the suspension end in question. Formula below:

Period = 1/frequency​

If we are only choosing one end, we need to find the amount of time it takes the vehicle to travel its own wheelbase at a chosen speed. Formula is as follows. Note the conversion factor from mph to feet per second. I will address how metric is handled at some point in the future, if it wasn’t mentioned in an earlier post.

Time = 0.0568 * wheelbase / speed​

Next, we find the period of the end not chosen. If the front was chosen, we add the time to the period. If the rear was chosen, we subtract the time from the period.

And then we convert from periods back to frequency to get the target initial frequency.

Next up we need to find the corner sprung weights. See post 119 for sprung X CG

Front sprung mass = (Vehicle Mass - Front Unsprung Mass - Rear Unsprung Mass) * (sprung X CG / Wheelbase) / 2​
Rear sprung mass = (Vehicle Mass – Front Unsprung Mass – Rear Unsprung Mass - 2 * Front sprung mass) / 2​

This gives us everything we need to determine the target wheel rates at ride height. I think the constant comes from converting units.

Wheel Rate = (sprung corner mass * (2 * pi * target initial frequency) ^ 2) / 386.088​



Now to discuss the preload approach. This one is much simpler.

We divide the corner weight by the distant to 0 spring force. 0 spring force is the down travel plus the desired preload divided by the install ratio. The reason we divide preload by the IR and not the IR squared is because we are only dealing with correcting for distance, not distance and force.



Now we can start going into the spring stuff. Just gonna rapid fire this stuff.

First up are the ideal springs.

Ride spring rate = wheel rate / install ratio ^ 2​
Main spring rate = step up ratio * ride spring rate​
Tender spring rate = step up ratio * ride spring rate / (step up ratio -1)​

Next up, data points for the springs. This is for both the user inputted spring rates used and for the spring rates that are auto selected from a list of commercially available springs.

Ride spring rate = main spring rate * tender spring rate / ( main spring rate + tender spring rate)​
Step up ratio = main spring rate / ride spring rate​
Ride wheel rate = ride spring rate * ride install ratio ^ 2​
Bump wheel rate = main spring rate * full bump install ratio ^ 2​
Ride frequency = sqrt( 386.088 * ride wheel rate / corner sprung rate ) / ( 2 * pi )​
bump frequency = sqrt( 386.088 * bump wheel rate / corner sprung rate ) / ( 2 * pi )​
Predicted preload = (corner sprung weight / wheel rate + down travel) * ride install ratio​

The rest of the shock stuff is lengths, percent of the shock travel used, and distance from one line to another (post 105).



I think that is it for the shock math. I think that just leaves the generating plot data for wheel force and wheel rates and then the last of the math for predicting pitch.

Once that is done, it will be time to do the GUI. I do not plan to document that here, though I will likely share some screenshots as I go.
 
Been a bit since I have worked on this. Just been lazy and distracted by video games. Hoping to have the next and hopefully last math update by the end of the week. I've got some pretty good motivation to work on it finally. I have had the basics and the general math for solving a 3d 4 link floating around my head recently and I really want to give it a try. And a deeper dive into spring rates, slider stops, and step up ratios. But, I'm not letting myself work on those until V7.0 is released.

The focus for the last few days has been on redoing how I was handling variables with a focus on organization, everything working together, and passing information between the modules. Then started work on the wheel rates and wheel forces calculations and remembered that I need to solve most of the geometry at the coil slider travel positions. Oops. I don't think it will be a huge deal to add; I think I can tack it to the end of the normal travel math.

I did finish the rest of the small shock stuff mentioned in the previous post. Most of the wheel force is done. Just need to do the initial fully extended position. I am taking a break from doing wheel rates to write this. Pitch predictions shouldn't be a big deal.

That leaves only a few things before the GUI work can start Importing the tables for link sizing, materials and rod ends, saving/loading the inputs to/from a save file, and importing the available spring values. The first 3 should be easy; CSVs are pretty easy to work with. The last one is a pain. There is a few other new features I want to add, but none of them will take more than a few minutes to do. I also want to make it so that the inputs convert when switching units systems or front X coordinate system. Should be pretty easy.


But I do have a few questions that I would like community feedback on:
  1. Part of the shock IR is based on how vertical the wheel's movement is (wheel regression). Currently, it uses the wheel hub as the reference point. Should that be the tire's contact with the ground instead?
  2. Input for the slider stop's position. Percentage of travel, percentage + or - from ride, travel from full droop, + or - travel from ride, or distance + or - on shock from ride?
  3. And for you weird metric users, how are coilover sizes done? Is it still a 2.0", 2.5", ect. shock? What about travel, inches or mm? Spring length and rates?
 
But I do have a few questions that I would like community feedback on:
  1. Part of the shock IR is based on how vertical the wheel's movement is (wheel regression). Currently, it uses the wheel hub as the reference point. Should that be the tire's contact with the ground instead?

I guess the tire contact patch because this is what the tire actually sees? Not completely sure if it makes a difference on a 4 link SA though. I could see it making a difference on an IFS with lots of camber change through travel. I cant think of a situation where the contact patch moves a significant amount relative to the hub in a solid axle configuration, other than articulating or tire rolling over or bulging.
  1. Input for the slider stop's position. Percentage of travel, percentage + or - from ride, travel from full droop, + or - travel from ride, or distance + or - on shock from ride?

I think of slider stop location in distance away from slider at ride height (Last option listed). So 2" away from stop means I have roughly 3-4 inches of travel before it hits (I know that isnt exact just an estimate). I dont think many people are hitting the slider stop above ride height so not sure that a negative value is needed.
 
Last edited:
I guess the tire contact patch because this is what the tire actually sees? Not completely sure if it makes a difference on a 4 link SA though. I could see it making a difference on an IFS with lots of camber change through travel. I cant think of a situation where the contact patch moves a significant amount relative to the hub in a solid axle configuration, other than articulating or tire rolling over or bulging.
Its not so much the contact patch not being below the hub, its more about it moving in an arc and how vertical the part of the arc is.
I think of slider stop location in distance away from slider at ride height (Last option listed). So 2" away from stop means I have roughly 3-4 inches of travel before it hits (I know that isnt exact just an estimate). I dont think many people are hitting the slider stop above ride height so not sure that a negative value is needed.
I was afraid that was going to be the answer as I typed it. The one option that can't be tacked on to the geometry solver. Negative would be active at ride height. No really used, but still doable. Though I need to revisit what that means for the spring rate solving.
 
Its not so much the contact patch not being below the hub, its more about it moving in an arc and how vertical the part of the arc is.
But is the hub not following the same arc as the contact patch during regression/progression? I would think the only time this may be different is with a big change in camber/articulation.

I was afraid that was going to be the answer as I typed it. The one option that can't be tacked on to the geometry solver. Negative would be active at ride height. No really used, but still doable. Though I need to revisit what that means for the spring rate solving.
Could you just relate that input number to something easier to work with like percent of travel from full droop?
 
But is the hub not following the same arc as the contact patch during regression/progression? I would think the only time this may be different is with a big change in camber/articulation.


Could you just relate that input number to something easier to work with like percent of travel from full droop?
Hub and contact should be assumed to be on different arcs at any point. Different radiuses.

It could be estimated. Solving it gives more accurate results. It's not a huge issue, just another thing to do.
 
Hub and contact should be assumed to be on different arcs at any point. Different radiuses.

It could be estimated. Solving it gives more accurate results. It's not a huge issue, just another thing to do.
Different radius but still rotating around the same point, the IC, correct? Are you calculating IR based on the motion ratio or directly with geometry? Am I not correct to say If the hub moves 4" vertically the tire contact patch is moving 4"? The way you have it set up do you get different IR values when using the hub center vs tire contact patch?
 
Different radius but still rotating around the same point, the IC, correct?
Correct. Which creates the technicality that same radius means same arc.
Are you calculating IR based on the motion ratio or directly with geometry?
Geometry. Using motion ratio tells between 2 points not at 2 points.
Am I not correct to say If the hub moves 4" vertically the tire contact patch is moving 4"?
Yes and no. There is a setting to turn on and off tire compression estimation. But for sake of discussion, yes.
The way you have it set up do you get different IR values when using the hub center vs tire contact patch?
It should. May not be a big difference.
 
This should be the last post about the calculator's math. The last little bit was a lot of 1 step forward, 2 steps back.

The distance from the shocks to the body roll axis and the distance between links use formulas posted earlier in the thread. See post 105. The distance between links is also used as a check in shock sizing.

Also added caster change to pitch predictions. That was as simple as adding the pinion change to the overall angle change.

Added loading the tables used for rod end properties, link material properties, and available spring rates.


Then it became time to finish the shocks. Spring force, wheel rate, wheel force. All fairly easy in theory. Spring force is the distance the spring compresses times the spring rate. Wheel rate is spring rate times the installation ratio squared. Wheel force is shock force times the IR squared.

And that is where it started to unravel. To find those, the slider stop is needed. It is pretty easy to say, X distance from touching at ride. But to use that, you need to know where that is in travel. And solve the geometry for where it is in travel. And account for what happens if it is used to compress the spring at travel. The first two were not hard. Solve for shock length, check if at slider stop, repeat. Once location is known, solve for antis and IR. But accounting for the compression requires adding that case to the ideal spring math.


Once that was all wrapped up, all that remained was adding the pitch predictions. The math here isn't exact, just a prediction. Being on a slop is treated as accelerating, The nitrogen charge in the shock is ignored. First step was to get the half of the weight transfer:

.5 Weight Transfer = .5 * CG height * Acceleration in Gs * Vehicle Mass / wheelbase​
Using that value, we can get the change in load on a front corner and a rear corner. If we are predicting for a car on a slope, we add:

corner sprung weight * (cos(slope) - 1)​
We then select which anti value we need depending on if the acceleration is positive or negative. We also account for the anti of the slider stop here.

We then generate a list of force at the spring using:

Spring force = wheel force + .5 weight transfer * (1-anti) - load change​
We then find the closest value to 0, find the travel for said point, and calculate the percentage of load at each end of the car.


So that the math. Finally done with that. Next up is input and output handing with unit conversions. Then make the interface and test things. IO should be easy, I have most of the inputs done already.
 
Got through the input conversions last week. I plan to get through the output conversions by the end of this week. Had some idle time while generating animations for the shock theory thread over the weekend. Could have done the output handling then. But, I got a bit distracted by something else.
1681185191773.gif

Validated equal travel. Normally I would check the flex against CAD, but Fusion 360 is refusing to open properly right now. I am assuming that it is all correct based on it needing to have the right length links (error less than 1^-10) to exit the solver. And the link end points do not need to be symmetric.

This will not be in 7.0. For a few reasons. One of which is the compute time. Time to solve goes up exponentially with how many travel sample points there are. 5 points of bump and droop takes 11 seconds to run using parallel processing and 97 seconds running sequentially.
 
All of your work here is great. Want to start on an IFS/IRS calc next?
It's crossed my mind a few times to add it to the 4 link calc. It is not a possibility with the excel version. But the ability to work in modules is part of the reason for version 7.0.

As far as actually doing, maybe. The stuff I learned while doing 3d 4 link makes true wishbone suspensions pretty easy. Even turning and bumpsteer. The multi link stuff that we see on the newer ifs is a different beast. And that's the real hesitation, all the different styles. But now that you got me thinking about it, it's really no different than solving a 4 link.
 
Progress update. Just reached a huge milestone. Ran through all modules in order using the default values. Tested in English units and with the metric conversion. Tested panhard bar and one upper link. I did not verify the results. I could do it, but it would be extremely time consuming and it is much easier to wait until the GUI is made.

Next on the to do list. Loading and saving a design. Adding new materials and rod ends. Updating all inputs when the unit system changes. Then finally start work on the GUI.

Regarding the GUI, I wanted to sample the idea of making travel the Y axis of the output plots instead of the X axis. I feel like it will be more intuitive.



With the end goal in sight, and working through the rather dull task of handling unit conversions, my mind started to wander to what comes after V7.0 is released. Obvious answer is 7.x for bug fixes. But beyond that, different types of suspension and 3d viewing/clearances.

The calculator is setup to add new modules like viewing in 3d. Potential other future modules include roll bars and bump steer.

But in it's current structure adding different types of suspension is prohibitively difficult. At the same time, I experimented with a different approach to solver structure and variable management in my test 3d calc that would be far more manageable and practical for multiple suspensions. So, pending other distractions, I will likely begin the rewrite to support different suspensions once 7.0 is out. The good news is that the linked suspension math is already in code form and alot of stuff like the math for spring rates is relativly suspension type independent. A little bit of change will be needed, mostly to get away from solving front and rear simultaneously.

I would like to do a 3d viewer in 7.1, but enough of it would need to be rewritten for what will likely be V8.0 that it would be a waste of time. The nice part of it is that the saved designs should be able to go between versions in both directions, so there shouldn't be any reason to not use V7.0. The post(s) on the math behind 3d will likely be pretty soon and wishbone's will come eventually though it will be extremely similar.

Current planned new suspension types are wishbone and multilinked front and rear and trailing arm and a rzr style linked suspension in the rear. I am open to requests. Only limitations are nothing over constrained, and nothing relying on a spring for geometry. And preferably 4x4 related, for now. I am not planning to have all of them available in V8.0, but to instead roll them out over time just due to how much I expect to have to do to add a new type. Not all types will be 100% accurate, portals throw off anything having to do with antis and forces.
 
for multilinked I assume you mean, 3 link, radius arm, parallel 4 link, etc?

For the rzr style linked rear, would that also include the 5 link, like the rear of the Talon?
 
for multilinked I assume you mean, 3 link, radius arm, parallel 4 link, etc?

For the rzr style linked rear, would that also include the 5 link, like the rear of the Talon?
Solid axle will have radius arm, 3 link with panhard, 4 link with panhard (modeled as a 3 link), and triangulated 4 link.

Multi link ifs. So a 5 link. From what I could tell, RZRs use a three link with the hub built into the main link.
 
The math behind solving 3d articulation. Much like the 2d approach it solves for the travel at the lower control arms. At some point I will add an outer layer that solves for their travel with a given wheel travel input.

This will be in two sections, general logic and 3d movement of point on the axle. It should be noted that the second section and parts of it will be used in for figuring out double wishbone suspensions.

I will talk about things in terms of Positive Y (PosY) and Negative Y (NegY). That is to keep track of which side of the vehicle the link is on. Lower axle is abbreviated LA, lower frame as LF, upper axle as UA, and upper frame as UF. Each link end has an X,Y,Z coordinate.

We need a few values to start: length of each link and the distance between all axle link ends. It is a total of 10 distances all gained with the 3d distance equation. We also set a tolerance for error.

Section 1​

The first part of the logic is to find PosY LA. This is done by adding the travel to the Z position, leaving Y alone, and doing the 3d distance equation in reverse to get X.

The NegY LA is then solved. Travel is added to Z. Solving for X and Y are done in two loops. The outer loop solves for Y, the inner one solves for X. The loops stop when the distance to the PosY LA and the NegY LF are with the tolerance.

We then use the 3d solver to find the location of the PosY UA point. We do this iteratively finding a rotation angle around the new lower link such that the length of the PosY upper is within the error tolerance.

We then use the angle and the 3d solver to get the NegY UA. Find the distance from NegY UA to NegY UF. We then adjust the Y value of PosY LA and repeat until the distance from NegY UA to NegY UF is within tolerance.

There is a few more things here such as checking if the links cross, checking if the axle end is ahead of or behind the frame end, etc.


Section 2: The 3d solver​

This is the bulk of the math part. This part relies heavily on 3d math such as vectors, unit vectors, dot multiplication, and cross products.
To find the movement of a point on the axle, we need the point in question (P1), a reference line (L1), the post movement reference line (L2), and the rotation around the post movement line (theta). Both lines are defined by the endpoints (S for start, E for end). The point we are finding is P2

First step is to find the translation to move L2S to L1S. This is L2S - L1S. (1)
Next find 3 vectors using the end point minus the start point for:
  • From L1S to L1E (2.1)
  • From L2S to L2E (2.2)
  • From L1S to P1 (2.3)
We next find a temporary point, Pt. If L1 is parallel to L2, Pt = (2.3) as a point

In the more common case of L1 and L2 not being parallel we need to perform a rotation.
To do this we find the angle between (2.1) and (2.2) using: acos( [(2.1)dot(2.2)] / [length (2.1) * length (2.2)])

Now for the rotation. And this is where we using a quaternion, a 4x1 vector of sorts. The basic format for this in our use is:
(scaling about origin) * [cos(angle/2),sin(angle/2)*[unit vector of rotation axis]].

Now to get Q1. For our uses, the scaling is 1. We found the angle above. For the rotation to get Pt, the unit vector is the unit of the cross product or in equation form:
(2.1)X(2.2) / (length of (2.1)X(2.2))

To apply the rotation we first need to find the inverse of the quaternion (Q1^-1). This is done by doing a component multiplication of Q1 * [1, -1, -1, -1].

We also need to get P1 in the right format. This is Q2 = [0, (2.3)x, (2.3)y, (2.3)z].
The new location is the i, j, k values of the series of multiplications: Q1Q2Q1^-1.
Quaternion multiplication copied below.
QuatProduct.gif


Now we do another rotation. Pt about the unit vector of (2.2) by theta using the same process as the first rotation.
We then get P2 by translating the result of the second rotation by adding (1) and adding L1S.
 
Suggestion for link calculator:
It would be nice to see what the angles of flex are at each joint.

I tried to define this in terms of x, y and z axis, but I confused myself... What I am suggesting is seeing the maximum angle the joint is at when viewed from the side view, and when viewed from above. Possibly you could assume a ride height at 0 degrees of deflection, or give the user the ability to define the "resting" angle as it applies to each view.

This could be helpful as far as knowing what the maximum deflection your design will require of the joint, and for designing brackets for the links in knowing how much room you need to allow for (in terms of joint rotation about the bolt, not really deflection).

Thanks!
 
Last edited:
Suggestion for link calculator:
It would be nice to see what the angles of flex are at each joint.

I tried to define this in terms of x, y and z axis, but I confused myself... What I am suggesting is seeing the maximum angle the joint is at when viewed from the side view, and when viewed from above. Possibly you could assume a ride height at 0 degrees of deflection, or give the user the ability to define the "resting" angle as it applies to each view.

This could be helpful as far as knowing what the maximum deflection your design will require of the joint, and for designing brackets for the links in knowing how much room you need to allow for.

Thanks!
Do you mean the link ends?
 
Top Back Refresh