velocity[1,gi,gj,0,ie] = - 2*pi*sin(lon)*sin(alpha) ''' """ #---------------------------------------------- # spectral element #---------------------------------------------- interact = InteractBetweenElems() inside = InsideElems(N, ngll, nelem, state, interact) # minimum dx, dt max_v = 2*pi dt = cfl*min_dx/max_v tloop = RungeKutta(dt, inside) tloop.allocate(state.psi.shape, state.psi.dtype) #---------------------------------------------- # print the setup information #---------------------------------------------- print '-'*47 print 'N\t\t', N print 'ngll\t\t', ngll print 'nelem\t\t', nelem print 'cfl\t\t', cfl print 'min_dx\t\t', min_dx print 'dt\t\t', dt #tmax = int( numpy.ceil(1/dt) ) tmax = 10