HI
Once you have seen squicles you can not unsee then, It is much easier
on the eyes, it is not a sudden change in curvature like rounded
corners on a square. So I put together a simple module that makes a
squicle in openscad.
Squircle
https://gist.github.com/bmsleight/6946455ea1c5ec3891b8c438fd68c6e9
Example, r and center are optional:-
squircle([40,30,10], r=10, center=false);
https://i.imgur.com/hz62r3Q.png
Hope this helps someone as I could not find an openscad Squircle
example searching the web.
BMS
While the superellipse can be a pleasing form, I think that it's hard to
generalize that to corners other than 90 degrees, and given the global
nature of the function, not obvious how to make it work on an L-shape, say,
or if you want different amounts of curvature on different corners. Note
if you look around for "supershape" you can find multiple implementations
of this generalization of the superellipse.
I am very interested in rounding and have put a bunch of effort into
developing continuous curvature rounding as a general approach, not just
for one shape, that you might find interesting if the abrupt change in
curvature bothers you. Using a 4th order bezier you can make a continuous
curvature roundover on any corner with a fairly straight forward approach.
See the following which all support continuous curvature rounding:
https://github.com/revarbat/BOSL2/wiki/rounding.scad#function-round_corners
https://github.com/revarbat/BOSL2/wiki/rounding.scad#functionmodule-rounded_prism
https://github.com/revarbat/BOSL2/wiki/rounding.scad#functionmodule-join_prism
On Sun, Nov 6, 2022 at 8:30 AM Brendan Sleight bms@barwap.com wrote:
HI
Once you have seen squicles you can not unsee then, It is much easier
on the eyes, it is not a sudden change in curvature like rounded
corners on a square. So I put together a simple module that makes a
squicle in openscad.
Squircle
https://gist.github.com/bmsleight/6946455ea1c5ec3891b8c438fd68c6e9
Example, r and center are optional:-
squircle([40,30,10], r=10, center=false);
https://i.imgur.com/hz62r3Q.png
Hope this helps someone as I could not find an openscad Squircle
example searching the web.
BMS
OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org
I tried numerically computing the curvature of the superellipse and to my
surprise, it seems to approach zero at the sides, unlike the circle, which
has constant curvature. I didn't go to the trouble of computing the actual
exact curvature so I don't know if it's really zero, but by an exponent of
3 it's numerically zero, close enough for good joins if you wanted to use
1/4 of the curve curve for roundovers of 90 deg corners. You're still in
trouble, I think. if you have corners with other angles.
On Sun, Nov 6, 2022 at 8:48 AM Adrian Mariano avm4@cornell.edu wrote:
While the superellipse can be a pleasing form, I think that it's hard to
generalize that to corners other than 90 degrees, and given the global
nature of the function, not obvious how to make it work on an L-shape, say,
or if you want different amounts of curvature on different corners. Note
if you look around for "supershape" you can find multiple implementations
of this generalization of the superellipse.
I am very interested in rounding and have put a bunch of effort into
developing continuous curvature rounding as a general approach, not just
for one shape, that you might find interesting if the abrupt change in
curvature bothers you. Using a 4th order bezier you can make a continuous
curvature roundover on any corner with a fairly straight forward approach.
See the following which all support continuous curvature rounding:
https://github.com/revarbat/BOSL2/wiki/rounding.scad#function-round_corners
https://github.com/revarbat/BOSL2/wiki/rounding.scad#functionmodule-rounded_prism
https://github.com/revarbat/BOSL2/wiki/rounding.scad#functionmodule-join_prism
On Sun, Nov 6, 2022 at 8:30 AM Brendan Sleight bms@barwap.com wrote:
HI
Once you have seen squicles you can not unsee then, It is much easier
on the eyes, it is not a sudden change in curvature like rounded
corners on a square. So I put together a simple module that makes a
squicle in openscad.
Squircle
https://gist.github.com/bmsleight/6946455ea1c5ec3891b8c438fd68c6e9
Example, r and center are optional:-
squircle([40,30,10], r=10, center=false);
https://i.imgur.com/hz62r3Q.png
Hope this helps someone as I could not find an openscad Squircle
example searching the web.
BMS
OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org
That would not be a surprise if superellipses, as I suppose, have
continuous curvature.
Em dom., 6 de nov. de 2022 16:34, Adrian Mariano avm4@cornell.edu
escreveu:
I tried numerically computing the curvature of the superellipse and to my
surprise, it seems to approach zero at the sides, unlike the circle, which
has constant curvature. I didn't go to the trouble of computing the actual
exact curvature so I don't know if it's really zero, but by an exponent of
3 it's numerically zero, close enough for good joins if you wanted to use
1/4 of the curve curve for roundovers of 90 deg corners. You're still in
trouble, I think. if you have corners with other angles.
On Sun, Nov 6, 2022 at 8:48 AM Adrian Mariano avm4@cornell.edu wrote:
While the superellipse can be a pleasing form, I think that it's hard to
generalize that to corners other than 90 degrees, and given the global
nature of the function, not obvious how to make it work on an L-shape, say,
or if you want different amounts of curvature on different corners. Note
if you look around for "supershape" you can find multiple implementations
of this generalization of the superellipse.
I am very interested in rounding and have put a bunch of effort into
developing continuous curvature rounding as a general approach, not just
for one shape, that you might find interesting if the abrupt change in
curvature bothers you. Using a 4th order bezier you can make a continuous
curvature roundover on any corner with a fairly straight forward approach.
See the following which all support continuous curvature rounding:
https://github.com/revarbat/BOSL2/wiki/rounding.scad#function-round_corners
https://github.com/revarbat/BOSL2/wiki/rounding.scad#functionmodule-rounded_prism
https://github.com/revarbat/BOSL2/wiki/rounding.scad#functionmodule-join_prism
On Sun, Nov 6, 2022 at 8:30 AM Brendan Sleight bms@barwap.com wrote:
HI
Once you have seen squicles you can not unsee then, It is much easier
on the eyes, it is not a sudden change in curvature like rounded
corners on a square. So I put together a simple module that makes a
squicle in openscad.
Squircle
https://gist.github.com/bmsleight/6946455ea1c5ec3891b8c438fd68c6e9
Example, r and center are optional:-
squircle([40,30,10], r=10, center=false);
https://i.imgur.com/hz62r3Q.png
Hope this helps someone as I could not find an openscad Squircle
example searching the web.
BMS
OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org
OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org
The family of superellipses includes the circle. Yes, they have continuous
curvature, but we know that the circle has constant nonzero curvature, so
you cannot mate it to a rectangle's flat edge and maintain continuous
curvature. I assume this is the original poster's complaint about how
rounding is often done. It is not obvious to me that the curvature of
higher order superellipses will be close to zero at the sides, though I
suppose the limit (a square) will clearly have zero curvature there.
If considering a unit circle, with exponent n=2 the curvature is of course
On Sun, Nov 6, 2022 at 2:56 PM Ronaldo Persiano rcmpersiano@gmail.com
wrote:
That would not be a surprise if superellipses, as I suppose, have
continuous curvature.
Em dom., 6 de nov. de 2022 16:34, Adrian Mariano avm4@cornell.edu
escreveu:
I tried numerically computing the curvature of the superellipse and to my
surprise, it seems to approach zero at the sides, unlike the circle, which
has constant curvature. I didn't go to the trouble of computing the actual
exact curvature so I don't know if it's really zero, but by an exponent of
3 it's numerically zero, close enough for good joins if you wanted to use
1/4 of the curve curve for roundovers of 90 deg corners. You're still in
trouble, I think. if you have corners with other angles.
On Sun, Nov 6, 2022 at 8:48 AM Adrian Mariano avm4@cornell.edu wrote:
While the superellipse can be a pleasing form, I think that it's hard to
generalize that to corners other than 90 degrees, and given the global
nature of the function, not obvious how to make it work on an L-shape, say,
or if you want different amounts of curvature on different corners. Note
if you look around for "supershape" you can find multiple implementations
of this generalization of the superellipse.
I am very interested in rounding and have put a bunch of effort into
developing continuous curvature rounding as a general approach, not just
for one shape, that you might find interesting if the abrupt change in
curvature bothers you. Using a 4th order bezier you can make a continuous
curvature roundover on any corner with a fairly straight forward approach.
See the following which all support continuous curvature rounding:
https://github.com/revarbat/BOSL2/wiki/rounding.scad#function-round_corners
https://github.com/revarbat/BOSL2/wiki/rounding.scad#functionmodule-rounded_prism
https://github.com/revarbat/BOSL2/wiki/rounding.scad#functionmodule-join_prism
On Sun, Nov 6, 2022 at 8:30 AM Brendan Sleight bms@barwap.com wrote:
HI
Once you have seen squicles you can not unsee then, It is much easier
on the eyes, it is not a sudden change in curvature like rounded
corners on a square. So I put together a simple module that makes a
squicle in openscad.
Squircle
https://gist.github.com/bmsleight/6946455ea1c5ec3891b8c438fd68c6e9
Example, r and center are optional:-
squircle([40,30,10], r=10, center=false);
https://i.imgur.com/hz62r3Q.png
Hope this helps someone as I could not find an openscad Squircle
example searching the web.
BMS
OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org
OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org
OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org
Em dom., 6 de nov. de 2022 às 17:09, Adrian Mariano avm4@cornell.edu
escreveu:
The family of superellipses includes the circle. Yes, they have
continuous curvature, but we know that the circle has constant nonzero
curvature, so you cannot mate it to a rectangle's flat edge and maintain
continuous curvature. I assume this is the original poster's complaint
about how rounding is often done. It is not obvious to me that the
curvature of higher order superellipses will be close to zero at the sides,
though I suppose the limit (a square) will clearly have zero curvature
there.
If considering a unit circle, with exponent n=2 the curvature is of course
After some struggle, I guess I have found the correct expression for the
curvature of a superellipse at a side. And the result is very surprising
because the curvature is 0 for any superellipse with an exponent greater
than 2. If my deduction is correct (see the attached file) superellipses
(with n>2) may be used for smooth (curvature continuous) rounding corners.
For 90 degree corners, the application is trivial. For corners with an
angle not zero nor 180 degree, it is always possible to affine transform
(by sheer transforms) a quarter of a superellipse so the arc be tangent to
the corner sides.
Anyway, I think the parametric smooth rounding with Bezier arcs of degree 4
(order 5) is a better approach because it allows an easy and efficient
generation of points of the curve which is not so simple with algebraic
curves.
I am having some difficulty in understanding your approach at computing the
curvature. Another thing: when I numerically estimate the curvature I get
a nonzero value for 2<=n<=3. Of course, this could be misleading, but I
get values that are far from zero, and no reason to think numerical
estimation would fail so badly.
On Fri, Nov 11, 2022 at 5:33 PM Ronaldo Persiano rcmpersiano@gmail.com
wrote:
Em dom., 6 de nov. de 2022 às 17:09, Adrian Mariano avm4@cornell.edu
escreveu:
The family of superellipses includes the circle. Yes, they have
continuous curvature, but we know that the circle has constant nonzero
curvature, so you cannot mate it to a rectangle's flat edge and maintain
continuous curvature. I assume this is the original poster's complaint
about how rounding is often done. It is not obvious to me that the
curvature of higher order superellipses will be close to zero at the sides,
though I suppose the limit (a square) will clearly have zero curvature
there.
If considering a unit circle, with exponent n=2 the curvature is of
course 1. If n=2.1 my computed value is 0.43. If n=2.2 I get 0.18, and if
n=2.5 I get a curvature of 0.012. It goes to zero very quickly as n
rises. At n=4 as proposed by the original poster, I get a curvature of
2e-8, which maybe is zero curvature, i don't know. (My guess is that
probably the curvature is small but positive and approaches zero in the
limit as n->infinity.)
After some struggle, I guess I have found the correct expression for the
curvature of a superellipse at a side. And the result is very surprising
because the curvature is 0 for any superellipse with an exponent greater
than 2. If my deduction is correct (see the attached file) superellipses
(with n>2) may be used for smooth (curvature continuous) rounding corners.
For 90 degree corners, the application is trivial. For corners with an
angle not zero nor 180 degree, it is always possible to affine transform
(by sheer transforms) a quarter of a superellipse so the arc be tangent to
the corner sides.
Anyway, I think the parametric smooth rounding with Bezier arcs of degree
4 (order 5) is a better approach because it allows an easy and efficient
generation of points of the curve which is not so simple with algebraic
curves.
OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org
On Sun, Nov 6, 2022 at 7:49 AM Adrian Mariano avm4@cornell.edu wrote:
While the superellipse can be a pleasing form, I think that it's hard to
generalize that to corners other than 90 degrees,
...
I took this as a challenge to find a "regular polygon"-ircle based on the
super ellipse. I dub this shape the "polygircle".
https://gist.github.com/thehans/1791e1b8c6b40cc9841544e1a255c170
"Trircle" https://i.imgur.com/zUtuedz.png
"Pentircle" https://i.imgur.com/zG5rD1a.png
It took a bit of testing to determine some good proportions between
parameters which look nice, for numbers of sides != 4.
It is based on a generalized superellipse formula in polar form.
https://en.wikipedia.org/wiki/Superformula
Bonus article showing some interesting natural/botanical shapes which can
be recreated using the generalized superformula:
https://medium.com/@researchoutreach/superellipses-to-superformula-the-impact-of-gielis-transformations-aef5e07acce6
Those last two links you (Hans) include are very interesting.
The first one shows a number of 2D plots of even more interesting shapes,
and then 3D solids. Not sure how easy those solids would be to code up,
but they could be very interesting.
The last link shows the math shapes in nature.
On Sun, Nov 13, 2022 at 2:09 PM Hans L thehans@gmail.com wrote:
On Sun, Nov 6, 2022 at 7:49 AM Adrian Mariano avm4@cornell.edu wrote:
While the superellipse can be a pleasing form, I think that it's hard to
generalize that to corners other than 90 degrees,
...
I took this as a challenge to find a "regular polygon"-ircle based on the
super ellipse. I dub this shape the "polygircle".
https://gist.github.com/thehans/1791e1b8c6b40cc9841544e1a255c170
"Trircle" https://i.imgur.com/zUtuedz.png
"Pentircle" https://i.imgur.com/zG5rD1a.png
It took a bit of testing to determine some good proportions between
parameters which look nice, for numbers of sides != 4.
It is based on a generalized superellipse formula in polar form.
https://en.wikipedia.org/wiki/Superformula
Bonus article showing some interesting natural/botanical shapes which can
be recreated using the generalized superformula:
OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org
I got curious about the 3D shapes and found this page which explained the
math well, and showed many nice examples with parameters.
http://paulbourke.net/geometry/supershape/
So here's the 3D stuff in OpenSCAD
https://gist.github.com/thehans/aced1138436a33150ba5c572bc04e2e7
On Sun, Nov 13, 2022 at 3:37 PM Daniel Shriver tabbydan@gmail.com wrote:
Those last two links you (Hans) include are very interesting.
The first one shows a number of 2D plots of even more interesting shapes,
and then 3D solids. Not sure how easy those solids would be to code up,
but they could be very interesting.
The last link shows the math shapes in nature.
On Sun, Nov 13, 2022 at 2:09 PM Hans L thehans@gmail.com wrote:
On Sun, Nov 6, 2022 at 7:49 AM Adrian Mariano avm4@cornell.edu wrote:
While the superellipse can be a pleasing form, I think that it's hard to
generalize that to corners other than 90 degrees,
...
I took this as a challenge to find a "regular polygon"-ircle based on
the super ellipse. I dub this shape the "polygircle".
https://gist.github.com/thehans/1791e1b8c6b40cc9841544e1a255c170
"Trircle" https://i.imgur.com/zUtuedz.png
"Pentircle" https://i.imgur.com/zG5rD1a.png
It took a bit of testing to determine some good proportions between
parameters which look nice, for numbers of sides != 4.
It is based on a generalized superellipse formula in polar form.
https://en.wikipedia.org/wiki/Superformula
Bonus article showing some interesting natural/botanical shapes which can
be recreated using the generalized superformula:
OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org
OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org