implemented protodomain related subroutines
Updated the matlab command to prevent error when simulated in Mac OS X