protrader

409 Reputation

7 Badges

16 years, 315 days

MaplePrimes Activity


These are replies submitted by protrader

 

 

yes, it works, that meets my needs, thanks a lor Robert, you are the man!

 

 

Robert,

I tried many dates, your proc gives +/-1 day sometimes. I think it is because of the leap years. To determine whether a year is a leap year or not there is a very simple method for Gregorian calendar:

 

if (year modulo 4 is 0) and (year modulo 100 is not 0) or (year modulo 400 is 0)


       then is_leap_year
else
       not_leap_year

(from: http://en.wikipedia.org/wiki/Leap_year)

 

 

 

 

Robert,

I tried many dates, your proc gives +/-1 day sometimes. I think it is because of the leap years. To determine whether a year is a leap year or not there is a very simple method for Gregorian calendar:

 

if (year modulo 4 is 0) and (year modulo 100 is not 0) or (year modulo 400 is 0)


       then is_leap_year
else
       not_leap_year

(from: http://en.wikipedia.org/wiki/Leap_year)

 

 

 

 

I appreciate it very much Joe!

 

 

 

I appreciate it very much Joe!

 

 

 

wow, this is really a sophisticated procedure, thanks. I am sorry I forgot sth to tell. I am currently playing with these functions that you used but to complete your procedure, how can we add CD as below:

8(-2 CD)=1+2+3
Note that CD always is a string and will not change at all.

 

 

wow, this is really a sophisticated procedure, thanks. I am sorry I forgot sth to tell. I am currently playing with these functions that you used but to complete your procedure, how can we add CD as below:

8(-2 CD)=1+2+3
Note that CD always is a string and will not change at all.

 

 

Thanks a lot. Could you please tell me how I can add other things to this symbol? I will need to add "=" sign and a number in paranthesis e.g.

vec2symb(<1,2,3>,<8,-2>);

The output must be:
8(-2)=1+2+3

 

 

 

 

Thanks a lot. Could you please tell me how I can add other things to this symbol? I will need to add "=" sign and a number in paranthesis e.g.

vec2symb(<1,2,3>,<8,-2>);

The output must be:
8(-2)=1+2+3

 

 

I could not get it worked?

I could not get it worked?

That's smart Robert:

restart:
M:=Matrix([[1,2,9],[-4,5,0],[3,9,2]]);
find := (A, v) ->  select(i -> (A[op(i)]=v), [indices(A)]):
find(M,max(M));
                              [[1, 3], [3, 2]]
find(M,min(M));
                                  [[2, 1]]
 

It is funny I could not paste the output matrix M, I am using mozilla fireofx, how do you copy such results into here?

That's smart Robert:

restart:
M:=Matrix([[1,2,9],[-4,5,0],[3,9,2]]);
find := (A, v) ->  select(i -> (A[op(i)]=v), [indices(A)]):
find(M,max(M));
                              [[1, 3], [3, 2]]
find(M,min(M));
                                  [[2, 1]]
 

It is funny I could not paste the output matrix M, I am using mozilla fireofx, how do you copy such results into here?

Thanks acer,
can we change its font size too? or mkae it bold, italic, etc ? Where in the help can I find some more examples of this?

Thanks acer,
can we change its font size too? or mkae it bold, italic, etc ? Where in the help can I find some more examples of this?

1 2 3 4 Page 2 of 4