Welcome! Log In Create A New Profile

Advanced

How to do same with cube as cylinder(d1,d2,h)

Posted by Vuokko 
How to do same with cube as cylinder(d1,d2,h)
May 12, 2016 03:53PM
I want cube which has top of 5x5 and bottom 8x8 and height of 15.

With cylinder I can do this simply cylinder(d1=8, d2=5 h=15) but how do I do this with cube? With polyhedron and hard thinking could achieve that, but not really useful, I think.
Re: How to do same with cube as cylinder(d1,d2,h)
May 12, 2016 04:42PM
you can use either hull() to do this, e.g.
hull(){
   cube([8,8,0.1]);
   translate([1.5,1.5,14.9])cube([5,5,0.1]);
}
or just use cylinder with $fn=4, something like:
rotate(45)cylinder(d1=8*sqrt(2), d2=5*sqrt(2), h=15,$fn=4);
Sorry, only registered users may post in this forum.

Click here to login