二十四山èr shí sì shān
Feng shui
The 24 compass directions, three to each of the eight palaces: 壬子癸 belong to 坎 (north), 丙午丁 to 离 (south), and so on. A year spirit's branch is placed on the compass this way.
Source
戌乾亥屬乾壬子癸屬坎丑艮寅屬艮甲卯乙屬震辰巽巳屬巽丙午丁屬離未坤申屬坤庚酉辛屬兌謂之八宫
欽定協紀辨方書 · 卷二·二十四山
Example chart
乙卯 甲申 癸巳 丁巳
The year, month, day and hour pillars, in that order.