For the problems existing in current frequent episode mining with minimal occurrences, the paper proposes a method of discovering distinct minimal occurrences and counting them. On this basis, an episode matrix and frequent episode tree based mining method is proposed, which only scans event sequences once based on the idea of direct extension without candidate generation and enhances space-time efficiency. Moreover, its optimization is presented based on same node chains and hash chains, which improves the mining performance further by omitting the extension process of same nodes. A series of experiments on different types of real data sets show the advantage of the proposed method, and validate the effectiveness and efficiency of the optimization method.