<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def to_array(self, normalization=None, csphase=None, lmax=None):
 """ Return spherical harmonic coefficients as a numpy array. Usage ----- coeffs = x.to_array([normalization, csphase, lmax]) Returns ------- coeffs : ndarry, shape (2, lmax+1, lmax+1) numpy ndarray of the spherical harmonic coefficients. Parameters normalization : str, optional, default = x.normalization Normalization of the output coefficients: '4pi', 'ortho', 'schmidt', or 'unnorm' for geodesy 4pi normalized, orthonormalized, Schmidt semi-normalized, or unnormalized coefficients, respectively. csphase : int, optional, default = x.csphase Condon-Shortley phase convention: 1 to exclude the phase factor, or -1 to include it. lmax : int, optional, default = x.lmax Maximum spherical harmonic degree to output. If lmax is greater than x.lmax, the array will be zero padded. Description This method will return an array of the spherical harmonic coefficients using a different normalization and Condon-Shortley phase convention, and a different maximum spherical harmonic degree. If the maximum degree is smaller than the maximum degree of the class instance, the coefficients will be truncated. Conversely, if this degree is larger than the maximum degree of the class instance, the output array will be zero padded. """

        if normalization is None:
            normalization = self.normalization
        if csphase is None:
            csphase = self.csphase
        if lmax is None:
            lmax = self.lmax

        coeffs = _convert(self.coeffs, normalization_in=self.normalization,
                          normalization_out=normalization,
                          csphase_in=self.csphase, csphase_out=csphase,
                          lmax=lmax)

        return coeffs