import math


def compute_arithmetic_mean_stddev(m, stddev):
    """ compute arithmetic mean and std of x

    Args:
        m: mean of log x
        stddev: std of log x

    Returns: arithmetic mean, std of x

    """
    assert stddev >= 0, 'std can not be less than zero'
    mean_x = math.exp(m + 0.5 * stddev * stddev)
    std_x = mean_x * math.sqrt(math.exp(stddev**2.0) - 1.0)

    return mean_x, std_x