How hard is it to do a just slighty eccentric circle in openscad?

classic Classic list List threaded Threaded
27 messages Options
12
Reply | Threaded
Open this post in threaded view
|

How hard is it to do a just slighty eccentric circle in openscad?

Gene Heskett
Greetings all;

I have another of my wild hair ideas, and want to make a bearing seat
that will hold a 4" diameter plastic bearing nominally 9/32" out of
round. IOW, how do I nake a true, mathematically accurate eccentric in
openscad?

Thanks everybody.

Cheers, Gene Heskett
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis
Genes Web page <http://geneslinuxbox.net:6309/gene>
_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

OpenSCAD mailing list-2
Can you give a bit more detail?

What hapens when you use scaling?


Do you have any code to show?


On 2021-04-27 9:50 p.m., Gene Heskett wrote:
Greetings all;

I have another of my wild hair ideas, and want to make a bearing seat 
that will hold a 4" diameter plastic bearing nominally 9/32" out of 
round. IOW, how do I nake a true, mathematically accurate eccentric in 
openscad?

Thanks everybody.

Cheers, Gene Heskett

-- 
Ron Wheeler
Artifact Software
438-345-3369
[hidden email]

_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

nophead
I don't know what you mean by a "true, mathematically accurate eccentric". An eccentric circle simply means off centre, so you can just translate it relative to the axis of rotation.

If you mean an ellipse then that is mathematically the same as a circle scaled on one axis. E.g.

module ellipse(xr, yr) scale([1, yr / xr]) circle(xr); 



On Wed, 28 Apr 2021 at 03:46, Ron Wheeler via Discuss <[hidden email]> wrote:



---------- Forwarded message ----------
From: Ron Wheeler <[hidden email]>
To: [hidden email]
Cc: 
Bcc: 
Date: Tue, 27 Apr 2021 22:40:09 -0400
Subject: [OpenSCAD] Re: How hard is it to do a just slighty eccentric circle in openscad?
Can you give a bit more detail?

What hapens when you use scaling?


Do you have any code to show?


On 2021-04-27 9:50 p.m., Gene Heskett wrote:
Greetings all;

I have another of my wild hair ideas, and want to make a bearing seat 
that will hold a 4" diameter plastic bearing nominally 9/32" out of 
round. IOW, how do I nake a true, mathematically accurate eccentric in 
openscad?

Thanks everybody.

Cheers, Gene Heskett

-- 
Ron Wheeler
Artifact Software
438-345-3369
[hidden email]



---------- Forwarded message ----------
From: Ron Wheeler via Discuss <[hidden email]>
To: [hidden email]
Cc: Ron Wheeler <[hidden email]>
Bcc: 
Date: Tue, 27 Apr 2021 22:40:09 -0400
Subject: [OpenSCAD] Re: How hard is it to do a just slighty eccentric circle in openscad?
_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]

_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

mondo
In reply to this post by Gene Heskett
Hi,

If it is an eccentric you want, as used in, say, Stephenson's valve
gear, then in your example, it will have a throw of 9/16 inch.  so, make
a vertical stubby cylinder to hold your bearing (if you need to insert
the bearing) and translate it 9/32 inch in the x direction, say. The
centre that you need for the axle/whatever will be at the origin, so put
the axle there.

On 28/04/2021 02:50, Gene Heskett wrote:

> Greetings all;
>
> I have another of my wild hair ideas, and want to make a bearing seat
> that will hold a 4" diameter plastic bearing nominally 9/32" out of
> round. IOW, how do I nake a true, mathematically accurate eccentric in
> openscad?
>
> Thanks everybody.
>
> Cheers, Gene Heskett
_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

Gene Heskett
In reply to this post by nophead
On Wednesday 28 April 2021 03:10:06 nop head wrote:

> I don't know what you mean by a "true, mathematically accurate
> eccentric". An eccentric circle simply means off centre, so you can
> just translate it relative to the axis of rotation.

I'm not Ron Wheeler, and I show no msg from him that you are replying to.
Is this list coupled?

> If you mean an ellipse then that is mathematically the same as a
> circle scaled on one axis. E.g.
>
> module ellipse(xr, yr) scale([1, yr / xr]) circle(xr);

That looks as if it should do it except that will make a single lobe (I
think but what do I know, my algebra teacher was far more interested in
getting the girls to the wet panties stage with his off color jokes than
in teaching the class algrebra, one of the reasons I quit school in the
middle of my freshman year and went to work fixing tv's for a living
in '48, ending up switching to broadcasting in '62, with a sign on my
saying Chief Engineer for most of the last 30 years of my working life.
I am also a C.E.T.) it needs to be like the usual woodworkers ellipse
layout tool, consisting of 2 pins and a string loop to fix the reach,
the string is dropped over the two pins, and a pencil is then used to
make the outline mark by using the string as a "thats as far as I can
reach" and stay inside the string. I want to do that in openscad so it
can be scaled and printed on a 3d printer. In this particular case an
Ender 5 Plus. At about 100mm in diameter, so the ellipse will have two
lobes. With about a 6 to 7mm total diff between x and y.

A hint about $fn here, I could see and feel in the movements, the facets
of the circle at an $fn=360, so I stepped it up to $fn=1440, which then
made a 50 meg stl it takes cura several minutes to process. But the
result is noticably smoother motion.

Thinking about that, and realizing as I watch the printer move, that I do
not have the electrical cableing routed correctly which is putting an
extra bind on the bowden tube, but the assembled printer is too heavy
for my back to move around easily, it occurs to me that while I am
printing bearings, I may as well do one as big as the Ender 5 Plus's
glass, 13" plus, and use it for a Lazy Suzan bearing in a 30" diameter
table top, with a quad of casters at the top of the 24" legs to serve as
weight bearing helpers for the lazy suzan bearing.  So thats on the
agenda too, but with bb's for bearings in such a beast, I'll have to get
another jar of them. Since I have another large but bed slinger printer
awaiting parts to repair its burned up controller board, I may as well
make 2 tables since the computer has more usb ports, it may as well
drive both printers. It will take this printer several hours to build a
L.S. bearing that big, but it will still be way cheaper than buying a
stamped steel one that big. Humm, with the casters bearing the weight, I
can use a broom handle dowel pin in the center for the locator pivot.
Even cheaper.

But the need for the ellipse continues. I'm making the bearings circular,
then insert the ellipse made on a mill from alu, to make it
non-circular. I have one made, but with the bearing groove too small, so
its a bit tight when filled with bb's and I can stretch it plenty far
enough to do this with only a couple ounces pull with my thumbs.

It also crosses my mind to go back to the external facing spline gear,
make its ID about 2mm smaller and inlay in that 2mm a pair of bearing
grooves effectively making it the bearings external race and removing
any possibility of slippage wear at that point.

As you can see, my mind, whats left of it, thinks better while typeing.

Thanks everybody.

>
> On Wed, 28 Apr 2021 at 03:46, Ron Wheeler via Discuss <
>
> [hidden email]> wrote:
> > ---------- Forwarded message ----------
> > From: Ron Wheeler <[hidden email]>
> > To: [hidden email]
> > Cc:
> > Bcc:
> > Date: Tue, 27 Apr 2021 22:40:09 -0400
> > Subject: [OpenSCAD] Re: How hard is it to do a just slighty
> > eccentric circle in openscad?
> > Can you give a bit more detail?
> >
> > What hapens when you use scaling?
> >
> > Do you have any code to show?
Fugly stuff but attached. Comments welcome.

> > On 2021-04-27 9:50 p.m., Gene Heskett wrote:
> >
> > Greetings all;
> >
> > I have another of my wild hair ideas, and want to make a bearing
> > seat that will hold a 4" diameter plastic bearing nominally 9/32"
> > out of round. IOW, how do I nake a true, mathematically accurate
> > eccentric in openscad?
> >
> > Thanks everybody.
> >
> > Cheers, Gene Heskett
> >
> >
> > --
> > Ron Wheeler
> > Artifact Software
> > [hidden email]
> >
> >
> >
> >
> > ---------- Forwarded message ----------
> > From: Ron Wheeler via Discuss <[hidden email]>
> > To: [hidden email]
> > Cc: Ron Wheeler <[hidden email]>
> > Bcc:
> > Date: Tue, 27 Apr 2021 22:40:09 -0400
> > Subject: [OpenSCAD] Re: How hard is it to do a just slighty
> > eccentric circle in openscad?
> > _______________________________________________
> > OpenSCAD mailing list
> > To unsubscribe send an email to [hidden email]

Cheers, Gene Heskett
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis
Genes Web page <http://geneslinuxbox.net:6309/gene>

_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]

Big5Bearing-races.scad (1K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

milmac
In reply to this post by Gene Heskett

Gene, I’m afraid it’s still far from clear (to me, at least) what exactly you’re trying make. Ellipses don’t have “lobes”. Perhaps you could post a hand-drawn sketch of what you want to make?

Gene Heskett wrote:

…That looks as if it should do it except that will make a single lobe … so the ellipse will have two lobes



_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

jon_bondy

Gene:

Can you make the shape you want by using hull() on two circles or cylinders of different diameters spaced a bit apart?


On 4/29/2021 7:59 AM, [hidden email] wrote:

Gene, I’m afraid it’s still far from clear (to me, at least) what exactly you’re trying make. Ellipses don’t have “lobes”. Perhaps you could post a hand-drawn sketch of what you want to make?

Gene Heskett wrote:

…That looks as if it should do it except that will make a single lobe … so the ellipse will have two lobes



_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

will
It seems to me that Gene is describing an ellipse:

>it needs to be like the usual woodworkers ellipse
layout tool, consisting of 2 pins and a string loop to fix the reach,
the string is dropped over the two pins, and a pencil is then used to
make the outline mark by using the string as a "thats as far as I can
reach" and stay inside the string.


In which case the answer has already been posted by Nop Head (module ellipse(xr, yr) scale([1, yr / xr]) circle(xr); ), and any confusion about lobes or asymmetry is just that.

On Thu, 29 Apr 2021 at 13:05, jon <[hidden email]> wrote:

Gene:

Can you make the shape you want by using hull() on two circles or cylinders of different diameters spaced a bit apart?


On 4/29/2021 7:59 AM, [hidden email] wrote:

Gene, I’m afraid it’s still far from clear (to me, at least) what exactly you’re trying make. Ellipses don’t have “lobes”. Perhaps you could post a hand-drawn sketch of what you want to make?

Gene Heskett wrote:

…That looks as if it should do it except that will make a single lobe … so the ellipse will have two lobes


_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]

_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

Msquare
// 3 "eccentric"s

module disc(r) { cylinder(r=r,h=2) ; }
module rod() cylinder(h=4,r=2) ;
translate([60,0,0]) {// A circle is a circle. Can't be anything else
// if you rotate elsewhere than its centre, then it's motion is eccentric
rotate(360*$t) translate([5,0,0]) disc(20);
rod() ;
}

translate([-60,0,0]) {
// An elongated circle is mathematically the same as an ellipse
// if you rotate it about its center it has two "lobes" in Genes parlance
  translate([0,40,0]) {
  rotate(360*$t) scale([1.2,1,1]) disc(20); // ellipse 40x48
  rod() ;
  }
// you can rotate it about one of the foci, in which case it has one "lobe".
  focus = (sqrt(20*1.2*20*1.2-20*20)); // distance of focus from center
  translate([0,-40,0]) {
  rotate(360*$t) translate([focus,0,0]) scale([1.2,1,1]) disc(20);
  rod() ;
  }
}
// a "hull" round two circles (with plenty of overlap) is a traditional "cam" as in camshaft
rotate(360*$t) hull() {disc(20); translate([0,18,0]) disc(8);}
rod() ;


Best viewed as an animation, f.eks. FPS 5, steps 25
image.png


On Thu, 29 Apr 2021 at 14:29, Will Hardiman <[hidden email]> wrote:
It seems to me that Gene is describing an ellipse:

>it needs to be like the usual woodworkers ellipse
layout tool, consisting of 2 pins and a string loop to fix the reach,
the string is dropped over the two pins, and a pencil is then used to
make the outline mark by using the string as a "thats as far as I can
reach" and stay inside the string.


In which case the answer has already been posted by Nop Head (module ellipse(xr, yr) scale([1, yr / xr]) circle(xr); ), and any confusion about lobes or asymmetry is just that.

On Thu, 29 Apr 2021 at 13:05, jon <[hidden email]> wrote:

Gene:

Can you make the shape you want by using hull() on two circles or cylinders of different diameters spaced a bit apart?


On 4/29/2021 7:59 AM, [hidden email] wrote:

Gene, I’m afraid it’s still far from clear (to me, at least) what exactly you’re trying make. Ellipses don’t have “lobes”. Perhaps you could post a hand-drawn sketch of what you want to make?

Gene Heskett wrote:

…That looks as if it should do it except that will make a single lobe … so the ellipse will have two lobes


_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]

_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
+--+
| M |
+--+
Reply | Threaded
Open this post in threaded view
|

Making a curved cone?

OpenSCAD mailing list-2
Hey all.

I've been looking and maybe I missed this.

I want to make a slightly curved cone, so it's a cylinder() call, but I'd like about 15 degrees of bend in the cone over its' length. Think of a curved Marlinspike, if you've done ropework.

linear_extrude() is straight, rotate_extrude doesn't scale or I'd be set (I'd have to rotate it vertical to print, I imagine.)

I've been really enjoying the "c-ishness" of OpenSCAD, long time programmer, but by no means an artist, so I fake it in code :)

Any options other than bending the object post-print? That could be done, just looking at future projects where that'd get tougher.

Thanks!

  Mark

_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

Gene Heskett
In reply to this post by jon_bondy
On Thursday 29 April 2021 08:05:34 jon wrote:

> Gene:
>
> Can you make the shape you want by using hull() on two circles or
> cylinders of different diameters spaced a bit apart?

Close, but no cigar, Jon. See the drawings to the right of the hull
discussion in the docs.  That leaves a straight line top and bottom the
same length as the center separation in the example shown, and that is
not an elliptical curve.

Take a 4" circle made out of rubber, pin the left edge at its ID then
pull it out of round by a by stretching over another pin 3/16" larger
than the circles diameter. This will be a pretty close approximation of
what I want. This is a spline made out of triangles, running inside an
identical spline with the triangles rotated 180 degrees. The tips of the
elipse forces the splines to be fully engaged at 180 dehree intervals.
while the pullin at 90 degrees is just enough to make the splines clear
each other as the tips of the splines pass each other because there 2
more splines on the outer ring facing in, than on the inner ring facing
out.

Thanks Jon, you made me look it up to see if I miss-interpreted it.

> On 4/29/2021 7:59 AM, [hidden email] wrote:
> > Gene, I’m afraid it’s still far from clear (to me, at least) what
> > exactly you’re trying make. Ellipses don’t have “lobes”. Perhaps you
> > could post a hand-drawn sketch of what you want to make?
> >
> > Gene Heskett wrote:
> >
> >     …That looks as if it should do it except that will make a single
> >     lobe … so the ellipse will have two lobes


Cheers, Gene Heskett
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis
Genes Web page <http://geneslinuxbox.net:6309/gene>
_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: Making a curved cone?

JordanBrown
In reply to this post by OpenSCAD mailing list-2
I want to make a slightly curved cone, so it's a cylinder() call, but I'd like about 15 degrees of bend in the cone over its' length. Think of a curved Marlinspike, if you've done ropework.

There's no simple way.  You need to construct a polyhedron.

There are libraries that will help you do this, mostly with the name "sweep".  Here is one such function:

https://github.com/revarbat/BOSL2/wiki/skin.scad#functionmodule-sweep

These generally operate by having you supply a polygon that is then swept along a specified path to form a polyhedron.

Here's an example:
include <BOSL2/std.scad>

// Usual $fs, $fa, $fn control the number of sides of the circle.
$fs = 0.5;

step = 0.01;    // Steps from 0 to 1 by this increment
bend = 15;      // In degrees
height = 20;    // Before bending
r1 = 3;         // At base
r2 = 0;         // At peak

path_transforms = [
    for (t=[0:step:1-step])
        xrot(bend*t)
        * translate([0,0,height*t])
        * scale(1 + t*(r2-r1)/r1)
];
sweep(circle(r=r1), path_transforms);


_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: Making a curved cone?

cacb
In reply to this post by OpenSCAD mailing list-2
On 2021-04-29 16:50, M W via Discuss wrote:
> Any options other than bending the object post-print?
> That could be done, just looking at future projects where that'd get
> tougher.

One way is something like this
https://gist.github.com/arnholm/fadb3e6c7e38983643377569ca94d0b9

Another way is sweeping
https://gist.github.com/arnholm/87ccd342abc8b8bef712791f648b5021

Carsten Arnholm
_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

Gene Heskett
In reply to this post by will
On Thursday 29 April 2021 08:29:03 Will Hardiman wrote:

> It seems to me that Gene is describing an ellipse:
> >it needs to be like the usual woodworkers ellipse
>
> layout tool, consisting of 2 pins and a string loop to fix the reach,
> the string is dropped over the two pins, and a pencil is then used to
> make the outline mark by using the string as a "thats as far as I can
> reach" and stay inside the string.
>
> A video of this technique: https://www.youtube.com/watch?v=Et3OdzEGX_w
>
> In which case the answer has already been posted by Nop Head (module
> ellipse(xr, yr) scale([1, yr / xr]) circle(xr); ), and any confusion
> about lobes or asymmetry is just that.
>
I believe thats correct, however ellipse is not listed in the cheat
sheet, so where do I find its docs?

searching the net I found the MCAD-master.zip on gh, downloaded the zip
and unpacked as a subdir into the path openscad was looking in for its
library page. But I do not see a load library anyplace in the editors
menu's.  Can someone enlighten me how this is done for the linux
AppImage 2021.01 (git 41f58fe) ?

Thank you.

> On Thu, 29 Apr 2021 at 13:05, jon <[hidden email]> wrote:
> > Gene:
> >
> > Can you make the shape you want by using hull() on two circles or
> > cylinders of different diameters spaced a bit apart?
> >
> >
> > On 4/29/2021 7:59 AM, [hidden email] wrote:
> >
> > Gene, I’m afraid it’s still far from clear (to me, at least) what
> > exactly you’re trying make. Ellipses don’t have “lobes”. Perhaps you
> > could post a hand-drawn sketch of what you want to make?
> >
> > Gene Heskett wrote:
> >
> > …That looks as if it should do it except that will make a single
> > lobe … so the ellipse will have two lobes
> >
> > _______________________________________________
> > OpenSCAD mailing list
> > To unsubscribe send an email to [hidden email]


Cheers, Gene Heskett
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis
Genes Web page <http://geneslinuxbox.net:6309/gene>
_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

OpenSCAD mailing list-2
http://forum.openscad.org/Drawing-Ellipses-td536.html

If you google "OpenSCAD elipse" you will find a lot of references.

I think that you are making this a lot harder than it really is.

In what way is an ellipse different from a circle scaled by different amounts on each axis?

Free advice: Pay a lot of attention to nop head. I don't know him but from watching the forum, there are not many things about OpenSCAD that he does not know. If he says "try it" then you should try it.

On 2021-04-29 12:43 p.m., Gene Heskett wrote:
On Thursday 29 April 2021 08:29:03 Will Hardiman wrote:

It seems to me that Gene is describing an ellipse:
it needs to be like the usual woodworkers ellipse
layout tool, consisting of 2 pins and a string loop to fix the reach,
the string is dropped over the two pins, and a pencil is then used to
make the outline mark by using the string as a "thats as far as I can
reach" and stay inside the string.

A video of this technique: https://www.youtube.com/watch?v=Et3OdzEGX_w

In which case the answer has already been posted by Nop Head (module
ellipse(xr, yr) scale([1, yr / xr]) circle(xr); ), and any confusion
about lobes or asymmetry is just that.

I believe thats correct, however ellipse is not listed in the cheat 
sheet, so where do I find its docs?

searching the net I found the MCAD-master.zip on gh, downloaded the zip 
and unpacked as a subdir into the path openscad was looking in for its 
library page. But I do not see a load library anyplace in the editors 
menu's.  Can someone enlighten me how this is done for the linux 
AppImage 2021.01 (git 41f58fe) ?

Thank you.

On Thu, 29 Apr 2021 at 13:05, jon [hidden email] wrote:
Gene:

Can you make the shape you want by using hull() on two circles or
cylinders of different diameters spaced a bit apart?


On 4/29/2021 7:59 AM, [hidden email] wrote:

Gene, I’m afraid it’s still far from clear (to me, at least) what
exactly you’re trying make. Ellipses don’t have “lobes”. Perhaps you
could post a hand-drawn sketch of what you want to make?

Gene Heskett wrote:

…That looks as if it should do it except that will make a single
lobe … so the ellipse will have two lobes

_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]

Cheers, Gene Heskett

-- 
Ron Wheeler
Artifact Software
438-345-3369
[hidden email]

_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

Gene Heskett
In reply to this post by Msquare
On Thursday 29 April 2021 09:06:32 Michael Möller wrote:

> // 3 "eccentric"s
>
> module disc(r) { cylinder(r=r,h=2) ; }
> module rod() cylinder(h=4,r=2) ;
> translate([60,0,0]) {// A circle is a circle. Can't be anything else
> // if you rotate elsewhere than its centre, then it's motion is
> eccentric rotate(360*$t) translate([5,0,0]) disc(20);
> rod() ;
> }
>
This below is almost precisely what I wanted, thank you Michael.

> translate([-60,0,0]) {
> // An elongated circle is mathematically the same as an ellipse
> // if you rotate it about its center it has two "lobes" in Genes
> parlance translate([0,40,0]) {
>   rotate(360*$t) scale([1.2,1,1]) disc(20); // ellipse 40x48
>   rod() ;
>   }
One final question: Once the circumference has been determined, do I
subtract an equal amount from Y that I added to x to keep the
circumference unchanged as I make it into an ellipse?  Or is there some
trig needed?

IOW if I change the scale arguements to 1.03,.97,1 will the circumference
remain unchanged from the 1,1,1 condition?

Thank you. A fresh copy of the piece that will be flexed by this ellipse
is about a 4.5 hour build, about 3 hours into it now, and then I'll have
something to measure and test fit against.  This is not the same printer
so the finished sizes of the parts may easily be a major fraction of a
millimeter different. Probably requiring I adjust and rebuild. This
piece building now in particular as I made the first one on a different
printer out of translucent PETG, but this printer is loaded with black
PETG, and despite its not showing anything but a hi res cylinder for an
inner wall in openscad, the bases of the splines are seriously "printing
thru".  Something I could not see in the translucent PETG at all.  That
may predict an early failure.

> // you can rotate it about one of the foci, in which case it has one
> "lobe". focus = (sqrt(20*1.2*20*1.2-20*20)); // distance of focus from
> center translate([0,-40,0]) {
>   rotate(360*$t) translate([focus,0,0]) scale([1.2,1,1]) disc(20);
>   rod() ;
>   }
> }
> // a "hull" round two circles (with plenty of overlap) is a
> traditional "cam" as in camshaft
> rotate(360*$t) hull() {disc(20); translate([0,18,0]) disc(8);}
> rod() ;
>
> Best viewed as an animation, f.eks. FPS 5, steps 25
> [image: image.png]
>
>
> On Thu, 29 Apr 2021 at 14:29, Will Hardiman
> <[hidden email]>
>
> wrote:
> > It seems to me that Gene is describing an ellipse:
> > >it needs to be like the usual woodworkers ellipse
> >
> > layout tool, consisting of 2 pins and a string loop to fix the
> > reach, the string is dropped over the two pins, and a pencil is then
> > used to make the outline mark by using the string as a "thats as far
> > as I can reach" and stay inside the string.
> >
> > A video of this technique:
> > https://www.youtube.com/watch?v=Et3OdzEGX_w
> >
> > In which case the answer has already been posted by Nop Head (module
> > ellipse(xr, yr) scale([1, yr / xr]) circle(xr); ), and any confusion
> > about lobes or asymmetry is just that.
> >
> > On Thu, 29 Apr 2021 at 13:05, jon <[hidden email]> wrote:
> >> Gene:
> >>
> >> Can you make the shape you want by using hull() on two circles or
> >> cylinders of different diameters spaced a bit apart?
> >>
> >>
> >> On 4/29/2021 7:59 AM, [hidden email] wrote:
> >>
> >> Gene, I’m afraid it’s still far from clear (to me, at least) what
> >> exactly you’re trying make. Ellipses don’t have “lobes”. Perhaps
> >> you could post a hand-drawn sketch of what you want to make?
> >>
> >> Gene Heskett wrote:
> >>
> >> …That looks as if it should do it except that will make a single
> >> lobe … so the ellipse will have two lobes
> >>
> >> _______________________________________________
> >> OpenSCAD mailing list
> >> To unsubscribe send an email to [hidden email]
> >
> > _______________________________________________
> > OpenSCAD mailing list
> > To unsubscribe send an email to [hidden email]


Cheers, Gene Heskett
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis
Genes Web page <http://geneslinuxbox.net:6309/gene>
_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

nophead
Good luck trying to calculate the circumference of an ellipse. There is no formula. See https://www.youtube.com/watch?v=5nW3nJhBHL0

On Thu, 29 Apr 2021 at 18:58, Gene Heskett <[hidden email]> wrote:
On Thursday 29 April 2021 09:06:32 Michael Möller wrote:

> // 3 "eccentric"s
>
> module disc(r) { cylinder(r=r,h=2) ; }
> module rod() cylinder(h=4,r=2) ;
> translate([60,0,0]) {// A circle is a circle. Can't be anything else
> // if you rotate elsewhere than its centre, then it's motion is
> eccentric rotate(360*$t) translate([5,0,0]) disc(20);
> rod() ;
> }
>
This below is almost precisely what I wanted, thank you Michael.

> translate([-60,0,0]) {
> // An elongated circle is mathematically the same as an ellipse
> // if you rotate it about its center it has two "lobes" in Genes
> parlance translate([0,40,0]) {
>   rotate(360*$t) scale([1.2,1,1]) disc(20); // ellipse 40x48
>   rod() ;
>   }
One final question: Once the circumference has been determined, do I
subtract an equal amount from Y that I added to x to keep the
circumference unchanged as I make it into an ellipse?  Or is there some
trig needed?

IOW if I change the scale arguements to 1.03,.97,1 will the circumference
remain unchanged from the 1,1,1 condition?

Thank you. A fresh copy of the piece that will be flexed by this ellipse
is about a 4.5 hour build, about 3 hours into it now, and then I'll have
something to measure and test fit against.  This is not the same printer
so the finished sizes of the parts may easily be a major fraction of a
millimeter different. Probably requiring I adjust and rebuild. This
piece building now in particular as I made the first one on a different
printer out of translucent PETG, but this printer is loaded with black
PETG, and despite its not showing anything but a hi res cylinder for an
inner wall in openscad, the bases of the splines are seriously "printing
thru".  Something I could not see in the translucent PETG at all.  That
may predict an early failure.

> // you can rotate it about one of the foci, in which case it has one
> "lobe". focus = (sqrt(20*1.2*20*1.2-20*20)); // distance of focus from
> center translate([0,-40,0]) {
>   rotate(360*$t) translate([focus,0,0]) scale([1.2,1,1]) disc(20);
>   rod() ;
>   }
> }
> // a "hull" round two circles (with plenty of overlap) is a
> traditional "cam" as in camshaft
> rotate(360*$t) hull() {disc(20); translate([0,18,0]) disc(8);}
> rod() ;
>
> Best viewed as an animation, f.eks. FPS 5, steps 25
> [image: image.png]
>
>
> On Thu, 29 Apr 2021 at 14:29, Will Hardiman
> <[hidden email]>
>
> wrote:
> > It seems to me that Gene is describing an ellipse:
> > >it needs to be like the usual woodworkers ellipse
> >
> > layout tool, consisting of 2 pins and a string loop to fix the
> > reach, the string is dropped over the two pins, and a pencil is then
> > used to make the outline mark by using the string as a "thats as far
> > as I can reach" and stay inside the string.
> >
> > A video of this technique:
> > https://www.youtube.com/watch?v=Et3OdzEGX_w
> >
> > In which case the answer has already been posted by Nop Head (module
> > ellipse(xr, yr) scale([1, yr / xr]) circle(xr); ), and any confusion
> > about lobes or asymmetry is just that.
> >
> > On Thu, 29 Apr 2021 at 13:05, jon <[hidden email]> wrote:
> >> Gene:
> >>
> >> Can you make the shape you want by using hull() on two circles or
> >> cylinders of different diameters spaced a bit apart?
> >>
> >>
> >> On 4/29/2021 7:59 AM, [hidden email] wrote:
> >>
> >> Gene, I’m afraid it’s still far from clear (to me, at least) what
> >> exactly you’re trying make. Ellipses don’t have “lobes”. Perhaps
> >> you could post a hand-drawn sketch of what you want to make?
> >>
> >> Gene Heskett wrote:
> >>
> >> …That looks as if it should do it except that will make a single
> >> lobe … so the ellipse will have two lobes
> >>
> >> _______________________________________________
> >> OpenSCAD mailing list
> >> To unsubscribe send an email to [hidden email]
> >
> > _______________________________________________
> > OpenSCAD mailing list
> > To unsubscribe send an email to [hidden email]


Cheers, Gene Heskett
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis
Genes Web page <http://geneslinuxbox.net:6309/gene>
_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]

_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

Msquare
As nophead wrote : https://en.wikipedia.org/wiki/Ellipse#Circumference ... if you just want to read rather than watch. 

The article gives a relatively simple formula for an approximation, and the error bounds. It may be enough for you.

Put that into a spread sheet or something and adjust a,b until they fit your circumference requirement and eccentricity. 

On Thu, 29 Apr 2021 at 21:13, nop head <[hidden email]> wrote:
Good luck trying to calculate the circumference of an ellipse. There is no formula. See https://www.youtube.com/watch?v=5nW3nJhBHL0

On Thu, 29 Apr 2021 at 18:58, Gene Heskett <[hidden email]> wrote:
On Thursday 29 April 2021 09:06:32 Michael Möller wrote:

> // 3 "eccentric"s
>
> module disc(r) { cylinder(r=r,h=2) ; }
> module rod() cylinder(h=4,r=2) ;
> translate([60,0,0]) {// A circle is a circle. Can't be anything else
> // if you rotate elsewhere than its centre, then it's motion is
> eccentric rotate(360*$t) translate([5,0,0]) disc(20);
> rod() ;
> }
>
This below is almost precisely what I wanted, thank you Michael.

> translate([-60,0,0]) {
> // An elongated circle is mathematically the same as an ellipse
> // if you rotate it about its center it has two "lobes" in Genes
> parlance translate([0,40,0]) {
>   rotate(360*$t) scale([1.2,1,1]) disc(20); // ellipse 40x48
>   rod() ;
>   }
One final question: Once the circumference has been determined, do I
subtract an equal amount from Y that I added to x to keep the
circumference unchanged as I make it into an ellipse?  Or is there some
trig needed?

IOW if I change the scale arguements to 1.03,.97,1 will the circumference
remain unchanged from the 1,1,1 condition?

Thank you. A fresh copy of the piece that will be flexed by this ellipse
is about a 4.5 hour build, about 3 hours into it now, and then I'll have
something to measure and test fit against.  This is not the same printer
so the finished sizes of the parts may easily be a major fraction of a
millimeter different. Probably requiring I adjust and rebuild. This
piece building now in particular as I made the first one on a different
printer out of translucent PETG, but this printer is loaded with black
PETG, and despite its not showing anything but a hi res cylinder for an
inner wall in openscad, the bases of the splines are seriously "printing
thru".  Something I could not see in the translucent PETG at all.  That
may predict an early failure.

> // you can rotate it about one of the foci, in which case it has one
> "lobe". focus = (sqrt(20*1.2*20*1.2-20*20)); // distance of focus from
> center translate([0,-40,0]) {
>   rotate(360*$t) translate([focus,0,0]) scale([1.2,1,1]) disc(20);
>   rod() ;
>   }
> }
> // a "hull" round two circles (with plenty of overlap) is a
> traditional "cam" as in camshaft
> rotate(360*$t) hull() {disc(20); translate([0,18,0]) disc(8);}
> rod() ;
>
> Best viewed as an animation, f.eks. FPS 5, steps 25
> [image: image.png]
>
>
> On Thu, 29 Apr 2021 at 14:29, Will Hardiman
> <[hidden email]>
>
> wrote:
> > It seems to me that Gene is describing an ellipse:
> > >it needs to be like the usual woodworkers ellipse
> >
> > layout tool, consisting of 2 pins and a string loop to fix the
> > reach, the string is dropped over the two pins, and a pencil is then
> > used to make the outline mark by using the string as a "thats as far
> > as I can reach" and stay inside the string.
> >
> > A video of this technique:
> > https://www.youtube.com/watch?v=Et3OdzEGX_w
> >
> > In which case the answer has already been posted by Nop Head (module
> > ellipse(xr, yr) scale([1, yr / xr]) circle(xr); ), and any confusion
> > about lobes or asymmetry is just that.
> >
> > On Thu, 29 Apr 2021 at 13:05, jon <[hidden email]> wrote:
> >> Gene:
> >>
> >> Can you make the shape you want by using hull() on two circles or
> >> cylinders of different diameters spaced a bit apart?
> >>
> >>
> >> On 4/29/2021 7:59 AM, [hidden email] wrote:
> >>
> >> Gene, I’m afraid it’s still far from clear (to me, at least) what
> >> exactly you’re trying make. Ellipses don’t have “lobes”. Perhaps
> >> you could post a hand-drawn sketch of what you want to make?
> >>
> >> Gene Heskett wrote:
> >>
> >> …That looks as if it should do it except that will make a single
> >> lobe … so the ellipse will have two lobes
> >>
> >> _______________________________________________
> >> OpenSCAD mailing list
> >> To unsubscribe send an email to [hidden email]
> >
> > _______________________________________________
> > OpenSCAD mailing list
> > To unsubscribe send an email to [hidden email]


Cheers, Gene Heskett
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis
Genes Web page <http://geneslinuxbox.net:6309/gene>
_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]

_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
+--+
| M |
+--+
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

Gene Heskett
On Thursday 29 April 2021 15:20:16 Michael Möller wrote:

> As nophead wrote : https://en.wikipedia.org/wiki/Ellipse#Circumference
> ... if you just want to read rather than watch.
>
No wonder, yee Gods etc, that the guys during Apollo wanted to know if
Katherine checked their orbits, she may have been the only person on the
planet that understood all that stuff.

> The article gives a relatively simple formula for an approximation,
> and the error bounds. It may be enough for you.

Simple? I don't want to know your definitiion of complex.

> Put that into a spread sheet or something and adjust a,b until they
> fit your circumference requirement and eccentricity.
>
The last spreadsheet I used was dynacalc for os9 in '86, to print it all
out and prove to the state income tax folks that they had finally
managed to write an income tax law that ate its own tail, and without
changing a thing, it calculated about 20% greater liability everytime
you hit the recalc key, I mailed them the printouts of that whole
hairball and said you calculate it, I can't get a straight answer.  Took
them about 5 months to issue a refund for more than I'd ever seen out of
dynacalc. And the intructions for the next year were simple enough I
could do it a 4 banger $12 calc.  One of those that said 2X2 was
3.999999.  And they bought it!

Life can be seriously funny, and it would be fun if it didn't end with a
death sentence anyway. :-)

Cheers, Gene Heskett
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis
Genes Web page <http://geneslinuxbox.net:6309/gene>
_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: How hard is it to do a just slighty eccentric circle in openscad?

JordanBrown
In reply to this post by Gene Heskett
On 4/29/2021 9:43 AM, Gene Heskett wrote:
In which case the answer has already been posted by Nop Head (module
ellipse(xr, yr) scale([1, yr / xr]) circle(xr); ), and any confusion
about lobes or asymmetry is just that.
I believe thats correct, however ellipse is not listed in the cheat 
sheet, so where do I find its docs?

There is no built-in ellipse module.

What's shown above is the *definition* of an ellipse module:
module ellipse(xr, yr) scale([1, yr / xr]) circle(xr);
Once you have that, you can say "ellipse(3,5);" to get an ellipse with a "radius" in X of 3 and in Y of 5.  (I don't know whether that's a good definition of "radius", but it's sort of understandable.)


_______________________________________________
OpenSCAD mailing list
To unsubscribe send an email to [hidden email]
12