Heuristic approach to circuit sizing problem