def trivial_forecast(submodel, horizon):
    """Computing the forecast for the trivial models

    """
    points = []
    submodel_points = submodel['value']
    period = len(submodel_points)
    if period > 1:
        for h in range(horizon):
            points.append(submodel_points[h % period])
    else:
        for _ in range(horizon):
            points.append(submodel_points[0])
    return points
