Polyphony originated in the halls of the Catholic Church as plainchant, or Gregorian chant. Plainchant involved simple unaccompanied chanting without any established rhythm in either medieval major or minor mode. Around 900 CE, the earliest type of polyphony started appearing as organum, in which the chant melody was sung along with an accompanying voice, usually below the original in an interval of either a fourth or fifth. In the eleventh century, the organum started becoming more complicated and flexible,