def lemma_8_3_3_generalized(scalars, vectors):
    """
    Demonstrates that if v1... vn are mutually orthogonal that for any coefficients a1.... an
    ||a1 * v1 + ... + an * vn||^2 == a1^2 * ||v1||^2 + ... + an^2 * ||vn||^2
    :param scalars: n length list of scalars
    :param vectors: n length list of m vectors
    :return: 2-tuple with each side of description equation
    >>> scalars = [2, 3]
    >>> vectors = [list2vec([1, 0]), list2vec([0, 1])]
    >>> result = lemma_8_3_3_generalized(scalars, vectors)
    >>> result[0] == result[1]
    True
    >>> scalars2 = [2, 3]
    >>> vectors2 = [list2vec([1, 1]), list2vec([0, 1])] # not orthogonal
    >>> result = lemma_8_3_3_generalized(scalars2, vectors2)
    >>> result[0] != result[1]
    True
    >>> scalars3 = [2, 3, 4]
    >>> vectors3 = [list2vec([1, 0, 0]), list2vec([0, 1, 0]), list2vec([0, 0, 1])]
    >>> result = lemma_8_3_3_generalized(scalars3, vectors3)
    >>> result[0] == result[1]
    True
    >>> scalars4 = [2, 3, 4]
    >>> vectors4 = [list2vec([1, 0, 1]), list2vec([0, 1, 0]), list2vec([0, 0, 1])] # not orthogonal
    >>> result = lemma_8_3_3_generalized(scalars4, vectors4)
    >>> result[0] != result[1]
    True
    """
    t1 = sum([(s * v) for s, v in zip(scalars, vectors)])
    t1 *= t1 # because the Vec clas does not have the 'pow' operator implemented
    t2 = sum([s**2 * ((v*v)**(1/2))**2 for s, v in zip(scalars, vectors)])
    return t1, t2