Go to Post On the one hand, I wouldn’t want to discourage innovation. But on the other, I would want to encourage simplicity. - Jack Jones [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #2   Spotlight this post!  
Unread 04-02-2007, 14:45
Bongle's Avatar
Bongle Bongle is offline
Registered User
FRC #2702 (REBotics)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2002
Location: Waterloo
Posts: 1,069
Bongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond repute
Send a message via MSN to Bongle
Re: Storing functions to variables

If I read this correctly, you're trying to make a function that returns a distance.

Code:
double dist(double tilt_angR)
{
  return 80.0/tan(tilt_angR);
}
That code will do what I think you want to do.
 


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Storing the balls Max Brin Technical Discussion 4 18-02-2006 20:34
Math.h and Functions and Variables amateurrobotguy Programming 1 26-02-2005 03:19
PDF of all functions/variables! mikesown Programming 1 01-02-2005 18:56
Storing Tetras on Robot MisterX General Forum 22 15-01-2005 19:26
SCORing vs. STORing Chris Fultz General Forum 3 15-01-2004 13:36


All times are GMT -5. The time now is 23:52.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi