added dynamic parallel array merge and tests