added some comments
added .pdf flowchart