Post subject: Boring math crap
Banned User, Former player
Joined: 12/23/2004
Posts: 1850
*004920> <Xkeeper> given possible denominations of 4, 8, 12, 16, 24, 32, 48, and 64 *004948> <Xkeeper> and a notes/measure *004955> <Xkeeper> I need to determine what kind of note goes where *005002> <Xkeeper> i.e., if a measure is "0 0 0 0", it'd be all 4th *005013> <Xkeeper> if it was "0 0 0 0 0 0 0 0", it'd be 4 8 4 8 4 8 4 8 *005028> <Xkeeper> then for 16 , 4 16 8 16 4 16 8 16 etc. *005138> <Tompala> Huh *005158> <Xkeeper> etc up to 64 *005207> <Xkeeper> but I have no idea how to do it and I've been frustrated for quite a while The possible "0s per measure" (for example) can go as high as 192 (a mix of 64th and 48th) I've really, really tried quite hard to get this right and so far nothing (outside of a stupid 192-row lookup table) has worked... and even then that wouldn't work either, since I'd have to have a sperate one for each possible "rows/measure" value, argh...
Perma-banned
Joined: 10/24/2005
Posts: 1080
Location: San Jose
Let's just say that xkeeper solved it. I came up with my own solution: https://webfiles.berkeley.edu/DK64_MASTER/shared/xkeep.doc The key was to find the repeated string and see how it is based off of previous values... (recursive, of course) Here's the iterative solution for finding correct values of the repeated string (repeated 4 times) Given n is your number of notes Start off with "4 8", interleave 16s, interleave 32s, interleave 64s.... interleave ns.
<agill> banana banana banana terracotta pie! <Shinryuu> ho-la terracotta barba-ra anal-o~
Joined: 2/12/2006
Posts: 432
I have no clue what that means. Perhaps you could rephrase it?
Player (36)
Joined: 9/11/2004
Posts: 2624
What about the 12ths, 24ths, and 48ths?
Build a man a fire, warm him for a day, Set a man on fire, warm him for the rest of his life.
Player (70)
Joined: 8/24/2004
Posts: 2562
Location: Sweden
Me and my friend were puzzled about the equation in the Weird al Yankovic's video "White and nerdy". The equation can be found at wikipedia: http://en.wikipedia.org/wiki/White_and_nerdy The "correct" (as they put it) equation should be the Dirac's Constant, but the theory of a friend of mine and me is that if this equation can be calculated at all, it's result will be 27, which happens to be a reccuring joke without any special logic throughout his videos, or something else which might be connected to our hero. Would be awesome if any of you guys/gals could give us the answer to this (if one can be given). :) Cheers!
Banned User, Former player
Joined: 12/23/2004
Posts: 1850
OmnipotentEntity wrote:
What about the 12ths, 24ths, and 48ths?
I figured out a solution to fix those:
		$noteval	= array(
			4, 8, 12, 16, 24, 32, 48, 64
			);

		foreach ($noteval as $noteskip) {
			for ($i = 0; $i < $noteskip; $i++) {
				$num	= ($i / $noteskip) * 192;
				$num	= floor($num);
				if (!$notelookup3[$num]) $notelookup3[$num] = $noteskip;
			}
		}
Suprisingly useful :) There's another lookup table to translate "4 -> noteimage 1", and any non-marked one defaults to 0, or "192nd note". I tried it out and it worked flawlessly, though there are many ways it could be improved ^^
Perma-banned