<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def calc_glmelt_in_v1(self):
 """Calculate melting from glaciers which are actually not covered by a snow layer and add it to the water release of the snow module. Required control parameters: |NmbZones| |ZoneType| |GMelt| Required state sequence: |SP| Required flux sequence: |TC| Calculated fluxes sequence: |GlMelt| Updated flux sequence: |In_| Basic equation: :math:`GlMelt = \\Bigl \\lbrace { {max(GMelt \\cdot (TC-TTM), 0) \\ | \\ SP = 0} \\atop {0 \\ | \\ SP > 0} }` Examples: Seven zones are prepared, but glacier melting occurs only in the fourth one, as the first three zones are no glaciers, the fifth zone is covered by a snow layer and the actual temperature of the last two zones is not above the threshold temperature: glmelt(0.0, 0.0, 0.0, 2.0, 0.0, 0.0, 0.0) in_(3.0, 3.0, 3.0, 5.0, 3.0, 3.0, 3.0) Note that the assumed length of the simulation step is only a half day. Hence the effective value of the degree day factor is not 4 but 2: gmelt(4.0) array([ 2., 2., 2., 2., 2., 2., 2.]) """

    con = self.parameters.control.fastaccess
    der = self.parameters.derived.fastaccess
    flu = self.sequences.fluxes.fastaccess
    sta = self.sequences.states.fastaccess
    for k in range(con.nmbzones):
        if ((con.zonetype[k] == GLACIER) and
                (sta.sp[k] <= 0.) and (flu.tc[k] > der.ttm[k])):
            flu.glmelt[k] = con.gmelt[k]*(flu.tc[k]-der.ttm[k])
            flu.in_[k] += flu.glmelt[k]
        else:
            flu.glmelt[k] = 0.