def P8_bitshiftleft1():
    p = Program()
    p.create_decrement_component()
    p.create_not_component()
    p.create_and_component()
    p.create_bitshiftleft_component(1)
    p.create_bitshiftleft_component(1)
    p.create_bitshiftleft_component(1)
    return ProgramSynthesis(p, BVT.P8, 'P8 BitShiftL1')
def alternative_increment():
    ps = []
    p = Program(num_prog_inputs=1)
    # p.create_increment_component()
    p.create_bitshiftleft_component(1)
    p.create_bitshiftright_component(1)
    p.create_ule_component()
    p.create_ult_component()
    p.create_bvredor_component()
    p.create_and_component()
    p.create_add_component()
    oracle = BVT.Psimple_inc
    ps_short = ProgramSynthesis(p, oracle, 'P Simple')
    ps_short.find_shortest_program = True
    ps.append(ps_short)
    return ps
def shortestComparison_P14():
    ps = []
    p = Program(num_prog_inputs=2)
    p.create_bitshiftleft_component(-1)
    p.create_increment_component()
    p.create_subtract_component()
    p.create_and_component()
    p.create_divide_component()
    p.create_xor_component()
    oracle = BVT.P14
    ps_short = ProgramSynthesis(p, oracle, 'Shortest')
    ps_short.find_shortest_program = True
    ps.append(ps_short)
    ps_no_short = ProgramSynthesis(p, oracle, 'No Shortest')
    ps_no_short.find_shortest_program = False
    ps.append(ps_no_short)
    return ps