fix #4
fix #4
fix #5
fix #5
fix #6
fix #8
finish #8