A study on dynamic processes at late stages in the formation of planetary systems in gas and dust disks