What's new

I need some Maths help

Ten_Tacles

Level 42
Jul 5, 2010
991
0
Credits
18,110
Points
0
I want to Calculate Tacle Spires by inserting one of four parts of them.



The "Level" of a Spire (Amount of different sized layers, usually from 1 to 15).

The Height of a Spire.

The Basesize (length of the lowest/biggest layer).

And the Amount of Blocks needed to create it.



For now, I can calculate everything using the Level and the Basesize.

But now I fail at using the Height.



Y = ((X+1)/2)*X



This is the formula for Height, where is Y is Height and X is Level.

But now I need to get the Level using the Height.





You can control it with this list:

Level = Height

1 = 1

2 = 3

3 = 6

4 = 10

5 = 15

6 = 21

and so on.
 

The Noodle

Level 48
Aug 1, 2010
1,755
2
Credits
22,850
Points
0
2y - x = x^2

sqrt(2y - x) = x

eh, thats as far as I got before thinking realising i'm probably going in the wrong direction.
 

Ten_Tacles

Level 42
Jul 5, 2010
991
0
Credits
18,110
Points
0
Thanks to Bildramer on the Minecraft Irc, I finally have it solved!

I can now calculate all four Spire attributes using Level, Basesize and Height!

Only Amount of Blocks may be a problem though.



for(int i=0; i < Level; i++) {

Blockamount = Blockamount + (((Basesize-(i*2))*(Basesize-(i*2)))*(i+1));

}

That is what I use for calculation the needed Blocks.

I haven't got as far as even turning it into a formula, and I fear it is not possible, because it uses 2 other attributes.
 
Top