Simple 3d orbit question

  • Thread starter ducati321
  • Start date
  • #1
1
0
"simple" 3d orbit question

Hi folks,
I am following this pattern:
http://www.bit-101.com/tutorials/3D-rotation.html

to build a 3d model of an atom, using silverlight. I have what i think is an easy question for math pros... I'd like to know what I can change to make the angle of the orbiting item (my electron) be different.

In other words, my electron is currently orbiting in a horizontal left-to-right pattern. what can I do to get it to a 45 or 30 or N degrees angle, so it's traversing my nucleus diagonally?

the blue dot is my electron orbiting the yellow nucleus...
2 pics below show it going from left to right, it's centerY is constant...

here is my math:
newx = Math.Cos(t * Math.PI / 180) * radius + xCenter;
newy = yCenter; //-- y is constant cause it's horizontal

newz = Math.Sin(t * Math.PI / 180) * radius + zCenter;
scale1 = fl / (fl + newz);

electron1.Width = electron1.Height = scale1 * 100;

Thanks folks!
4i2cn.jpg
 

Answers and Replies

Related Threads on Simple 3d orbit question

Replies
3
Views
2K
  • Last Post
Replies
3
Views
4K
  • Last Post
Replies
2
Views
2K
  • Last Post
Replies
6
Views
10K
  • Last Post
Replies
11
Views
5K
  • Last Post
Replies
4
Views
2K
  • Last Post
Replies
2
Views
3K
Top