Tick Talk on EsoxRepublic.com


Spline Curvature and Geartrax

Posted in GearTrax, Splines by Administrator on the May 28th, 2008

As promised, more [yawn] detail about spline curvature, involutes, and Geartrax. Part 1 of this subject is here.

As I wrote before, there are some errors in the involute spline generated by Geartrax. While the spline passes through all of the defining points, it meanders between these points, introducing minute error as it goes. This is due to the fact that the spline is only defined by its points, with no attention paid to tangency or curvature at any point.

screenshot of Geartrax sample part screenshot of Geartrax curvature comb
Screen shot of spur gear sample from Geartrax’ web site. Curvature comb of Geartrax tooth profile. (Click image to view full size)

Curvature of an involute

The curvature profile of an involute with respect to its length is asymptotic. It is infinite (zero radius) at the root and approaches (but never reaches) zero as the length increases. The formula is c=1/sqrt(s), where c is curvature and s is length from the root. For details, see 2dcurves.com.

The problem with the Geartrax “involute” is that it does not follow this curvature profile. The curvature is zero at each end. Also, there are inflecctions in the curvature comb. The curvature should always get smaller as the length from the root increases. The Geartrax spline has regions where the curvature increases with distance. the image below shows the Geartrax spline with curvature comb along with a curve showing what the idealized curvature comb should look like.

Geartrax curvature comb vs. ideal
Curvature comb of Geartrax tooth profile (purple) vs. ideal (red line)
A: Ideal curvature is infinite at root, Geartrax spline curvature abruptly reverts to zero
B: Geartrax spline curvature has region where curvature increases as distance from root increases
C: Geartrax spline curvature is zero at endpoint. Ideal curvature approaches but never reaches zero
(Click image to view full size)

Is this a problem?

Probably not. It depends on how much detail you need in your involutes. If you are cutting gear teeth right from CAD data, you are copying the errors. If you are cutting gear teeth with hobs, the error would not be carried through. For most common uses, performance will not be noticeably affected in either case.

I did have one application where this could have been an issue. I was tasked to model a very large gear for a very large press. The gear was to be wire EDM cut right from CAD geometry. The gear was large enough that CAD geometry errors could possibly be detected. Being a former submariner, I appreciate large, quiet, smooth gears.

Still, I am disappointed. Involutes are nothing new, and the mathematics behind them are clear and well-established. Geartrax’ results are a bit ham-fisted when placed next to an ideal involute’s simple elegance.

What you can learn

The big lesson is that there is more to drawing splines than connecting the dots. Many spline control problems are only made worse by adding more points. Controlling tangency and curvature at key points will go a long way toward creating a spline that suits your needs.

A Simple Way to Thank Our Vets

Posted in Uncategorized by Administrator on the May 27th, 2008

Try to live a life that shows you aspire to be worthy of the blood that was shed for you.

Synchronous Technology First Blush

Posted in UG/NX, Uncategorized by Administrator on the May 23rd, 2008

Plenty of buzz about Siemens/UGS new synchronous technology. All I can say for the moment is that it will be interesting to watch.

I love UG. It’s where I cut my 3D teeth. Later, I was baptized in fire at Apple, modelling transluscent blue shells for demanding and temperamental industrial designers. For that, UG was the right tool for the job. I also learned Pro/E there, and was a dual-user for a while. Pro/E lets you play doctor, UG lets you play god.

At that time, UG already had a lot of great tools for dealing with unfeatured data. We could (and often did) abandon the feature tree and model exclusively with these tools. UG could also already assimilate “unfeatured” data into its feature tree. For instance, raw “curves in space” could be swept or extruded, then those curves could be brought into a sketch and constrained/parameterized accordingly. Neat stuff.

I could go on. I’ve carved a nice career from SW, but UG still has a siren song.

What it is; how it works

For those who haven’t seen, here are a couple links explaining UG/NX6’s new “synchronous technology”. The video is an attention getter. The PDF white paper provides a more detailed explanation.
Propaganda video
White paper

The video does a great job of showing how synchronous technology should work. Looks slick. I would hope so. That’s what video editor folks are supposed to do. The white paper provides a reasonable explanation of what is happening. Very intriguing. Apparently, the synchronous technology evaluates the model to determine what feature edits it must do in order to change geometry in a certain way. Neat!

We can see how it works. What will prove more interesting is how it doesn’t work. Models and model trees come in all degrees of complexity. Some are complex by necessity. Some are complex due to poor training or bad hiring decisions. In either case, I’m sure it won’t take long before folks are finding the limits of this budding technology.

Bad example, before Bad example, before
What kind of model tree goes from this… …to this???

Here is a good specimen of a bad example. This is an .avi of a really extreme example of poor model tree management. Pure hack-slashery. The video is a series of screen shots as the part feature tree is rolled back and then forward. I would love to see how UG/NX6 handles something like this.

I would also like to see how UG/NX6 handles well-constructed surface modelling. I can’t imagine that synchronous techology has evolved to a point where it could handle a fully-featured model of something complex like an iMac shell or an auto interior console. I do hope it can, but I doubt it.

Your jobs are safe

The CAD users of today are not going to be instantaneously supplanted by an invading army of synchronous-using replacements I also don’t foresee a great improvement in the CAD-user populace. The aces will still be aces. The putzes will still be putzes. There will be a market shift, but there will be no mass-divestment in current parametric modelling technology.

Comparing files’ internal ID’s

Posted in Internal ID by Administrator on the May 22nd, 2008

Originally posted on the SW website API forum, forums.solidworks.com
Compare file internal ID’s

There is no way in SW API to get a document’s internal ID (”IID”). SW doesn’t make that data publicly available, apparently because it would be too convenient for programmers who need that information. Still, there is a way to divine some useful information about a file’s internal ID.

SW recognizes two files as having the same IID if
1.) they were created at the exact same second
2.) they were created by the same installation of SW

Very difficult to ascertain #2, but #1 comes easy.

To answer the question, “Do these two files have the same internal ID?”, one need only check the creation date. But, not just any creation date. There are many ways to check creation date, and most will not work for this purpose. The creation date of interest is the one generated the instant a user clicked the final “OK” when creating a new file in SW. What’s the right way? Use DSOfile.dll. The property “SummaryProperties.DateCreated” records the moment SW brought this file into being. It does not change when a SW file is moved, renamed, or copied. It is the “mitochondrial DNA” date stamp, passed down intact through generations of saves, moves, and copies.

What’s the wrong way? Nearly any other creation date property or method. SW’s custom property “SW-Created Date” can change due to a Save As operation. Windows API methods creation dates can change depending on how and where a file is moved or copied.

How reliable is the DSOfile create date for determining if two files share an IID? The inverse of the probability that two files of interest were created by two separate people at the exact same second. Good enough.

Things API teaches about SW

Posted in API, Internal ID by Administrator on the May 21st, 2008

Part 1 of ?

One of the things I like about learning the API of SW is that it gives great insight into what is going on deep inside SW. The insight is not limited to just the SW application, either. I believe that the API also reveals some of the goings-on at the SW development offices.

Internal confusion about Internal ID

It’s a subject that has come up many times, in many places. API programmers working with SW drawings and assemblies need access to the internal ID (”IID”) of SW files. Without fail, they fail to find an answer. The answer I got from SW API support was in two parts:

  1. “SW API does not give access to IID information.”
  2. “You shouldn’t need it. If you needed it we would have given it to you.”

But we do need it. It comes up quite often, for many reasons. It is needed when swapping references. It is needed when attempting to repair lost references. It is needed when (re)organizing a non-PDM-using company’s SW file pile.

Access to IID data is a basic (if not primal) requirement for managing references. Yet, SW has done nothing to open it up to public API users. SW won’t even acknowledge its importance. Version after version is released without any tools for even comparing file IID’s. This clearly is a case where SW is 180° out of phase with the want and needs of the API user.

A partial solution exists

Recently, I posted a partial solution to the IID problem in forum.solidworks.com. Once I track it down, I will repost it here. There is a method to retrieve creation date information of a file which provides a means of reliably comparing SW file IID’s.

Coming soon

  1. A solution for comparing file IID’s
  2. Lost in lofts at SW

Spline endpoints zero curvature on creation

Posted in GearTrax, Splines by Administrator on the May 20th, 2008

There’s a yawner of a title for ya! Probably of little interest to most. I would wager that there are more who should be interested, if they knew what was good for them. Especially GearTrax users.

Curvature of a spline is the inverse of the radius of the spline at a given point. A curvature of zero equals infinite radius = straight. Certain geometry is sensitive to curvature. Curvature continuity is important for airfoils and cams. Involute curves used to define gear teeth are also curvature-sensitive.

Curvature of SolidWorks Splines

One tool for evaluating the curvature of a spline is the curvature comb. The curvature comb shows a relative indication of a spline’s curvature. Where the comb’s “teeth” are long, the curvature is high. The comb tooth length decreases as curvature approaches zero. Inflection points are indicated where the comb switches sides.

An important phenomenon of SolidWorks splines is that they have zero curvature at their endpoints when they are initially created. The curvature will stay zero until the spline endpoints are altered somehow. Spline endpoints could be altered by moving, trimming, adding constrains, or manipulating control handles.

spline with curvature comb
Spline with curvature comb. When open splines are first drawn in SolidWorks, they have zero curvature at their endpoints.

Involutes and Curvature

One case where curvature is important is when drawing an involute. An involute is the curve needed for gear teeth. It is graphically derived by unwrapping a string from a circle. There is also a mathematical formula.

One common method of drawing an involute is to draw a spline through a series of points, derived either mathematically or graphically. However, if one were to simply draw a spline through a set of points and walk away without further editing, that spline would have noticeable error. The endpoints of the spline would be straight (zero curvature).

At no point in an involute is there zero curvature! In fact, an involute has infinite curvature at its root. Forcing a spline to zero curvature at the involute root would immediately introduce error to the rest of the spline as it interpolates its path between defining point. The spline would wander inside and outside of the ideal involute path as it attempts to meet all of the defining points after starting with zero curvature. Additional error is also introduced by the zero-curvature end condition.

…and GearTrax

After all these years, I finally took a look at GearTrax. This after seeing a post about gear design and having a moment of idleness and curiosity.

Of course, I downloaded some samples. I set about inspect the gear profile curvature. I was curious to see how the models were constructed, and what the involute looked like. I honestly expected that GearTrax would have dealt with this issue somehow. However…

to be continued…

Delusions of Relevance?

Posted in Uncategorized by Administrator on the May 16th, 2008

This T-shirt says it all.
Finally starting a blog. That makes it officially uncool, even by geek standards.

Why bother? Dunno. Feel like it. I’ve learned to enjoy writing. A few deranged souls have even learned to extract a modicum of entertainment value from my writing. God bless them all.

I can’t promise anything special. I do hope to get some good API development discussions going. Of course, I will deviate from the technical into the musical, recreational, political and spiritual. I have some projects in the works (always in the works! finish when?). Topics in the near future:
“Nearly Free Nearly PDM”: designing a cheap system for those in need
Back to basics: occasional articles about geometry basics
Non-traditional fly fishing: rivers in my Sheboygan County neighborhood abound with smallmouth bass, northern pike and carp that are quite willing to entertain a fly fisherman who has lost his patience with trout
Kayaking
Music: been married to the same guitar for 21 years now