Mooncalf

01-29-2004, 02:10 AM

Hi y'all,

So I was going through the Auto-Breathe tutorial over at kiaran.net Everything works fine, but I'm not content just to see that it DOES work; I want to know WHY.

To put it briefly, the whole auto-breathe is controlled by an expression that looks like this:

mouthControl.breatheIn=abs(sin(time*mouthControl.frequency))*mouthControl.depth;

I'm sure this is pretty basic fare. And I understand what it's doing, for the most part. But I'm having trouble visualizing how the sin works.

I vaguely remember sin and cos and tan from 10th grade, but that was a long time ago. I know it's a wave...I'd like to know a few things:

a) Exactly the value it is multiplying the rest of the equation by? (I recognize it is not a constant value) Is there a way to visually represent this for me to understand?

b) I tried replacing sin with cos and got a nearly identical result. I say "nearly" because I couldn't tel the difference, though I'm sure there is one. What IS the difference? And what would be an example where I would use cos instead of sin?

c) How about tan? Is that a totally other kind of equation? (replacing "sin" with "tan" had some interesting results)

Any help understanding would be appreciated... as I appreciate your patience with my learning curve. :)

- M

So I was going through the Auto-Breathe tutorial over at kiaran.net Everything works fine, but I'm not content just to see that it DOES work; I want to know WHY.

To put it briefly, the whole auto-breathe is controlled by an expression that looks like this:

mouthControl.breatheIn=abs(sin(time*mouthControl.frequency))*mouthControl.depth;

I'm sure this is pretty basic fare. And I understand what it's doing, for the most part. But I'm having trouble visualizing how the sin works.

I vaguely remember sin and cos and tan from 10th grade, but that was a long time ago. I know it's a wave...I'd like to know a few things:

a) Exactly the value it is multiplying the rest of the equation by? (I recognize it is not a constant value) Is there a way to visually represent this for me to understand?

b) I tried replacing sin with cos and got a nearly identical result. I say "nearly" because I couldn't tel the difference, though I'm sure there is one. What IS the difference? And what would be an example where I would use cos instead of sin?

c) How about tan? Is that a totally other kind of equation? (replacing "sin" with "tan" had some interesting results)

Any help understanding would be appreciated... as I appreciate your patience with my learning curve. :)

- M