A compressible magnetohydrodynamic numerical code with time-dependent boundary conditions in cylindrical geometry