Re: Evaluating Min[2^(1/2),3^(1/2)]
- To: mathgroup at yoda.physics.unc.edu
- Subject: Re: Evaluating Min[2^(1/2),3^(1/2)]
- From: "Roger B. Kirchner" <kirchner at cs.umn.edu>
- Date: Thu, 27 Aug 1992 12:21:36 -0500
Using David Jacobson's name and generalizing Todd Gayley's solution
by replacing the outer First@ with Sequence@@, we get
ExactMin[items__] :=
Module[ {nlist = N /@ {items}},
{items}[[ Sequence@@First at Position[nlist,Min[nlist]] ]]
]
ExactMin can be applied to a list or a sequence of numbers, lists.
E.g.
ExactMin[Sin[1], {Cos[1], 2 - 2^(1/2)} evaluates to Cos[1].
Thanks for the help.
Roger Kirchner