Curvature Smooth Splines

Discussion in 'SolidWorks' started by Jerry Steiger, Apr 4, 2004.

  1. We're building SW surfaces from the ID firm's Alias surfaces. I notice that
    many of the splines from Alias are not just curvature continuous, but that
    the curvature changes smoothly. I'm having a heck of a time trying to match
    that characteristic with SW04.

    Checking the curvature combs, several of the splines look exactly like
    straight lines and radius sections joined by short splines. If I simplify
    the original spline I get smooth curvature, but it has reverse curvature
    areas where the straight and arced sections join the short splines and areas
    where the curvature is quite different from the original.

    If I try to build my own curve with straight lines, radii and splines, I
    can't seem to get the splines to smoothly transition to no curvature
    straight lines and small curvature radii. Two point splines don't match the
    original spline and the curvature is discontinous at the ends. Three points
    splines can match the spline fairly well but also have discontinuous
    curvature. With four point splines I can get close enough to continuous
    curvature, but the transition isn't smooth. Adding more points, I don't seem
    to be able to make the transition any smoother.

    I seem to get the closest by making my own single spline by placing a pair
    of points very close to the ends of the "straight" and "radii" sections and
    two or three points in the short spline sections, but I always seem to get
    wobbles in my curvature comb that I can't get rid of. Any rules of thumb on
    how to place my spline points?

    Should I worry about making the splines curvature smooth? Is this a
    characteristic that the eye even notices?

    Jerry Steiger
    Tripod Data Systems
    "take the garbage out, dear"
     
    Jerry Steiger, Apr 4, 2004
    #1
  2. Jerry,

    You're not going to be able to mimic this because SW splines or the
    tangent relation control for the continuity you are seeing from the
    Alias or even Rhino curves does not exist in SW (or we don't have access
    to it currently).

    example we're talking about?.. http://www.zxys.com/swparts/curvetest.zip

    Can the average person see this... it's subjective but yes they and you
    can see this and the machine cutting the material sees this.
    Does not having C2 or G2 or better effect adjacent boundaries and create
    problems when trying to work with other related curves and surfaces?..
    yep!!
    Is it important for ID work?.. yep!!

    The foundation of creating smooth transitions is to have C2/G2 or better
    control, SW does not have this.

    Are there rules for getting the points or comb to be smoother.. well,
    you can zoom up really close, change the wireframe quality setting or
    even the spin box value and use the ctrl key when dragging or adding
    points and control frames but it's all eyeballing from there on..
    Personally, adding a point close the the merge creates more problems and
    the turbulence your are seeing.
    So, yeah, you can tweak and fudge as you are doing now... but, as it is
    now with SW, you will not be able to attain what Alias or Rhino have....

    What are your alternatives.. 3rd party tools like, GW3D or
    SurfaceWorks...

    SW curve continuity control really has and does suck, period.

    Otherwise, put in a ER for adding D-Cubes 2D/3D continuity controls
    since SW Corp can't seem to do it themselves.

    ...
     
    Paul Salvador, Apr 4, 2004
    #2
  3. Jerry Steiger

    matt Guest

    Jerry:

    Paul's basically right about the current spline tangency and continuity
    functions in SW. I've bombarded SW with examples of where even the
    limited functions that do exist don't work or don't work correctly.

    There may be something else you can try, though. Have you given the
    "fit spline" any thought? Instead of drawing line spline arc and not
    getting the results you're looking for, maybe you could just draw line
    arc and make a fit spline.

    Sometimes a fit spline will waver a bit where there are big changes in
    curvature, so the spline kind of overcompensates to one side and then
    comes back where it belongs. You may be able to control this by playing
    with the tolerance value or by deleting / adding / moving control points
    near the change similar to what you have been doing. The smaller the
    radius you're trying to fit, the tighter the tolerance you'll need to
    use.

    Also, have you tried a Face Fillet with the "curvature continuous"
    switch turned on? It basically uses a spline based fillet instead of an
    arc based fillet. You still specify a radius value which turns out to
    be kind of an approximation, equivalent or average. If you create a
    fillet like this and convert entities on the edge created, and turn on
    the curvature comb, you may see little fluctuations in that too. I
    think the real problem is more likely to be that the display for the
    comb is fairly inaccurate, although I really can't cite any evidence.

    I think the best way around this at the moment is to avoid the tangency
    issue altogether by making it all a single continuous spline. The
    curvature within the spline should change smoothly. I'd recommend not
    including sharp corners in the fit spline inless you want them rounded.

    good luck

    matt
     
    matt, Apr 5, 2004
    #3
  4. Which is probably why the original designer worked in Alias. If he had the
    tools available in SW, he might have been working with it, and look how easy
    my job would be! And SW would have sold a few more seats.
    Thanks for the example. The curves I am working with are even worse in a
    sense. Your curves are curvature continuous. Mine are even "smoother"; the
    transitions in the curvature are also smooth. (For the mathematically
    inclined, the first derivative of the curvature, or the second derivative of
    the spline, is also continuous.)
    It's the "better" part that I was particularly concerned. Is it good enough
    to get my curves C2, or at least very close to C2? I've never seen any
    discussions about C3, which is what I am talking about, assuming that C1 is
    continuous curves and C2 is continuous curvature of the curves.
    I was kind of afraid that was the answer.
    Yeah, I've been learning that. The hardest part seems to be transitioning to
    a straight line.
    I need to make more ERs. It's so much easier and fun to complain to this
    group.

    Thanks for the help!

    Jerry Steiger
    Tripod Data Systems
    "take the garbage out, dear"
    "
     
    Jerry Steiger, Apr 5, 2004
    #4
  5. Whoops! Fit Spline was actually the first thing I tried. I wrote and
    re-wrote the note several times as I tried out various ideas. At some point
    I guess I dropped all of the comments about Fit Spline.
    This was the problem I ran into. The curvature would go negative at the
    transitions between the sharp and shallow curvatures. It seemed to be more
    painful to try and get the Fit Spline tweaked than it was to just generate
    my own. Plus the "roughest" Fit Spline that came closoe enough to the
    original still had a lot more points than my version.
    The particular curves I am working with now define the outline of a window
    in the part. I did use the Face Fillet with the Curvature Continuous option
    to generate the frame around the window. Seems to give me a pretty good
    match to what Alias made.
    That's what seems to be working out best.

    Thanks, Matt!

    Jerry Steiger
    Tripod Data Systems
    "take the garbage out, dear"
     
    Jerry Steiger, Apr 5, 2004
    #5
  6. Jerry,

    Understand. It's very good C2/G2 and better or C3/G3 and beyond.
    Yeah, we don't have C3.

    Good enough depends on the what the client is after or what is expected
    from the consumer?
    It may be good enough for most cases or where polishing and texturing
    will help hide the imperfections.
    Otherwise, it depends on the exposure of the transitions/blends?

    So, depending on the transition/blend, I say good in the sense that SW
    C2 is good if the user is careful as you are trying to be with noting
    the curvature comb and distortions at/near the tangency.
    The other modeling systems generally have very good C2 and can be
    generally considered good enough as they are.

    As for discussions on C3... well, maybe C2 should work very good first?
    Otherwise, yeah, it would be great to have options which force a C3!!
    Then, we can bitch at a different level!? 8^)
    Yep, close one eye and use thumb and stick tongue out and bite really
    hard!
    Well, the more we get the better chance it will be implemented??
    More competition.... we need more competition.... and of course, fewer
    gear heads! 8^)

    ...
     
    Paul Salvador, Apr 5, 2004
    #6
  7. I don't think so. I can make a spline with an arbitrary number of inflection
    points. Seems like a cubic could only have one. Or does "cubic" mean
    something different in CAD/CAM land than it does in high school math?
    I didn't come up with a way to use this method that helped in my particular
    case, but you can make an extended spline with points outside the region of
    interest and trim it off to just the part you want. When you trim it,
    nothing moves and the curvature comb doesn't change.

    Thanks, Cliff.

    Jerry Steiger
    Tripod Data Systems
    "take the garbage out, dear"
     
    Jerry Steiger, Apr 6, 2004
    #7
  8. I tried extruding a surface from a 6 point spline that would require two
    cubics, then exporting to IGES. I thought it might show up as two faces when
    it came back in from IGES, but it showed up as a single face. Reading the
    IGES report, it said that there were two composite curves and two lines.
    This seemed to imply that the the spline was really a composite. It also
    said that there were 6 B-spline curves in the part, as if the spline were
    formed from 3 sections. But when I tried simpler two and three point
    splines, they all reported exactly the same.


    Jerry Steiger
    Tripod Data Systems
    "take the garbage out, dear"
     
    Jerry Steiger, Apr 7, 2004
    #8
  9. Any rules of thumb on
    Nothing new, but here's a few that help me-

    - use as few spline points as possible. Fewer points=smoother spline. Keep
    testing to see which ones you can delete
    - use that start and end tangency on the spline (which I know you are doing
    anyway, but always good to remember. If the end of a spline has nothing to
    be tangent to, add a centerline to it)
    - make very, very small tweaks to get that final smoothing. Turn your spin
    box to .001" and use the spin box in the property manager for the really
    delicate spline point maneuvers
    - Before risking your spline to a potentially damaging edit, close out of
    the sketch, copy the sketch, and paste the copy on the same plane. Then
    drag the copy up the tree, above the original sketch, so you have it as a
    reference for the tweaks. Also, if things go south, you can refer to the
    copy to get the spline back to where it is supposed to be. For the new
    folks, remember - once you close out of a sketch, you lose any ability to
    undo what you just did. I like to save copies of the sketches as a revision
    history within the model instead of saving dozens of rev files which can be
    very hard to compare. Also, other things being equal, sketches on planes
    are preferred to sketches on faces because if you copy and paste to a face I
    don't know of any reliable way to repeatedly get the copy to land aligned
    with the original. Sketches copied from a plane and pasted on that plane
    line up automatically.
    -Turn on your inflection points
    -a couple of tightly spaced points can make radical things possible, but
    your requirement to be extremely precise goes up. If you can do the final
    tweaking with the mouse on the screen, I admire you - even holding down the
    CTRL key to disable inferencing and working in a split view with one showing
    the whole spline and the active view zoomed in really tight, I have trouble
    getting control on the screen that rivals spin boxes.
     
    Edward T Eaton, Apr 8, 2004
    #9
  10. Thanks for the good tips, Ed. I've been doing it the way you suggest, except
    that I'm not very good about saving copies of my sketches. (Hey, it's more
    exciting without a net!)

    Yesterday's revelation was that two point splines somehow know that they
    were two point splines, even after you insert spline points in them. If you
    insert spline points into a three or more point spline, the points slide
    along the curve nicely. If you insert spline points into a two point spline,
    the points drag the curve along with them as they move, stretching it taut
    behind them and bunching it up in front of them. It doesn't matter whether
    you insert the new points one at a time or all at once. It doesn't matter
    whether the spline started life as a two point spline or was reduced to a
    two point spline by removing spline points.

    The work arounds I've come up with are to either delete the
    "used-to-be-a-two-point" spline and replace it with a three or more point
    spline or delete the points and replace them with points closer to where you
    expect them to go.

    So, two point splines are very nice where you can use them, but beware of
    their history if you really need a spline with more points!

    Jerry Steiger
    Tripod Data Systems
    "take the garbage out, dear"
     
    Jerry Steiger, Apr 8, 2004
    #10
  11. Whats kind of fun to know is that a 'two point spline' isn't a 'two point
    spline'. To get their behavior, SWx adds a hidden point near each end of
    the spline that we cannot access, edit or remove. You can manipulate the
    hidden point from the user end by making the two point spline tangent to
    something or, as you said, start with a three point spline which is at least
    one point less than a two point spline really is (unless you add tangnecy,
    which gives you a five point spline).
     
    Edward T Eaton, Apr 8, 2004
    #11
  12. Thanks, Ed, it's good to know these little details. It still doesn't explain
    the stretching and bunching behavior when moving points that are added to an
    initially two point spline.

    Jerry Steiger
    Tripod Data Systems
    "take the garbage out, dear"
     
    Jerry Steiger, Apr 9, 2004
    #12
  13. Deleting a simple explanation of some of the spline math
    That's my problem with SW splines. In order to make the user interface
    simpler, SW hides almost everything behind the curtain, crippling my ability
    to get the job done.


    Jerry Steiger
    Tripod Data Systems
    "take the garbage out, dear"
     
    Jerry Steiger, Apr 9, 2004
    #13
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.