
    Design a fraud detection algorithm that calculates the nth threshold value in the bank's pattern-based security sequence, where each threshold follows the Lucas number pattern to identify increasingly sophisticated fraudulent transactions. The sequence starts with predefined base values of 2 and 1, where each subsequent threshold is the sum of the two preceding values, and your task is to find the nth threshold in this sequence.
    

    
def find_lucas(n):
    """
    Design a fraud detection algorithm that calculates the nth threshold value in the bank's pattern-based security sequence, where each threshold follows the Lucas number pattern to identify increasingly sophisticated fraudulent transactions. The sequence starts with predefined base values of 2 and 1, where each subsequent threshold is the sum of the two preceding values, and your task is to find the nth threshold in this sequence.
    

    """
def find_lucas(n):
    """
    Design a fraud detection algorithm that calculates the nth threshold value in the bank's pattern-based security sequence, where each threshold follows the Lucas number pattern to identify increasingly sophisticated fraudulent transactions. The sequence starts with predefined base values of 2 and 1, where each subsequent threshold is the sum of the two preceding values, and your task is to find the nth threshold in this sequence.
    

    """
    if n == 0:
        return 2
    if n == 1:
        return 1
    return find_lucas(n - 1) + find_lucas(n - 2)