
Leitia Adept
Joined: 04 May 2007 Posts: 292 Location: Boston

Posted: Fri Jul 13, 2007 4:56 am
Mathfun 
This is an algorithm I think, I discovered it computing the remainder for up to 4 lots of 50 to 200, I am not
in the math community, so to me this is amazing, even negative numbers do not return 0. I am guessing at physics from here and there.
#var sips %1
#sh @sips" ="
#sh %eval( 50  (200  (@sips + (50 * %int( (200  @sips) / 50)))))
#sh " "
other constants:
note: %int (integer) truncates the fraction.
%eval( 0  (1  (@sips + (0 * %int( (1  @sips) / 0)))))
subtracts 1 for positives and adds 1 for negatives
%eval( 1  (0  (@sips + (1 * %int( (0  @sips) / 1)))))
always returns 1 even for 0  also never changes in the super numbers.
which I wonder if in reality is this too:
%eval( 1  (1  (@sips + (1 * %int( (1  @sips) / 1)))))
and
%eval( 1  (2  (@sips + (1 * %int( (2  @sips) / 1)))))
%eval( 19  (20  (@sips + (19 * %int( (20  @sips) / 19)))))
this makes 1 act like 0
%eval( 199  (200  (@sips + (199 * %int( (200  @sips) / 199)))))
this is hard to describe but super numbers always return 3 digits, it is cyclical, pleasant and ratio looking
anyway
%eval( 200  (200  (@sips + (200 * %int( (200  @sips) / 200)))))
this outputs the input to 400 but to me it acts as a wave (with an origin at 100?) it seems to end at + 9999999999. Sometimes these other permutations seem to end, sometimes they don't.
%eval( 3  (3  (@sips + (3 * %int( (3  @sips) / 3)))))
this returns 3,4,5 for numbers above 3 and 1,2,3 for numbers below
and also
%eval( 3  (3  (@sips + (3 * %int( (3  @sips) / 3)))))
10x numbers (1000000) return 4 0000000000000001 return 2
%eval( 4  (4  (@sips + (4 * %int( (4  @sips) / 4)))))
same deal if it is a wave it has a larger oscillation, probably they are ratios, or base numbers. I don't get either.
%eval( 4  (40  (@sips + (4 * %int( (40  @sips) / 4)))))
2 x 4 seems significant in range, nothing cool
now I am bored. see ya. 



Leitia Adept
Joined: 04 May 2007 Posts: 292 Location: Boston

Posted: Fri Jul 13, 2007 7:57 pm 
This is the code I am using to test it. I know there are simpler ways of saying 100  2 = 98 but using this alias I can say it as  rocketscience 100 0 2
It will do 0 if I use 0 in the constants, otherwise it does not understand 0
I am still trying to understand the sequences
excuse my exhuberance. I have never seen one before and having created one to one purpose it is exciting to see it do other things.
this is my test code:
#if (%isnumber( %3)) {
#var term %3
#sh term" ="@term
}
#if (%isnumber( %2)) {
#var group %2
#sh group" ="@group
}
#if (%isnumber( %1)) {
#var sips %1
#sh sips" ="@sips
#sh %eval( @group  (@term  (@sips + (@group * %int( (@term  @sips) / @group)))))
} {
#sh " sips = "@sips
#sh " group = "@group
#sh " term = "@term
#SH " "
#sh " %eval( "@group"  ("@term"  ("@sips" + ("@group" * %int( ("@term"  "@sips") / "@group")))))"
}
#sh " " 






You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum

