add the code & tests of phase4
add the code & tests of phase1
Revert "add the code & tests of phase4"

This reverts commit 336d8bfc02c7a75697958e99cd6caad0c7d39bcb.
Revert "Revert "add the code & tests of phase4""

This reverts commit c9d58800eaae9adf89c3ce4096777f78f8f30e57.
add Communicator selfTest