BBO Discussion Forums: Cute little math trick - BBO Discussion Forums

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Cute little math trick

#1 User is online   hrothgar 

  • PipPipPipPipPipPipPipPipPipPipPip
  • Group: Advanced Members
  • Posts: 15,683
  • Joined: 2003-February-13
  • Gender:Male
  • Location:Natick, MA
  • Interests:Travel
    Cooking
    Brewing
    Hiking

Posted 2009-June-19, 05:48

So, I'm sitting at work yesterday and one of our users needs an easy way to calculate the area of a trapezoid.

I still and think about things and come up with a decent enough solution using my old high school algebra.

I post the solution.
10 minutes later one of our developers comes back and replaced the entire function with less than a single line of code

Apparantly I forgot that the vector area of a quadrilateral is one half the cross product of the diagonals.

More significant, we never spent any real time on linear algebra back in High School. As a result, I lost on on a wealth of cute little tricks like this one.

Folks might find the following web site amusing:

http://softsurfer.com/Archive/algorithm_01...orithm_0101.htm
Alderaan delenda est
0

#2 User is offline   gwnn 

  • Csaba the Hutt
  • PipPipPipPipPipPipPipPipPipPip
  • Group: Advanced Members
  • Posts: 13,027
  • Joined: 2006-June-16
  • Gender:Male
  • Interests:bye

Posted 2009-June-19, 06:19

Nice, I didn't know about that theorem either. Indeed it's a cute page, thanks.
... and I can prove it with my usual, flawless logic.
      George Carlin
0

#3 User is offline   Jlall 

  • Follower of 655321
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 3,293
  • Joined: 2008-December-05
  • Interests:drinking, women, bridge...what else?

Posted 2009-June-19, 19:14

obv
0

#4 User is offline   blackshoe 

  • PipPipPipPipPipPipPipPipPipPipPip
  • Group: Advanced Members
  • Posts: 17,849
  • Joined: 2006-April-17
  • Gender:Male
  • Location:Rochester, NY

Posted 2009-June-19, 21:12

What, no "LOL"? :P
--------------------
As for tv, screw it. You aren't missing anything. -- Ken Berg
Our ultimate goal on defense is to know by trick two or three everyone's hand at the table. -- Mike777
I have come to realise it is futile to expect or hope a regular club game will be run in accordance with the laws. -- Jillybean
0

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users