View Single Post
  #1   Spotlight this post!  
Unread 06-03-2006, 20:40
sanddrag sanddrag is offline
On to my 16th year in FRC
FRC #0696 (Circuit Breakers)
Team Role: Teacher
 
Join Date: Jul 2002
Rookie Year: 2002
Location: Glendale, CA
Posts: 8,510
sanddrag has a reputation beyond reputesanddrag has a reputation beyond reputesanddrag has a reputation beyond reputesanddrag has a reputation beyond reputesanddrag has a reputation beyond reputesanddrag has a reputation beyond reputesanddrag has a reputation beyond reputesanddrag has a reputation beyond reputesanddrag has a reputation beyond reputesanddrag has a reputation beyond reputesanddrag has a reputation beyond repute
Visual Basic. Using a loop to solve the cosine function.

I need to do this http://upload.wikimedia.org/math/5/b...69cad0c4a3.png in Visual Basic.

Attached is what I have done so far. I can't get it to work right though. I am not a programmer and I'm really struggling with this. I think the problem is coming from instead of (2*n)factorial my program is doing (n factorial)*2. I don't know how to fix it.

It should be noted that the "n" in that equation corresponds to "Counter" in my program and "n" in my program represents the number of terms of the series (since we can't have it going ifinitely).

Hopefully someone can help. Thanks.
Attached Files
File Type: xls Vbcosine.xls (22.5 KB, 517 views)
__________________
Teacher/Engineer/Machinist - Team 696 Circuit Breakers, 2011 - Present
Mentor/Engineer/Machinist, Team 968 RAWC, 2007-2010
Technical Mentor, Team 696 Circuit Breakers, 2005-2007
Student Mechanical Leader and Driver, Team 696 Circuit Breakers, 2002-2004