Intelligent Sketches: Mohr's Circle
As an example of what can be done intelligently with sketches, link values and equations consider graphically calculating a Mohr's circle. You can use dimensions on a sketch to dynamically calculate the resultant stresses. You can also drive the rotation of the element dynamically to create an animation of how the stresses change with that rotation.
Some background first.
Plane Stress
Consider a flat body that is being pulled in two directions. The part is in condition of plane stress; there are no stresses created across the part.
Element Stresses
If you cut the part and consider an tiny element (shown huge magnified) at the cut surface you can determine that the element experiences normal stresses in two directions.
Alternate Element Stresses
If you cut the part at an angle and consider another tiny element at the cut surface you can also determine the element stresses. Because we've cut the body at an angle, the element is now also experiencing shear stresses. The normal stresses are changed.
Now to evaluate the different stresses experienced in different orientations of the element, you can use cosine type equations, or you can use a Mohr's circle to do this graphically. Consider that in plane stress you basically have three stresses: normal stresses sx and sy, and a shear stress txy (example values: sx = 110, sy = 50, txy = 40).
You plot a circle that goes through point (sx, -txy) and (sy, txy). Since we have shear stresses, the element isn't positioned like in the above example.
As you rotate the element, rotate the line connecting the two points on the graph by twice that amount. You can then read off the new coordinates as (sx, -txy) and (sy, txy). In the example, a 10 degree rotation changed sx to 121 (from 110), sy to 38 (from 50), and txy to 27 (from 40).
From this graph you can tell that there are two special conditions. If you rotate the element by 26.57 degrees (i.e. 53.13 deg in the circle), you end up with 0 shear stress and maximum (130) minimum (30) normal stresses. These are called the principal stresses, these are used for the Van Mises calculations in an FEA package (like CosmosWorksXPress).
Also, if you rotate (36 deg) the other way, you can see that there is a point of maximum shear stress (the radius of the graph = 50), where both normal stresses have the same value (80).
Enough background. You can use SolidWorks to set this up, so you can read off the transformed values from your sketch.
A. Set up your Initial Sketch
Set up your initial sketch, rename the sketch "original" and rename the
relevant dimension. I'm using linked values here. Note that I am adding the
angle to principal stress (53.13 deg) as a driven dimension. (You can show the
names of your dimensions via
  Tools>Options>Settings>General [x] Show Dimension
Names).
I can use txy twice because it is a linked value.
B. Set up your Rotated Sketch
Create a new sketch in the same position called "rotated". Since the radius remains the same, project the curve onto the sketch. It is fully defined. Create a line through the center connecting two points on the perimeter. Add a driving angle between the original line and the new line. Then create driven dimensions (rename them sxprime, syprime, txyprime) to read off the numbers of the rotated line.
Now all you have to do is drive the rotation in the sketch to read off your stress levels at the rotated position.
Let's go one level further with this. You can use the stress levels to drive geometry that is, we can use the resulting stresses to plot a stress vector, by building the stress vector as an extrusion.
Create a part that consists of the element and three tubes whose length represents the magnitude of the stress level. Because you renamed your sketch and the relevant dimensions (including the driven ones), it is now easy to create an equation for the length of the extrusion, D1 of the extrusion feature "Vector:sx'":
"D1@Vector:sx'" = "sxprime@rotated"
Similarly, set up new equations for the other two vectors:
Vector:sy' -- "D1@Vector:sy'" = "syprime@rotated"
Vector:txy' -- "D1@Vector:txy'" = "txyprime@rotated"
You can even set up an annotation to display the rotation value (via Insert>Annotations>Note), referencing the element rotation (which is an equation half the circle rotation):
rotation: "D2@rotated"
It automatically displays the current rotation value.
So besides the "read off the value from the sketch" you now get a graphical representation of the magnitude of the vector. You can then animate this by driving the rotation of the element. Here is the end result as an animated GIF.
You can see that as the element rotates, the shear stresses get reduced till there are only principal stresses. You can also see that there is a point of maximum shear stress where the two principal stresses are the same. And of course, after you take the element through a 90 degree rotation, you're back where you started.
One final note: once the shear stress drops to zero, it should then become a negative stress and go in the other direction. I cannot easily build this by extruding a negative value, so this is one compromise that exists in this simple model, that should be relatively obvious since the final position (at 90 deg) should be the same as the initial position (at 0 deg).
Total Time to Build: 1-2 hrs
