```python
def harmonic_sum(n):
    """
    Calculates the harmonic sum of n-1.

    The harmonic sum of k is the sum of the reciprocals of the positive integers
    from 1 to k. H_k = 1 + 1/2 + 1/3 + ... + 1/k.

    This function calculates H_{n-1}.

    Args:
        n: An integer. The calculation goes up to n-1.

    Returns:
        The harmonic sum of n-1 as a float. If n <= 1, the sum is 0.
    """
    if n <= 1:
        return 0.0
    
    total = 0.0
    for i in range(1, n):
        total += 1 / i
        
    return total

```