![](/i/fill.gif) |
![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Hi,
I am having trouble with mathss, now I know this isn't a maths group, so
ill explain my problem and pray for forgivness..
I have a cylinder object, its verticle like a tower, then rotated (tilted
like the tower of pisa) 15 degrees.
I want to place a series of windows around the tower, but so that they
appear paralel to the ground plane. These windows are cutouts.
The easy part is making each window vertical, by simply rotating it as I
place them. But the hard part (for me) is working out the shape or size
of the elipse that a level floor would be...
Am I being clear? Even though it's a cylinder, because it's tilted the
floor isnotacircle, so I need torotate the windows around an elipse...
I can easily cut holes, but I want to place features on the cylinder
surface.
Were do I begin?
Thanks
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
the radius of the long side of the ellips equals the radius of you cylinder
divided by the cosine of the angle of rotation.
the radius short side of the ellips doesn't change.
so if i'm not mistaken you can make a cylinder of limited height and then
scale it in the right direction by an amount of 1/cos(15*pi/180) where the
latter part converts your 15 degrees to radians.
"Rob Brown-Bayliss" <rob### [at] zoism org> wrote in message
news:3d5f3f82@news.povray.org...
> Hi,
>
> I am having trouble with mathss, now I know this isn't a maths group, so
> ill explain my problem and pray for forgivness..
>
> I have a cylinder object, its verticle like a tower, then rotated (tilted
> like the tower of pisa) 15 degrees.
>
> I want to place a series of windows around the tower, but so that they
> appear paralel to the ground plane. These windows are cutouts.
>
> The easy part is making each window vertical, by simply rotating it as I
> place them. But the hard part (for me) is working out the shape or size
> of the elipse that a level floor would be...
>
> Am I being clear? Even though it's a cylinder, because it's tilted the
> floor isnotacircle, so I need torotate the windows around an elipse...
>
> I can easily cut holes, but I want to place features on the cylinder
> surface.
>
> Were do I begin?
>
> Thanks
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Wasn't it Rob Brown-Bayliss who wrote:
>Hi,
>
>I am having trouble with mathss, now I know this isn't a maths group, so
>ill explain my problem and pray for forgivness..
>
>I have a cylinder object, its verticle like a tower, then rotated (tilted
>like the tower of pisa) 15 degrees.
>
>I want to place a series of windows around the tower, but so that they
>appear paralel to the ground plane. These windows are cutouts.
>
>The easy part is making each window vertical, by simply rotating it as I
>place them. But the hard part (for me) is working out the shape or size
>of the elipse that a level floor would be...
>
>Am I being clear? Even though it's a cylinder, because it's tilted the
>floor isnotacircle, so I need torotate the windows around an elipse...
>
>I can easily cut holes, but I want to place features on the cylinder
>surface.
>
>Were do I begin?
A fairly non-mathematical solution would be to use trace().
A more mathematical solution would be to consider that the semimajor
axis (A) of the ellipse you seek is R/Cos(Theta) where R is the radius
of the original cylinder and Theta is the tilt (15 degrees) expressed in
radians. The semiminor axis (B) of the ellipse is just R. The equation
of an ellipse with semiaxes A and B is x^2/A^2 + z^2/B^2 = 1 so if your
tilt is a z rotation:
x^2/(R/cos(radians(15))^2 + z^2/R^2 = 1
The centre of the ellipse depends on the height above or below the
centre of rotation. This can be incorporated by substituting
x => x-y/tan(Theta) in the above equation.
It might be easier to work with parametric equations:
x = R/cos(radians(15)) * cos(t) - y/tan(radians(15))
z = R * sin(t)
varying t from 0 to 2*pi.
For example:-
camera { location <0,2,-5> look_at <0,2,0>}
light_source { <2,5,-5> colour 1}
plane { y, 0 pigment { rgb 1}}
#declare R=1; // tower radius
#declare H=4; // tower height
#declare Tilt=15; // tower tilt (degrees)
cylinder {0,y*H 1 rotate z*Tilt pigment {rgb 1}}
#declare h=0;
#while (h<H)
#declare T=0;
#while (T<2*pi)
#declare X =R/cos(radians(Tilt)) * cos(T) - h*tan(radians(Tilt));
#declare Z =R*sin(T);
sphere {<X,h,Z>,0.05 pigment {rgb <1,1,0>}}
#declare T=T+0.4;
#end
#declare h=h+0.5;
#end
--
Mike Williams
Gentleman of Leisure
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
maybe I read what you wanted wrong, but why not differnce the windows from
the cylidner and then rotate the whole thing to the required angle?
jim
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
On Mon, 19 Aug 2002 07:51:22 +1200, James Taylor wrote:
> maybe I read what you wanted wrong, but why not differnce the windows
> from the cylidner and then rotate the whole thing to the required angle?
>
> jim
Then the windows are at an angle tothe ground, not level, or parallel
with the ground. What I am trying to achieve is a building leaning on an
angle, but meant to be leaning on an angle, where as the tower of pisa
was not designed to lean over...
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
On Sun, 18 Aug 2002 18:33:50 +1200, Rob Brown-Bayliss wrote:
Thanks for all the help... :o)
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
In article <3d600f3e@news.povray.org>,
Rob Brown-Bayliss <rob### [at] zoism org> wrote:
> Then the windows are at an angle tothe ground, not level, or parallel
> with the ground. What I am trying to achieve is a building leaning on an
> angle, but meant to be leaning on an angle, where as the tower of pisa
> was not designed to lean over...
You could shear it instead of rotating. Then the windows and the top and
bottom would be level with the ground.
--
Christopher James Huff <cja### [at] earthlink net>
http://home.earthlink.net/~cjameshuff/
POV-Ray TAG: chr### [at] tag povray org
http://tag.povray.org/
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
On Mon, 19 Aug 2002 12:41:25 +1200, Christopher James Huff wrote:
> In article <3d600f3e@news.povray.org>,
> Rob Brown-Bayliss <rob### [at] zoism org> wrote:
>
>> Then the windows are at an angle tothe ground, not level, or parallel
>> with the ground. What I am trying to achieve is a building leaning on
>> an angle, but meant to be leaning on an angle, where as the tower of
>> pisa was not designed to lean over...
>
> You could shear it instead of rotating. Then the windows and the top and
> bottom would be level with the ground.
except that it's a cylinder structure, a tower if you will. So as the
windows go around the tower they need to be rotated as well... Thas the
easy bit, som of the other answers provide thew dificult bits..
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
In article <3d604a85@news.povray.org>,
Rob Brown-Bayliss <rob### [at] zoism org> wrote:
> except that it's a cylinder structure, a tower if you will. So as the
> windows go around the tower they need to be rotated as well... Thas the
> easy bit, som of the other answers provide thew dificult bits..
I don't understand. Cutting the windows out of a plain cylinder seems
easy enough, then just shear the result.
--
Christopher James Huff <cja### [at] earthlink net>
http://home.earthlink.net/~cjameshuff/
POV-Ray TAG: chr### [at] tag povray org
http://tag.povray.org/
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |