Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - nemo

Pages: 1 ... 9 10 [11] 12 13 ... 82
151
i remember learning the formula for a triangle in 3rd or 4th grade, along with a square and the approximation of a circle being 3 * r * r. in sixth grade i began learning formulas for 3-D shapes like cones, any-base pyramids, spheres. even had to describe relationships. volume of a cone with radius 1 height 1 is 1/3 the volume of a unit cube. volume of a sphere of radius 1 is 2/3 of a unit cube. completely forget why though.

152
this is exactly how my teachers in elementary school taught the formula. you can also point out that the sum of a triangle's angles are 180 and a square is 360 (360/180 = 2). a pentagon's angles sum to 540. it can also be divided into 3 triangles. 540/180 = 3

153
Art / Re: Image 50*50 : Axe Parser Tutorial
« on: January 09, 2011, 08:36:46 pm »
hey, i didn't see the bumps on this page. i'll do ASCII.

154
Math and Science / Re: Formula for getting prime number?
« on: January 09, 2011, 06:59:22 pm »
I put it in a spoiler so It wouldn't take up the whole page, in the code for the monospace for laying out the matrices.

code automatically has a scrollbar for that reason. if you put code inside a spoiler, for chrome users, it's virtually unreadable. here is a screenshot.

155
Math and Science / Re: Formula for getting prime number?
« on: January 09, 2011, 06:50:49 pm »
for those chrome users who cannot read willrandship's post.

Code: [Select]
Arrange your numbers in a matrix. The width determines the numbers you can eliminate.
Here's the basic concept. The width is a multiple of several prime numbers. If you multiply 3,5,and 7
together you get 105. In the 105 columns, you can eliminate every 3rd starting at 3, every 5th starting
 at 5, and every 7th starting at 7. You don't need to put in two, since you can simply eliminate every
other going down each column (-210 instead of -105)

Example using 3*5 (15)

0   1  2  3  4  5 6  7   8  9 10 11 12 13 14
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
30 31 32 33 34 35 36 37 38 39 40 41 42 43 44
45 46 47 48 49 50 51 52 53 54 55 56 57 58 59

    1   2     4          7  8          11     13 14
    16 17     19         22 23         26     28 29
    31 32     34         37 38         41     43 44
    46 47     49         52 53         56     58 59

The more primes you multiply in (nonprimes are useless, eliminate no more rows) the more you can eliminate! yay!
Now for checkerboarding for multiples of 2:

    1                        7             11     13 
        17     19             23                     29
    31                     37             41     43
        47     49             53                     59

True, you eliminate two, but who cares? You don't lose any primes.

By the way, doing this exactly this way with 105 (0-104) give you 31.428% remaining, whereas 3 gives 33.333% It's exponentially less effective, but still waaay better than just -2.

156
Computer Projects and Ideas / Re: Trio and Niko: Falling
« on: January 09, 2011, 03:49:17 pm »
if you have a bunch of calculations like
Code: [Select]
G*12+F+1*2+theta

a lot of times in a loop, it's a better idea to store it into a tempvar at the beginning of the loop and then just reference the tempvar.

157
Site Feedback and Questions / Re: Random Idea about the Gender Icons
« on: January 08, 2011, 10:25:23 pm »
Quote
If someone can make new one she's free to do so.

fixed  ._.

actually, it would be he's. the word "someone" is of neuter gender. when it comes to pronouns, she is the female pronoun. he is both the male and neuter pronoun. it comes straight out of German.
[/rant]

158
Art / Re: Assemblex Icon
« on: January 08, 2011, 08:38:23 pm »
Hum.. I like it nemo. I just don't like the fact that it has a background, most programs for Windows don't have icon backgrounds. Eitherway, make it non-background and I just might use it. THANKS ;D

oops. windows paint put that as its background then when i opened it up in gimp, i forgot that it wasn't transparent.

159
TI Z80 / Re: 'DE
« on: January 08, 2011, 08:32:23 pm »
no

is it dead? i was excited to see OOP on a calculator.

160
Art / Re: Assemblex Icon
« on: January 08, 2011, 08:30:45 pm »
eh?

161
Computer Projects and Ideas / Re: Juggernaut
« on: January 08, 2011, 07:25:31 pm »
level 12 of Exodus has been ported to Juggernaut, because i made level 12 of Exodus. the menu system is complete and doesn't take up unnecessary memory and doesn't slow the program down. now to port the other two levels i made for Exodus. of course, level 12 accomodates for Juggernauts physics so there are a few differences, but the way to solve it is fundamentally the same.

162
Computer Projects and Ideas / Re: Juggernaut
« on: January 08, 2011, 01:55:00 pm »
so, i revamped the menu system and now it is more maintainable and extendable. however, in-game when you press pause then you press resume, there is a massive slowdown, which only gets worse the more times you pause then resume. i pressed ctrl+alt+del and noticed that my program is taking from 60-90% of the CPU, generally over 80%, which is very undesirable. i've yet to come across the culprit of the slowdown, but i believe it is that everytime i return to the game, there is a "savestate" of all the variables and flags, and they are all wastefully recreated. this is a problem for another day though.

That's quite a lot nemo, I mean, for a maze Java game. Is fullscreen available?

it's not a maze, it's more like Exodus. i did come up with a solution though which will slowdown the game slightly overall, but it will be consistent. no random slowdowns, hopefully. i'm using platform graphics so fullscreen would be very, very slow. also, i'm not sure how to use the graphics card via java.

edit: woohoo, slowdown is nonexistent. only problem is a few glitches with menu interaction now

163
Computer Projects and Ideas / Re: Juggernaut
« on: January 07, 2011, 11:24:25 pm »
so, i revamped the menu system and now it is more maintainable and extendable. however, in-game when you press pause then you press resume, there is a massive slowdown, which only gets worse the more times you pause then resume. i pressed ctrl+alt+del and noticed that my program is taking from 60-90% of the CPU, generally over 80%, which is very undesirable. i've yet to come across the culprit of the slowdown, but i believe it is that everytime i return to the game, there is a "savestate" of all the variables and flags, and they are all wastefully recreated. this is a problem for another day though.

164
TI-BASIC / Re: Word Encoding/Decoding
« on: January 07, 2011, 06:01:36 pm »
Code: [Select]
"_
For(A,1,dim(LW
For(B,1,.5+.5int(log(LW(A
Ans+sub("AaBbCcDdEeFfGgHhIiJjKkLlMmNnOoPpQqRrSsTtUuVvWwXxYyZzΘ0123456789",iPart(E2fPart(LW(A)/10^(2B))),1
End
End
sub(Ans,2,length(Ans)-1→Str1

i think this still works.. but it's late, and i'm tired, so i'm not completely sure.

i can't even read that anymore... i'm spoiled by java

and yeah holmes this could be used with some modification for a matrix.

165
Math and Science / Re: Formula for getting prime number?
« on: January 07, 2011, 04:35:07 pm »
oops O_o

Code: [Select]
boolean isPrime=true;
for(int k = 2 ; k < number ; k++)
{
if (number==2 || number/k == 0)
isPrime=false;
}

EDIT: Aww

no,
Code: [Select]
boolean isPrime=true;
for(int k = 2 ; k < number ; k++)
     if ( number/k == 0)
          isPrime=false;

works. 2 is not less than 2, so the loop skips and isPrime remains true anyway.

Pages: 1 ... 9 10 [11] 12 13 ... 82