Prev: there is an "oops" with Root and Limit
Next: Using numbers close to to zero in Mathematica version 6
From: John Ertle Jr. on 9 Apr 2010 03:34 In[82]:= J = 367*y + floor (7*(y + floor ((m + 9)/12))/4) + int (275*m/9) + da + 1721013.5 Out[82]= 2.44254*10^6 + 7/4 floor (1966 + (17 floor)/12) + (2200 int)/ 9 How do you evaluate the floor s in the output in this example to yield a number for the Julian Date.
From: Murray Eisenberg on 10 Apr 2010 06:53 What symbolic system are your trying to use? Built-in objects in Mathematica have names beginning with upper-case letters; function calls surround their arguments with square-brackets, not parentheses. In any case, I don't see any "s" in the output. The relevant Mathematica function is -- guess what! -- Floor to calculate the floor of something. Of course you cannot expect it to do an actual evaluation of the Floor of something unless all the variables inside the argument already have actual numeric values. On 4/9/2010 3:34 AM, John Ertle Jr. wrote: > In[82]:= J = > 367*y + floor (7*(y + floor ((m + 9)/12))/4) + int (275*m/9) + da + > 1721013.5 > > Out[82]= 2.44254*10^6 + 7/4 floor (1966 + (17 floor)/12) + (2200 int)/ > 9 > > How do you evaluate the floor s in the output in this example to yield a number for the Julian Date. > -- Murray Eisenberg murray(a)math.umass.edu Mathematics & Statistics Dept. Lederle Graduate Research Tower phone 413 549-1020 (H) University of Massachusetts 413 545-2859 (W) 710 North Pleasant Street fax 413 545-1801 Amherst, MA 01003-9305
From: Bill Rowe on 10 Apr 2010 06:54 On 4/9/10 at 3:34 AM, ertlejack(a)sbcglobal.net (John Ertle Jr.) wrote: >In[82]:= J = 367*y + floor (7*(y + floor ((m + 9)/12))/4) + int >(275*m/9) + da + >1721013.5 >Out[82]= 2.44254*10^6 + 7/4 floor (1966 + (17 floor)/12) + (2200 >int)/ >9 >How do you evaluate the floor s in the output in this example to >yield a number for the Julian Date. You will have a lot more success if you use valid Mathematica syntax and spend some time reading the documentation. All built-in Mathematica functions start with an upper case letter and function arguments should be surrounded by square brackets, "[" and "]" not "(" and ")". That is In[34]:= 367*y + Floor[7*(y + Floor [(m + 9)/12])/4] + IntegerPart [275*m/9] + da + 1721013.5 /. {y -> 2010, m -> 4, da -> 15} Out[34]= 2.46234*10^6
From: John Ertle Jr. on 10 Apr 2010 06:55
I figured out that if you try to manipulate the data the floor will no reevaluate. You just have to make a new notebook! |