#DEFINITIONS: -*-sh-*- # # Demonstrates amd tests rotation of the Stokes vector as a function of scan # angle. The cfile also shows how an atmosphere completly lacking attenuation # can be generated. # # Authors: Patrick Eriksson Arts2 { INCLUDE "general/general.arts" INCLUDE "general/agendas.arts" INCLUDE "general/planet_earth.arts" # cosmic background radiation Copy( iy_space_agenda, iy_space_agenda__CosmicBackground ) # standard surface agenda (i.e., make use of surface_rtprop_agenda) Copy( iy_surface_agenda, iy_surface_agenda__UseSurfaceRtprop ) # Planck as blackbody radiation Copy( blackbody_radiation_agenda, blackbody_radiation_agenda__Planck ) # sensor-only path Copy( ppath_agenda, ppath_agenda__FollowSensorLosPath ) # no refraction Copy( ppath_step_agenda, ppath_step_agenda__GeometricPath ) # (standard) emission calculation Copy( iy_main_agenda, iy_main_agenda__Emission ) # Clearsky = No scattering cloudboxOff # No jacobian calculation jacobianOff # A dummy, empty atmosphere # abs_speciesSet( species=[] ) AgendaSet( propmat_clearsky_agenda ){ Ignore( rtp_mag ) Ignore( rtp_los ) Ignore( rtp_pressure ) Ignore( rtp_temperature ) Ignore( rtp_vmr ) propmat_clearskyZero } # AtmosphereSet1D VectorNLogSpace( p_grid, 2, 1013e2, 100e2 ) AtmRawRead( t_field_raw, z_field_raw, vmr_field_raw, abs_species, "testdata/tropical" ) AtmFieldsCalc Extract( z_surface, z_field, 0 ) Extract( t_surface, t_field, 0 ) # Number of Stokes components to be computed # IndexSet( stokes_dim, 4 ) # A single frequency # VectorSet( f_grid, [ 30e9 ] ) # Set surface to be flat water # VectorCreate(data_f_grid) VectorCreate(data_T_grid) VectorNLinSpace( data_f_grid, 10, 10e9, 100e9 ) VectorNLinSpace( data_T_grid, 5, 270, 310 ) complex_refr_indexWaterLiebe93( surface_complex_refr_index, data_f_grid, data_T_grid ) AgendaSet( surface_rtprop_agenda ){ specular_losCalc InterpSurfaceFieldToPosition( out=surface_skin_t, field=t_surface ) surfaceFlatRefractiveIndex } # Rayleigh-Jeans brightness temperatures # StringSet( iy_unit, "RJBT" ) # Create a small across-track scanning sequence as one mblock # # We take nadir as reference for our angles. # It is allowed that sensor_los+mblock_grid is > 180, this is automatically # mapped to a correct angle. # MatrixSet( sensor_pos, [800e3] ) MatrixSet( sensor_los, [180] ) # VectorCreate( angles ) VectorNLinSpace( angles, 5, 0, 60 ) IndexCreate( nang ) nelemGet( nang, angles ) # IndexSet( sensor_norm, 1 ) # Here just a dummy value AntennaOff # Simplest way to set some dummy variables # Copy( mblock_za_grid, angles ) # Perform basic checks atmfields_checkedCalc atmgeom_checkedCalc cloudbox_checkedCalc # Perform RT calculations, with no rotation # sensor_responseInit sensor_checkedCalc yCalc #Print(y) # Perform RT calculations, with rotation following scan angle # (rotation angle here set to 50% of angle from nadir!) Matrix1ColFromVector( stokes_rotation, angles ) MatrixScale( stokes_rotation, stokes_rotation, 0.5 ) # sensor_responseInit sensor_responseStokesRotation sensor_checkedCalc yCalc #Print(y) # Check last results VectorCreate( yref ) VectorSet( yref, [127.654,0,0,0,127.694,3.970,-1.056,0,128.398,15.195,-8.77282, 0,132.644,32.479,-32.479,0,154.624,58.901,-102.019,0]) Compare( y, yref, 0.05 ) }