Matriz do Tzolkin

[insert_php]
$calc1 = array(-14 => 8, -13 => 113, -12 => 218, -11 => 63, -10 => 168, -9 => 13, -8 => 118, -7 => 223, -6 => 68, -5 => 173, -4 => 18, -3 => 123, -2 => 228, -1 => 73, 0 => 178, 1 => 23, 2 => 128, 3 => 233, 4 => 78, 5 => 183, 6 => 28, 7 => 133, 8 => 238, 9 => 83, 10 => 188, 11 => 33, 12 => 138, 13 => 243, 14 => 88, 15 => 193, 16 => 38, 17 => 143, 18 => 248, 19 => 93, 20 => 198, 21 => 43, 22 => 148, 23 => 253, 24 => 98, 25 => 203, 26 => 48, 27 => 153, 28 => 258, 29 => 103, 30 => 208, 31 => 53, 32 => 158, 33 => 3, 34 => 108, 35 => 213, 36 => 58, 37 => 163); $calc2 = array (0, 54, 85, 113, 144, 174, 205, 0, 6, 37, 67, 98, 128); $portais = array(1, 20, 22, 39, 43, 50, 51, 58, 64, 69, 72, 77, 85, 88, 93, 96, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 146, 147, 148, 149, 150, 151, 152, 153, 154, 155, 165, 168, 173, 176, 184, 189, 192, 197, 203, 210, 211, 218, 222, 239, 241, 260);

$tons = array(
1 => array(“Magnético”, “Magnética”, “magnetico”),
2 => array(“Lunar”, “Lunar”, “lunar”),
3 => array(“Elétrico”, “Elétrica”, “eletrico”),
4 => array(“Autoexistente”, “Autoexistente”, “autoexistente”),
5 => array(“Harmônico”, “Harmônica”, “harmonico”),
6 => array(“Rítmico”, “Rítmica”, “ritmico”),
7 => array(“Ressonante”, “Ressonante”, “ressonante”),
8 => array(“Galáctico”, “Galáctica”, “galactico”),
9 => array(“Solar”, “Solar”, “solar”),
10 => array(“Planetário”, “Planetária”, “planetario”),
11 => array(“Espectral”, “Espectral”, “espectral”),
12 => array(“Cristal”, “Cristal”, “cristal”),
13 => array(“Cósmico”, “Cósmica”, “cosmico”));

$selos = array(
1 => array(“Dragão”, “Vermelho”, “o”, “dragao”),
2 => array(“Vento”, “Branco”, “o”, “vento”),
3 => array(“Noite”, “Azul”, “a”, “noite”),
4 => array(“Semente”, “Amarela”, “a”, “semente”),
5 => array(“Serpente”, “Vermelha”, “a”, “serpente”),
6 => array(“Enlaçador de Mundos”, “Branco”, “o”, “enlacador-de-mundos”),
7 => array(“Mão”, “Azul”, “a”, “mao”),
8 => array(“Estrela”, “Amarela”, “a”, “estrela”),
9 => array(“Lua”, “Vermelha”, “a”, “lua”),
10 => array(“Cachorro”, “Branco”, “o”, “cachorro”),
11 => array(“Macaco”, “Azul”, “o”, “macaco”),
12 => array(“Humano”, “Amarelo”, “o”, “humano”),
13 => array(“Caminhante do Céu”, “Vermelho”, “o”, “caminhante-do-ceu”),
14 => array(“Mago”, “Branco”, “o”, “mago”),
15 => array(“Águia”, “Azul”, “a”, “aguia”),
16 => array(“Guerreiro”, “Amarelo”, “o”, “guerreiro”),
17 => array(“Terra”, “Vermelha”, “a”, “terra”),
18 => array(“Espelho”, “Branco”, “o”, “espelho”),
19 => array(“Tormenta”, “Azul”, “a”, “tormenta”),
20 => array(“Sol”, “Amarelo”, “o”, “sol”));

$view = $_GET[“view”];
$kin = $_GET[“kin”];

if ($kin > 260 || $kin < 1) { $validKin = false; } else { $validKin = true; } if (!$kin || !$validKin) { # PARÂMETROS DE HOJE date_default_timezone_set('America/Sao_Paulo'); $day = date("d"); $month = date("m"); $year = date("Y"); if ($month < 10) { $month = ltrim($month, '0'); } # GREGORIANO -> KIN
$var = $year;
while ($var > 37) {
$var-= 52;
}
$kin = $day + $calc1[$var] + $calc2[$month];
if ($month == 7) {
if ($day < 26) { $kin += 235; } else { $calc2 += -25; } } if ($kin > 260) { $kin -= 260; }
}
# SETA SELO
$numSelo = $kin; while ($numSelo > 20) { $numSelo -= 20; }
# SETA TOM
$numTom = $kin; while ($numTom > 13) { $numTom -= 13; }
# SELO É FEMININO?
if ($numSelo == 3 || $numSelo == 4 || $numSelo == 5 || $numSelo == 7 || $numSelo == 8 || $numSelo == 9 || $numSelo == 15 || $numSelo == 17 || $numSelo == 19) { $femaleSeal = true; }
# KIN É PORTAL?
for ($i = 0; $i < 52; $i++) { if ($kin == $portais[$i]) { $kinGap = true; break; } } $kinCount = 1; $sealCount = 1; $toneCount = 1; # STRING DO TZOLKIN for ($numR = 0; $numR <= 20; $numR++) { $tzolkin .= ' ‘;
for ($numD = 0; $numD <= 13; $numD++) { $tzolkin .= '

‘;
}
else if ($numD == 0) {
$tzolkin .= ‘st-info”>

‘;
}
else {
// KIN
if ($numD == 1 && $numR == 1) { $kinCount = 1; }
else { $kinCount += 20; if ($kinCount > 260) { $kinCount = $kinCount – 260 + 1; } }
// SELO
$sealCount = $kinCount;
while ($sealCount > 20) { $sealCount -= 20; }
// TOM
$toneCount = $kinCount;
while ($toneCount > 13) { $toneCount -= 13; }
// ONDA
$waveCount = $kinCount;
if ($kinCount <= 13) { $waveCount = 1; } else { $waveCount = ($kinCount - $toneCount) / 13 + 1; } // CROMÁTICAS if (($sealCount >= 1 && $sealCount <= 4) || $sealCount == 20) { $chroCount = 4; } else if ($sealCount >= 5 && $sealCount <= 9) { $chroCount = 1; } else if ($sealCount >= 10 && $sealCount <= 14) { $chroCount = 2; } else { $chroCount = 3; } // CÉLULAS if ($sealCount >= 1 && $sealCount <= 4) { $cellCount = 1; } else if ($sealCount >= 5 && $sealCount <= 8) { $cellCount = 2; } else if ($sealCount >= 9 && $sealCount <= 12) { $cellCount = 3; } else if ($sealCount >= 13 && $sealCount <= 16) { $cellCount = 4; } else { $cellCount = 5; } // CASTELOS if ($kinCount <= 52) { $castCount = 1; } else if ($kinCount <= 104) { $castCount = 2; } else if ($kinCount <= 156) { $castCount = 3; } else if ($kinCount <= 208) { $castCount = 4; } else { $castCount = 5; } // ESTAÇÕES if ($kinCount <= 54) { $seasCount = 2; } else if ($kinCount <= 119) { $seasCount = 3; } else if ($kinCount <= 184) { $seasCount = 4; } else if ($kinCount <= 249) { $seasCount = 1; } else { $seasCount = 2; } if ($view == "wave") { $color = $waveCount; while ($color > 4) { $color -= 4; }
}
else if ($view == “cell”) {
$color = $cellCount;
}
else if ($view == “castle”) {
$color = $castCount;
}
else if ($view == “season”) {
$color = $seasCount;
}
else if ($view == “chrom”) {
$color = $chroCount;
}
else {
$color = $sealCount; while ($color > 4) { $color -= 4; }
$gap = false;
for ($i = 0; $i < 52; $i++) { if ($kinCount == $portais[$i]) { $gap = true; break; } } if ($gap) { $color = 5; } } $tzolkin .= 'color' . $color; if ($kin == $kinCount) { $tzolkin .= ' selected-kin'; } $tzolkin .= '">‘ . $kinCount . ‘

‘;
}
}
else {
$tzolkin .= ‘”>

‘;
}
}
$tzolkin .= ‘

‘;
}

# RESULTADO
echo ‘

Tzolkin

Visualizar:

‘ . $tzolkin . ‘

A matriz do Tzolkin é ainda melhor usando o seu celular na horizontal ????

Kin ‘ . $kin . ‘ – ‘ . $selos[$numSelo][0] . ‘ ‘;
if (!$femaleSeal) { echo $tons[$numTom][0]; }
else { echo $tons[$numTom][1]; }
echo ‘ ‘ . $selos[$numSelo][1] . ‘


Os 20 Selos SolaresOs 13 Tons GalácticosSobre o TzolkinCiclos do Tempo

‘;
[/insert_php]