This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2010-07-07 00:25:06

Sunrise-Moon
Scratcher
Registered: 2009-06-27
Posts: 1000+

Sine and Cosine Explained?

Could someone explain to me what the sine and cosine do and how to use them?


http://i1067.photobucket.com/albums/u427/HulKDzN/RebornBlade.png

Offline

 

#2 2010-07-07 00:29:14

ChuxXxliciousness
Scratcher
Registered: 2010-02-25
Posts: 90

Re: Sine and Cosine Explained?

They're trig functions, that's pretty much all I know about it and need to know.

Sine make a sideways S shape on a graphing calculator and Cosine makes a U or V shape


http://img443.imageshack.us/img443/676/continent2.pnghttp://img180.imageshack.us/img180/9229/button2a.png

Offline

 

#3 2010-07-07 00:36:50

Sunrise-Moon
Scratcher
Registered: 2009-06-27
Posts: 1000+

Re: Sine and Cosine Explained?

ChuxXxliciousness wrote:

They're trig functions, that's pretty much all I know about it and need to know.

Sine make a sideways S shape on a graphing calculator and Cosine makes a U or V shape

lol I'm pretty sure it can be helpful to at least know  yikes


http://i1067.photobucket.com/albums/u427/HulKDzN/RebornBlade.png

Offline

 

#4 2010-07-07 00:46:15

ChuxXxliciousness
Scratcher
Registered: 2010-02-25
Posts: 90

Re: Sine and Cosine Explained?

I guess they might come in handy making patterns or something like that, but I've never found a use for them. Maybe I could use it to make wavy text or something xD


http://img443.imageshack.us/img443/676/continent2.pnghttp://img180.imageshack.us/img180/9229/button2a.png

Offline

 

#5 2010-07-07 00:55:07

Harakou
Community Moderator
Registered: 2009-10-11
Posts: 1000+

Re: Sine and Cosine Explained?

Sine, cosine, and tangent are ratios in right triangles used in calculating distance and angles.

They're often used in projects involving things like launching objects based on angles and power.

I know that a lot of people want a block that points a sprite at a specific coordinate. Using trig, you can do that!  big_smile

Last edited by Harakou (2010-07-07 01:19:36)


http://www.blocks.scratchr.org/API.php?action=random&return=image&link1=http://i.imgur.com/OZn2RD3.png&link2=http://i.imgur.com/duzaGTB.png&link3=http://i.imgur.com/CrDGvvZ.png&link4=http://i.imgur.com/POEpQyZ.png&link5=http://i.imgur.com/ZKJF8ac.png

Offline

 

#6 2010-07-07 01:07:31

ChuxXxliciousness
Scratcher
Registered: 2010-02-25
Posts: 90

Re: Sine and Cosine Explained?

Well there you have it! lol.
Now if only I had good teachers at my school that would have told me the uses for trig functions. I didn't even do any of the work for the class, just programmed my calculator to do the problems for me. Aced every test that way!  big_smile


http://img443.imageshack.us/img443/676/continent2.pnghttp://img180.imageshack.us/img180/9229/button2a.png

Offline

 

#7 2010-07-07 01:18:20

Harakou
Community Moderator
Registered: 2009-10-11
Posts: 1000+

Re: Sine and Cosine Explained?

ChuxXxliciousness wrote:

Well there you have it! lol.
Now if only I had good teachers at my school that would have told me the uses for trig functions. I didn't even do any of the work for the class, just programmed my calculator to do the problems for me. Aced every test that way!  big_smile

On a TI-84? I love those! My friend and I wrote a program that factored trinomials for us.  big_smile


http://www.blocks.scratchr.org/API.php?action=random&return=image&link1=http://i.imgur.com/OZn2RD3.png&link2=http://i.imgur.com/duzaGTB.png&link3=http://i.imgur.com/CrDGvvZ.png&link4=http://i.imgur.com/POEpQyZ.png&link5=http://i.imgur.com/ZKJF8ac.png

Offline

 

#8 2010-07-07 06:42:04

ScratchReallyROCKS
Scratcher
Registered: 2009-04-22
Posts: 1000+

Re: Sine and Cosine Explained?

Heres a little project I uploaded yesterday:

(link to project)

It shows trig functions in the form of a triangle. Look at the sine and cosine scripts to see how they work.


http://imageshack.us/a/img694/3806/sigmad.png

Offline

 

#9 2010-07-07 10:07:34

TimeFreeze
Scratcher
Registered: 2008-08-11
Posts: 500+

Re: Sine and Cosine Explained?

They are actually the only reason that Scratch has the [move 10 steps] block. That block is really this:

[change x by ((sin of direction) * 10)]
[change y by ((cos of direction) * 10)]

The number that you put after * is the number of steps you want it to move.
If it was:

[change x by ((sin of direction) * 7)]
[change y by ((cos of direction) * 7)]

That would be [move 7 steps].

This can be useful for scrolling sometimes.


Hope it helps  smile !

Last edited by TimeFreeze (2010-07-07 10:08:21)


There are 10 types of people in this world: Those who understand binary, and those who don't. --[insert unrelated transition]-- GRANDILOQUENCE FTW!

Offline

 

#10 2010-07-07 10:12:17

juststickman
Scratcher
Registered: 2009-05-31
Posts: 1000+

Re: Sine and Cosine Explained?

Harakou wrote:

ChuxXxliciousness wrote:

Well there you have it! lol.
Now if only I had good teachers at my school that would have told me the uses for trig functions. I didn't even do any of the work for the class, just programmed my calculator to do the problems for me. Aced every test that way!  big_smile

On a TI-84? I love those! My friend and I wrote a program that factored trinomials for us.  big_smile

In my school, they gave us a program to do that stuff  smile

TimeFreeze wrote:

They are actually the only reason that Scratch has the [move 10 steps] block. That block is really this:

[change x by ((sin of direction) * 10)]
[change y by ((cos of direction) * 10)]

The number that you put after * is the number of steps you want it to move.
If it was:

[change x by ((sin of direction) * 7)]
[change y by ((cos of direction) * 7)]

That would be [move 7 steps].

This can be useful for scrolling sometimes.


Hope it helps  smile !

This is only for scratch. Otherwise you use cos for x and sin for y.


http://is.gd/iBQi2 Add grob to your sig and help with world dominiation!http://is.gd/iBQ9Q                                                             Hey guys, we're seriously naming our team bob?

Offline

 

#11 2010-07-07 15:26:08

Sunrise-Moon
Scratcher
Registered: 2009-06-27
Posts: 1000+

Re: Sine and Cosine Explained?

Ok, I see the use for it now. Thanks  smile


http://i1067.photobucket.com/albums/u427/HulKDzN/RebornBlade.png

Offline

 

#12 2010-07-07 16:15:03

coolstuff
Community Moderator
Registered: 2008-03-06
Posts: 1000+

Re: Sine and Cosine Explained?

It also has a lot of practical uses in things such as arms - my stickfigure animator, for example, uses trig.

Offline

 

Board footer