A Linear Time Solution to the Partition Problem in a Cellular Tissue-Like Model