POV-Ray : Newsgroups : povray.news-submissions : getting coordinates : Re: getting coordinates Server Time27 Mar 2023 06:56:49 EDT (-0400)
 Re: getting coordinates
 From: Tor Olav Kristensen Date: 1 Jan 2010 14:40:01 Message:
```
{
"@context": "https://schema.org",
"@type": "DiscussionForumPosting",
"@id": "#web.4b3e4f7d40720782fca6f0ee0%40news.povray.org",
"dateCreated": "2010-01-01T19:40:01+00:00",
"datePublished": "2010-01-01T19:40:01+00:00",
"author": {
"@type": "Person",
"name": "Tor Olav Kristensen"
}
}
Warp <war### [at] tagpovrayorg> wrote:
> Tor Olav Kristensen <tor### [at] toberemovedgmailcom> wrote:
> > "Coucou" <dom### [at] neuffr> wrote:
> > ......
> > > How to get x, y and z of C1 ?
>
> > You can write:
>
> >   vdot(C1, x)
> >   vdot(C1, y)
> >   vdot(C1, z)
>
> > - or shorter:
>
> >   C1.x
> >   C1.y
> >   C1.z
>
>   I hate to sound rude, but I really don't understand why give first a rather
> contrived answer of "vdot(C1, x)" and then give the right answer "C1.x".
> The dot product does produce the same result, but it's a needlessly
> complicated solution, so I don't really understand why you even suggested it.

Ok, the documentation says that the dot operator is used to extract components
from vectors.

- But the reason that I wrote it that way, is because I like to think of the
"C1.x" form as a short form of the dot product between the C1 vector and the
basis vector x.

It wasn't my intention to confuse anyone.

(Several ASCII-coded texts/papers/posts about vector math use the "." as the
vector dot product operator.)

--
Tor Olav
http://subcube.com
```