add array manager and split the .h and .cpp