diff --git a/ngehtsim/const_def.py b/ngehtsim/const_def.py index 9cee50cc2..ef24821ab 100755 --- a/ngehtsim/const_def.py +++ b/ngehtsim/const_def.py @@ -76,6 +76,13 @@ # default feed angle, if not otherwise known feed_angle = 0.0 +# default polarization basis, if not otherwise known +pol_basis = 'circular' + +# polarization basis conversion matrices +circ_to_lin = np.array([[1.0,1.0],[-1.0j,1.0j]])/np.sqrt(2.0) +lin_to_circ = np.array([[1.0,1.0j],[1.0,-1.0j]])/np.sqrt(2.0) + ################################################### # physical constants @@ -354,12 +361,12 @@ ################################################### # pull antenna properties from table -known_stations, tlcs, diam_arr, surf_arr, mnts_arr, fa_arr, altnames = np.loadtxt(path_to_tsm, - delimiter=',', - skiprows=1, - usecols=(0, 1, 7, 8, 9, 10, 11), - dtype=str, - unpack=True) +known_stations, tlcs, diam_arr, surf_arr, polbasis_arr, mnts_arr, fa_arr, altnames = np.loadtxt(path_to_tsm, + delimiter=',', + skiprows=1, + usecols=(0, 1, 7, 8, 9, 10, 11, 12), + dtype=str, + unpack=True) lat_arr, lon_arr, elev_arr = np.loadtxt(path_to_tsm, delimiter=',', skiprows=1, @@ -391,6 +398,11 @@ if (elev_arr[i] != ''): known_elevations[known_stations[i]] = elev_arr[i] +known_polbases = {} +for i in range(len(known_stations)): + if (polbasis_arr[i] != ''): + known_polbases[known_stations[i]] = polbasis_arr[i] + known_mount_types = {} for i in range(len(known_stations)): if (mnts_arr[i] != ''): diff --git a/ngehtsim/files/Telescope_Site_Matrix.csv b/ngehtsim/files/Telescope_Site_Matrix.csv index 84a458e3a..bcde9202a 100644 --- a/ngehtsim/files/Telescope_Site_Matrix.csv +++ b/ngehtsim/files/Telescope_Site_Matrix.csv @@ -1,113 +1,113 @@ -Name,Two_letter_code,Country,Latitude,Longitude,Elevation,Notes,Diameter,RMS_surf_err,Mount_type,Feed_angles,Alternative_names -ALMA,AA,Chile,-23.03217,-67.75536,5043,Atacama Large Millimeter/submillimeter Array,75,25,ALT-AZ,0, -APEX,AP,Chile,-23.00572,-67.75928,5061,Atacama Pathfinder Experiment,12,25,ALT-AZ+NASMYTH-R,0, -GLT,GL,Greenland,76.535087,-68.685908,67,Greenland Telescope,12,50,ALT-AZ,0, -IRAM,PV,Spain,37.066145,-3.392597,2864,IRAM 30-meter telescope,30,55,ALT-AZ+NASMYTH-L,0,IRAM-30m; PV -JCMT,JC,US,19.82293,-155.47709,4074,James Clerk Maxwell Telescope,15,24,ALT-AZ,0, -KP,KP,US,31.953279,-111.614806,1927,ARO 12-meter radio telescope located on Kitt Peak,12,16,ALT-AZ,0, -LMT,LM,Mexico,18.98575,-97.31481,4618,Large Millimeter Telescope,50,80,ALT-AZ+NASMYTH-L,0, -NOEMA,PB,France,44.63366,5.90669,2554,Northern Extended Millimeter Array,50,35,ALT-AZ,0,PDB -SMA,SM,US,19.8241,-155.47823,4075,Submillimeter Array,15,20,ALT-AZ+NASMYTH-L,45, -SMT,AZ,US,32.7016,-109.8913,3173,Submillimeter Telescope,10,15,ALT-AZ+NASMYTH-R,0, -SPT,SP,Antarctica,-90,45,2820,South Pole Telescope,10,25,ALT-AZ,0, -ALI,AL,China,32.305711,80.045628,5405,summit of a minor peak at the top of a trail located in Gar County Tibet,,,,, -ATCA,AT,Australia,-30.312912,149.56445,212,Australia Telescope Compact Array,54,200,ALT-AZ,0, -BAJA,BA,Mexico,31.043898,-115.463636,2802,National Astronomical Observatory of Mexico in San Pedro Martir,,,,,SPM -BAN,BN,Canada,51.350366,-116.206317,3473,summit of Mount Temple in Banff,,,,, -BAR,BR,US,37.633996,-118.255716,4342,White Mountain Research Station summit observatory near Mount Barcroft,,,,, -BGA,BG,Bulgaria,41.695234,24.738929,1732,Rozhen National Astronomical Observatory,,,,, -BGK,BK,Iceland,66.032485,-23.05252,827,minor ridge near Sudavik in Westfjords,,,,, -BLDR,BL,US,39.58838,-105.6434,4337,summit of Mount Evans,,,,, -BMAC,BM,South Africa,-30.648081,27.935199,3000,summit of Ben Macdhui,,,,, -BOL,BO,Bolivia,-16.35075,-68.1314,5227,near the summit of Chacaltaya mountain,,,,, -BRZ,BZ,Brazil,-20.438965,-41.798766,2847,Pico da Bandeira,,,,, -CAS,CS,Argentina,-54.790173,-68.415421,1295,minor summit in the Martial Glacier mountain range near Ushuaia,,,,, -CAT,CA,Argentina,-41.169754,-71.486301,2097,summit of Cerro Catedral,,,,, -CNI,CI,Canary Islands,28.299309,-16.508709,2364,Teide Astronomical Observatory in the Canary Islands,,,,, -CTIO,CT,Chile,-30.1682,-70.80498,2172,Cerro Tololo Inter-American Observatory,,,,, -DomeA,DA,Antarctica,-80.366736,77.351258,4090,Dome Argus on the East Antarctic Ice Sheet,,,,, -DomeC,DC,Antarctica,-75.100503,123.34202,3230,Dome Concordia on the Antarctic Ice Sheet,,,,, -DomeF,DF,Antarctica,-77.316617,39.702097,3700,Dome Fuji on the East Antarctic Ice Sheet,,,,, -EFF,EB,Germany,50.52477,6.883635,393,Effelsberg,100,550,ALT-AZ,0, -ERB,ER,IQ,36.584237,44.465782,2111,site of the inactive Erbil Observatory,,,,, -FAIR,FA,US,64.988399,-147.598528,616,The Fox Range near Fairbanks,,,,, -FLWO,FL,US,31.675479,-110.951028,1274,Fred Lawrence Whipple Observatory,,,,,HOP -FUJI,FU,Japan,35.36652,138.729687,3748,Mount Fuji,,,,, -GAM,AM,Namibia,-23.3393,16.229246,2342,Gamsberg Mountain site considered for the Africa Millimeter Telescope,15,25,ALT-AZ,0, -GARS,GA,Antarctica,-63.320456,-57.895441,20,German Antarctic Receiving Stations at General Bernardo O'Higgins Base,,,,, -GBT,GB,US,38.433502,-79.83967,807,Green Bank Telescope,100,260,ALT-AZ,0, -GGAO,GG,US,39.02202151,-76.82730398,19,GGAO VGOS station,12,100,ALT-AZ,0,GGAO12M -GLTS,GS,Greenland,72.579967,-38.449163,3229,summit of the Greenland ice sheet,,,,,GLT-S -GOR,GO,Switzerland,45.983333,7.784793,3128,Gornergrat observation platform,,,,, -HAN,HN,India,32.779767,78.963318,4496,Indian Astronomical Observatory near the Hanle River,,,,, -HAY,HA,US,42.623943,-71.488769,114,Haystack Observatory,37,85,ALT-AZ,0, -HESS,HE,Namibia,-23.27154,16.5002,1900,HESS site considered for the Africa Millimeter Telescope,15,25,ALT-AZ,0,AMT -HIT,HT,Japan,36.69744,140.69211,120,Hitachi dish of the EAVN,32,1600,ALT-AZ,0,HIT32 -HOB,HB,Australia,-42.80556702,147.4381427,41,Hobart VGOS dish in Tasmania,12,100,ALT-AZ,0,HOBART12 -IRK,IR,Japan,31.74789,130.43989,574,Iriki dish of VERA,20,500,ALT-AZ,0, -ISG,IS,Japan,24.412167,124.171,65,Ishigakijima dish of VERA,20,500,ALT-AZ,0, -ISH,IH,Japan,36.20918915,140.2189587,164,Ishioka VGOS dish,13.2,100,ALT-AZ,0,ISHIOKA -JELM,JE,US,41.096991,-105.976692,2943,the summit of Jelm Mountain,,,,, -KATH,KE,Australia,-14.37545703,132.1523771,189,Katherine VGOS dish in Cossack,12,100,ALT-AZ,0,KATH12M -KEN,KN,Kenya,-0.141467,37.314792,4260,Shiptons mountain hut on Mount Kenya,,,,, -KILI,KI,Tanzania,-3.088055,37.405676,4433,the saddle region between Kibo and Mawenzi peaks of Mount Kilimanjaro,,,,, -KNM,KM,China,25.028,102.796,1974,Kunming dish of the EAVN,26,500,ALT-AZ,0,KMRT40 -KOKEE,K2,US,22.12644472,-159.6649188,1169,Kokee Park VGOS dish in Hawaii,12,100,ALT-AZ,0,KOKEE12M -KVNPC,KC,Korea,37.534119,128.449676,504,Korean VLBI Network Pyeongchang,21,70,ALT-AZ,0, -KVNTN,KT,Korea,33.289021,126.459573,411,Korean VLBI Network Tamna,21,70,ALT-AZ,0, -KVNUS,KU,Korea,35.54559,129.24915,128,Korean VLBI Network Ulsan,21,70,ALT-AZ,0, -KVNYS,KY,Korea,37.565159,126.941027,92,Korean VLBI Network Yonsei,21,70,ALT-AZ,0, -LAS,LA,Chile,-29.031711,-70.685063,2321,Las Campanas Observatory,,,,,LCO -LLA,LL,Argentina,-24.192081,-66.474786,4781,Large Latin American Millimeter Array,12,25,ALT-AZ,0, -LOS,LO,US,35.880473,-106.675016,2000,site of a shuttered gamma-ray observatory,,,,, -MACGO,MG,US,30.68031655,-104.0237118,1891,McDonald VGOS dish in Fort Davis,12,100,ALT-AZ,0,MACGO12M -MATJ,MA,South Africa,-33.266,20.582,1340,Matjiesfontein,,,,, -MET,MT,Finland,60.2178,24.39307,52,Metsähovi Radio Observatory,13.7,100,ALT-AZ,0, -MIZ,MZ,Japan,39.133528,141.132583,117,Mizusawa dish of VERA,20,500,ALT-AZ,0, -MOR,MR,Morocco,31.206771,-7.866164,2743,Cadi Ayyad University Space Science and Research Center near Marrakesh,,,,, -MUZ,MZ,China,38.330119,74.896783,4527,Muztag; developed summit of a minor peak located in Akto County China,,,,, -NAN,NS,China,43.471,87.17789,2029,Nanshan dish of the EAVN,26,400,ALT-AZ,0,NSRT26 -NOB,NB,Japan,35.944476,138.47246,1370,Nobeyama Radio Observatory,45,100,ALT-AZ,0, -NOR,NR,Japan,35.467583,136.737082,17,Gifu Observatory 11-meter radio dish,11,,,, -NYALE,NY,Norway,78.94337333,11.85476064,54,Ny-Alesund VGOS dish in Svalbard,13.2,100,ALT-AZ,0,NYALE13N -NZ,NZ,New Zealand,-43.986753,170.465097,1012,University of Canterbury Mount John Observatory,,,,, -OGA,OG,Japan,27.09181,142.21661,273,Ogasawara dish of VERA,20,500,ALT-AZ,0, -ONS,ON,Sweden,57.395819,11.926388,28,Onsala Space Observatory,20,128,ALT-AZ,0, -ONSNE,OE,Sweden,57.39361181,11.91975015,53,Onsala VGOS dish NE,13.2,100,ALT-AZ,0,ONSA13NE -ONSSW,OW,Sweden,57.39309313,11.91895566,53,Onsala VGOS dish SW,13.2,100,ALT-AZ,0,ONSA13SW -ORG,OR,US,42.635413,-118.576287,2971,summit of Steens Mountain,,,,, -OVRO,OV,US,37.231409,-118.282436,1207,Owens Valley Radio Observatory,10.4,40,ALT-AZ,0, -PAR,PR,Chile,-24.628155,-70.404142,2638,Paranal Observatory,,,,, -PIKE,PK,US,38.840837,-105.041792,4284,Pikes Peak,,,,,PIKES -ROT,RT,Armenia,40.352974,44.239865,1739,site of the inactive ROT54 radio telescope,,,,, -SAN,SN,US,34.099287,-116.824632,3502,summit of San Gorgonio mountain,,,,, -SGO,SG,Chile,-33.346151,-70.269859,3345,Cima Tres Puntas mountain peak,,,,, -SHE,SH,China,31.099167,121.199667,29,Sheshan dish of the EAVN,25,650,ALT-AZ,0,SHRT25 -SKS,SK,Greece,35.211771,24.898374,1743,Skinakas Observatory,,,,, -SMAR,SA,Portugal,36.98528526,-25.12589335,302,Santa Maria VGOS dish,13.2,100,ALT-AZ,0,RAEGSMAR -SPX,SX,Switzerland,46.54759,7.98526,3505,Sphinx Observatory,,,,, -STL,SL,South Africa,-32.378,20.813,1800,site of the South African Astronomical Observatory in Sutherland,,,,, -SUF,SF,Uzbekistan,39.62321,68.467537,2437,site of an unfinished Suffa RT-70 Soviet radio dish,,,,, -TAK,TK,Japan,36.69847,140.69472,117,Takahagi dish of the EAVN,32,1600,ALT-AZ,0,TAK32 -TNMA,TN,China,31.09211,121.135944,49,Tianma dish of the EAVN,65,300,ALT-AZ,0,TMRT65 -TRL,TR,Antarctica,-72.010456,2.536986,1275,site of the Norwegian research station Troll,,,,, -VLA,VL,US,34.079048,-107.618354,2123,Very Large Array,130,420,ALT-AZ,0,SOC -VLBBR,VB,US,48.1312,-119.68327,257,VLBA dish at Brewster in Washington,25,320,ALT-AZ,0, -VLBFD,VF,US,30.63499,-103.94485,1614,VLBA dish at Fort Davis in Texas,25,320,ALT-AZ,0, -VLBHN,VH,US,42.933592,-71.986636,309,VLBA dish at Hancock in New Hampshire,25,320,ALT-AZ,0, -VLBKP,VK,US,31.956327,-111.612423,1918,VLBA dish at Kitt Peak in Arizona,25,320,ALT-AZ,0, -VLBLA,VA,US,35.775122,-106.245605,1968,VLBA dish at Los Alamos in New Mexico,25,320,ALT-AZ,0, -VLBMK,VM,US,19.8015,-155.4556,3726,VLBA dish at Mauna Kea in Hawaii,25,320,ALT-AZ,0, -VLBNL,VN,US,41.77148,-91.57422,241,VLBA dish at North Liberty in Iowa,25,320,ALT-AZ,0, -VLBOV,VO,US,37.231652,-118.277053,1208,VLBA dish at Owens Valley in California,25,320,ALT-AZ,0, -VLBPT,VP,US,34.301002,-108.119211,2373,VLBA dish at Pie Town in New Mexico,25,320,ALT-AZ,0, -VLBSC,VS,US,17.75652,-64.58376,13,VLBA dish at St. Croix in the Virgin Islands,25,320,ALT-AZ,0, -WEST,WF,US,42.61294938,-71.49379868,87,Westford VGOS dish,18,100,ALT-AZ,0,WESTFORD -WETTZ,WS,Germany,49.14341883,12.87828553,673,Wettzell VGOS dish,13.2,100,ALT-AZ,0,WETTZ13S -XSMC,XS,China,37.971837,96.58383,4807,undeveloped plateau in Qinghai province Tibet,,,,, -YAM,YM,Japan,34.216028,131.55708,133,Yamaguchi dish of the EAVN,32,1600,ALT-AZ,0,YAM32 -YAN,YA,Peru,-13.938431,-74.391871,4232,site of the Future Infrared and Submillimeter Astronomical Observatory of Peru,,,,, -YBJ,YJ,China,30.104812,90.525583,4316,small developed town in Damxung County Tibet,,,,,YBG -YEB,YS,Spain,40.523472,-3.088497,917,Yebes Observatory RT40m,40,150,ALT-AZ,0, -YEBRG,YB,Spain,40.52347605,-3.088524547,977,Yebes Observatory VGOS dish,13.2,100,ALT-AZ,0,RAEGYEB -ZUG,ZG,Germany,47.416686,10.979614,2680,Schneefernerhaus research station on Zugspitze,,,,, \ No newline at end of file +Name,Two_letter_code,Country,Latitude,Longitude,Elevation,Notes,Diameter,RMS_surf_err,Polarization_basis,Mount_type,Feed_angles,Alternative_names +ALMA,AA,Chile,-23.03217,-67.75536,5043,Atacama Large Millimeter/submillimeter Array,75,25,linear,ALT-AZ,0, +APEX,AP,Chile,-23.00572,-67.75928,5061,Atacama Pathfinder Experiment,12,25,circular,ALT-AZ+NASMYTH-R,0, +GLT,GL,Greenland,76.535087,-68.685908,67,Greenland Telescope,12,50,circular,ALT-AZ,0, +IRAM,PV,Spain,37.066145,-3.392597,2864,IRAM 30-meter telescope,30,55,circular,ALT-AZ+NASMYTH-L,0,IRAM-30m; PV +JCMT,JC,US,19.82293,-155.47709,4074,James Clerk Maxwell Telescope,15,24,circular,ALT-AZ,0, +KP,KP,US,31.953279,-111.614806,1927,ARO 12-meter radio telescope located on Kitt Peak,12,16,circular,ALT-AZ,0, +LMT,LM,Mexico,18.98575,-97.31481,4618,Large Millimeter Telescope,50,80,circular,ALT-AZ+NASMYTH-L,0, +NOEMA,PB,France,44.63366,5.90669,2554,Northern Extended Millimeter Array,50,35,circular,ALT-AZ,0,PDB +SMA,SM,US,19.8241,-155.47823,4075,Submillimeter Array,15,20,circular,ALT-AZ+NASMYTH-L,45, +SMT,AZ,US,32.7016,-109.8913,3173,Submillimeter Telescope,10,15,circular,ALT-AZ+NASMYTH-R,0, +SPT,SP,Antarctica,-90,45,2820,South Pole Telescope,10,25,circular,ALT-AZ,0, +ALI,AL,China,32.305711,80.045628,5405,summit of a minor peak at the top of a trail located in Gar County Tibet,,,,,, +ATCA,AT,Australia,-30.312912,149.56445,212,Australia Telescope Compact Array,54,200,circular,ALT-AZ,0, +BAJA,BA,Mexico,31.043898,-115.463636,2802,National Astronomical Observatory of Mexico in San Pedro Martir,,,,,,SPM +BAN,BN,Canada,51.350366,-116.206317,3473,summit of Mount Temple in Banff,,,,,, +BAR,BR,US,37.633996,-118.255716,4342,White Mountain Research Station summit observatory near Mount Barcroft,,,,,, +BGA,BG,Bulgaria,41.695234,24.738929,1732,Rozhen National Astronomical Observatory,,,,,, +BGK,BK,Iceland,66.032485,-23.05252,827,minor ridge near Sudavik in Westfjords,,,,,, +BLDR,BL,US,39.58838,-105.6434,4337,summit of Mount Evans,,,,,, +BMAC,BM,South Africa,-30.648081,27.935199,3000,summit of Ben Macdhui,,,,,, +BOL,BO,Bolivia,-16.35075,-68.1314,5227,near the summit of Chacaltaya mountain,,,,,, +BRZ,BZ,Brazil,-20.438965,-41.798766,2847,Pico da Bandeira,,,,,, +CAS,CS,Argentina,-54.790173,-68.415421,1295,minor summit in the Martial Glacier mountain range near Ushuaia,,,,,, +CAT,CA,Argentina,-41.169754,-71.486301,2097,summit of Cerro Catedral,,,,,, +CNI,CI,Canary Islands,28.299309,-16.508709,2364,Teide Astronomical Observatory in the Canary Islands,,,,,, +CTIO,CT,Chile,-30.1682,-70.80498,2172,Cerro Tololo Inter-American Observatory,,,,,, +DomeA,DA,Antarctica,-80.366736,77.351258,4090,Dome Argus on the East Antarctic Ice Sheet,,,,,, +DomeC,DC,Antarctica,-75.100503,123.34202,3230,Dome Concordia on the Antarctic Ice Sheet,,,,,, +DomeF,DF,Antarctica,-77.316617,39.702097,3700,Dome Fuji on the East Antarctic Ice Sheet,,,,,, +EFF,EB,Germany,50.52477,6.883635,393,Effelsberg,100,550,circular,ALT-AZ,0, +ERB,ER,IQ,36.584237,44.465782,2111,site of the inactive Erbil Observatory,,,,,, +FAIR,FA,US,64.988399,-147.598528,616,The Fox Range near Fairbanks,,,,,, +FLWO,FL,US,31.675479,-110.951028,1274,Fred Lawrence Whipple Observatory,,,,,,HOP +FUJI,FU,Japan,35.36652,138.729687,3748,Mount Fuji,,,,,, +GAM,AM,Namibia,-23.3393,16.229246,2342,Gamsberg Mountain site considered for the Africa Millimeter Telescope,15,25,circular,ALT-AZ,0, +GARS,GA,Antarctica,-63.320456,-57.895441,20,German Antarctic Receiving Stations at General Bernardo O'Higgins Base,,,,,, +GBT,GB,US,38.433502,-79.83967,807,Green Bank Telescope,100,260,circular,ALT-AZ,0, +GGAO,GG,US,39.02202151,-76.82730398,19,GGAO VGOS station,12,100,linear,ALT-AZ,0,GGAO12M +GLTS,GS,Greenland,72.579967,-38.449163,3229,summit of the Greenland ice sheet,,,,,,GLT-S +GOR,GO,Switzerland,45.983333,7.784793,3128,Gornergrat observation platform,,,,,, +HAN,HN,India,32.779767,78.963318,4496,Indian Astronomical Observatory near the Hanle River,,,,,, +HAY,HA,US,42.623943,-71.488769,114,Haystack Observatory,37,85,circular,ALT-AZ,0, +HESS,HE,Namibia,-23.27154,16.5002,1900,HESS site considered for the Africa Millimeter Telescope,15,25,circular,ALT-AZ,0,AMT +HIT,HT,Japan,36.69744,140.69211,120,Hitachi dish of the EAVN,32,1600,circular,ALT-AZ,0,HIT32 +HOB,HB,Australia,-42.80556702,147.4381427,41,Hobart VGOS dish in Tasmania,12,100,linear,ALT-AZ,0,HOBART12 +IRK,IR,Japan,31.74789,130.43989,574,Iriki dish of VERA,20,500,circular,ALT-AZ,0, +ISG,IS,Japan,24.412167,124.171,65,Ishigakijima dish of VERA,20,500,circular,ALT-AZ,0, +ISH,IH,Japan,36.20918915,140.2189587,164,Ishioka VGOS dish,13.2,100,linear,ALT-AZ,0,ISHIOKA +JELM,JE,US,41.096991,-105.976692,2943,the summit of Jelm Mountain,,,,,, +KATH,KE,Australia,-14.37545703,132.1523771,189,Katherine VGOS dish in Cossack,12,100,linear,ALT-AZ,0,KATH12M +KEN,KN,Kenya,-0.141467,37.314792,4260,Shiptons mountain hut on Mount Kenya,,,,,, +KILI,KI,Tanzania,-3.088055,37.405676,4433,the saddle region between Kibo and Mawenzi peaks of Mount Kilimanjaro,,,,,, +KNM,KM,China,25.028,102.796,1974,Kunming dish of the EAVN,26,500,circular,ALT-AZ,0,KMRT40 +KOKEE,K2,US,22.12644472,-159.6649188,1169,Kokee Park VGOS dish in Hawaii,12,100,linear,ALT-AZ,0,KOKEE12M +KVNPC,KC,Korea,37.534119,128.449676,504,Korean VLBI Network Pyeongchang,21,70,circular,ALT-AZ,0, +KVNTN,KT,Korea,33.289021,126.459573,411,Korean VLBI Network Tamna,21,70,circular,ALT-AZ,0, +KVNUS,KU,Korea,35.54559,129.24915,128,Korean VLBI Network Ulsan,21,70,circular,ALT-AZ,0, +KVNYS,KY,Korea,37.565159,126.941027,92,Korean VLBI Network Yonsei,21,70,circular,ALT-AZ,0, +LAS,LA,Chile,-29.031711,-70.685063,2321,Las Campanas Observatory,,,,,,LCO +LLA,LL,Argentina,-24.192081,-66.474786,4781,Large Latin American Millimeter Array,12,25,circular,ALT-AZ,0, +LOS,LO,US,35.880473,-106.675016,2000,site of a shuttered gamma-ray observatory,,,,,, +MACGO,MG,US,30.68031655,-104.0237118,1891,McDonald VGOS dish in Fort Davis,12,100,linear,ALT-AZ,0,MACGO12M +MATJ,MA,South Africa,-33.266,20.582,1340,Matjiesfontein,,,,,, +MET,MT,Finland,60.2178,24.39307,52,Metsähovi Radio Observatory,13.7,100,circular,ALT-AZ,0, +MIZ,MZ,Japan,39.133528,141.132583,117,Mizusawa dish of VERA,20,500,circular,ALT-AZ,0, +MOR,MR,Morocco,31.206771,-7.866164,2743,Cadi Ayyad University Space Science and Research Center near Marrakesh,,,,,, +MUZ,MZ,China,38.330119,74.896783,4527,Muztag; developed summit of a minor peak located in Akto County China,,,,,, +NAN,NS,China,43.471,87.17789,2029,Nanshan dish of the EAVN,26,400,circular,ALT-AZ,0,NSRT26 +NOB,NB,Japan,35.944476,138.47246,1370,Nobeyama Radio Observatory,45,100,circular,ALT-AZ,0, +NOR,NR,Japan,35.467583,136.737082,17,Gifu Observatory 11-meter radio dish,11,,,,, +NYALE,NY,Norway,78.94337333,11.85476064,54,Ny-Alesund VGOS dish in Svalbard,13.2,100,linear,ALT-AZ,0,NYALE13N +NZ,NZ,New Zealand,-43.986753,170.465097,1012,University of Canterbury Mount John Observatory,,,,,, +OGA,OG,Japan,27.09181,142.21661,273,Ogasawara dish of VERA,20,500,circular,ALT-AZ,0, +ONS,ON,Sweden,57.395819,11.926388,28,Onsala Space Observatory,20,128,circular,ALT-AZ,0, +ONSNE,OE,Sweden,57.39361181,11.91975015,53,Onsala VGOS dish NE,13.2,100,linear,ALT-AZ,0,ONSA13NE +ONSSW,OW,Sweden,57.39309313,11.91895566,53,Onsala VGOS dish SW,13.2,100,linear,ALT-AZ,0,ONSA13SW +ORG,OR,US,42.635413,-118.576287,2971,summit of Steens Mountain,,,,,, +OVRO,OV,US,37.231409,-118.282436,1207,Owens Valley Radio Observatory,10.4,40,circular,ALT-AZ,0, +PAR,PR,Chile,-24.628155,-70.404142,2638,Paranal Observatory,,,,,, +PIKE,PK,US,38.840837,-105.041792,4284,Pikes Peak,,,,,,PIKES +ROT,RT,Armenia,40.352974,44.239865,1739,site of the inactive ROT54 radio telescope,,,,,, +SAN,SN,US,34.099287,-116.824632,3502,summit of San Gorgonio mountain,,,,,, +SGO,SG,Chile,-33.346151,-70.269859,3345,Cima Tres Puntas mountain peak,,,,,, +SHE,SH,China,31.099167,121.199667,29,Sheshan dish of the EAVN,25,650,circular,ALT-AZ,0,SHRT25 +SKS,SK,Greece,35.211771,24.898374,1743,Skinakas Observatory,,,,,, +SMAR,SA,Portugal,36.98528526,-25.12589335,302,Santa Maria VGOS dish,13.2,100,linear,ALT-AZ,0,RAEGSMAR +SPX,SX,Switzerland,46.54759,7.98526,3505,Sphinx Observatory,,,,,, +STL,SL,South Africa,-32.378,20.813,1800,site of the South African Astronomical Observatory in Sutherland,,,,,, +SUF,SF,Uzbekistan,39.62321,68.467537,2437,site of an unfinished Suffa RT-70 Soviet radio dish,,,,,, +TAK,TK,Japan,36.69847,140.69472,117,Takahagi dish of the EAVN,32,1600,circular,ALT-AZ,0,TAK32 +TNMA,TN,China,31.09211,121.135944,49,Tianma dish of the EAVN,65,300,circular,ALT-AZ,0,TMRT65 +TRL,TR,Antarctica,-72.010456,2.536986,1275,site of the Norwegian research station Troll,,,,,, +VLA,VL,US,34.079048,-107.618354,2123,Very Large Array,130,420,circular,ALT-AZ,0,SOC +VLBBR,VB,US,48.1312,-119.68327,257,VLBA dish at Brewster in Washington,25,320,circular,ALT-AZ,0, +VLBFD,VF,US,30.63499,-103.94485,1614,VLBA dish at Fort Davis in Texas,25,320,circular,ALT-AZ,0, +VLBHN,VH,US,42.933592,-71.986636,309,VLBA dish at Hancock in New Hampshire,25,320,circular,ALT-AZ,0, +VLBKP,VK,US,31.956327,-111.612423,1918,VLBA dish at Kitt Peak in Arizona,25,320,circular,ALT-AZ,0, +VLBLA,VA,US,35.775122,-106.245605,1968,VLBA dish at Los Alamos in New Mexico,25,320,circular,ALT-AZ,0, +VLBMK,VM,US,19.8015,-155.4556,3726,VLBA dish at Mauna Kea in Hawaii,25,320,circular,ALT-AZ,0, +VLBNL,VN,US,41.77148,-91.57422,241,VLBA dish at North Liberty in Iowa,25,320,circular,ALT-AZ,0, +VLBOV,VO,US,37.231652,-118.277053,1208,VLBA dish at Owens Valley in California,25,320,circular,ALT-AZ,0, +VLBPT,VP,US,34.301002,-108.119211,2373,VLBA dish at Pie Town in New Mexico,25,320,circular,ALT-AZ,0, +VLBSC,VS,US,17.75652,-64.58376,13,VLBA dish at St. Croix in the Virgin Islands,25,320,circular,ALT-AZ,0, +WEST,WF,US,42.61294938,-71.49379868,87,Westford VGOS dish,18,100,linear,ALT-AZ,0,WESTFORD +WETTZ,WS,Germany,49.14341883,12.87828553,673,Wettzell VGOS dish,13.2,100,linear,ALT-AZ,0,WETTZ13S +XSMC,XS,China,37.971837,96.58383,4807,undeveloped plateau in Qinghai province Tibet,,,,,, +YAM,YM,Japan,34.216028,131.55708,133,Yamaguchi dish of the EAVN,32,1600,circular,ALT-AZ,0,YAM32 +YAN,YA,Peru,-13.938431,-74.391871,4232,site of the Future Infrared and Submillimeter Astronomical Observatory of Peru,,,,,, +YBJ,YJ,China,30.104812,90.525583,4316,small developed town in Damxung County Tibet,,,,,,YBG +YEB,YS,Spain,40.523472,-3.088497,917,Yebes Observatory RT40m,40,150,circular,ALT-AZ,0, +YEBRG,YB,Spain,40.52347605,-3.088524547,977,Yebes Observatory VGOS dish,13.2,100,linear,ALT-AZ,0,RAEGYEB +ZUG,ZG,Germany,47.416686,10.979614,2680,Schneefernerhaus research station on Zugspitze,,,,,, \ No newline at end of file diff --git a/ngehtsim/obs/obs_generator.py b/ngehtsim/obs/obs_generator.py index dc862d953..307063cda 100755 --- a/ngehtsim/obs/obs_generator.py +++ b/ngehtsim/obs/obs_generator.py @@ -512,7 +512,8 @@ def get_obs_times(self): # generate a raw observation def observe(self, input_model, addnoise=True, addgains=True, gainamp=0.04, opacitycal=True, - flagwind=True, flagday=False, addFR=False, el_min=const.el_min, el_max=const.el_max, p=None): + flagwind=True, flagday=False, addFR=False, allow_mixed_basis=False, + el_min=const.el_min, el_max=const.el_max, p=None): """ Generate a raw single-band observation that folds in weather-based opacity and sensitivity effects. @@ -525,6 +526,7 @@ def observe(self, input_model, addnoise=True, addgains=True, gainamp=0.04, opaci flagwind (bool): flag for whether to derate sites with high wind flagday (bool): flag for whether to flag sites during the local daytime addFR (bool): flag for whether or not to add feed rotations + allow_mixed_basis (bool): flag for whether to apply polarization basis conversions el_min (float): minimum elevation that a site can observe at, in degrees el_max (float): maximum elevation that a site can observe at, in degrees p (numpy.ndarray): list of parameters for an input ngEHTforecast.fisher.fisher_forecast.FisherForecast object @@ -533,9 +535,11 @@ def observe(self, input_model, addnoise=True, addgains=True, gainamp=0.04, opaci (ehtim.obsdata.Obsdata): eht-imaging Obsdata object containing the generated observation """ - # warning for the feed rotations + # print some warnings if addFR: print('WARNING: adding feed rotations is currently known to break with multi-frequency data generation, and it is suspect at all times.') + if allow_mixed_basis: + print('WARNING: data generated in a non-circular polarization basis does not have properly-stored metadata info.') # generate an empty obsdata object if ((self.obs_empty is None) or (self.obs_empty.rf != self.freq)): @@ -623,7 +627,7 @@ def observe(self, input_model, addnoise=True, addgains=True, gainamp=0.04, opaci # make sure we're in a circular basis obs = obs.switch_polrep(polrep_out='circ') - # extract elevation information + # extract relevant information t1 = obs.data['t1'] t2 = obs.data['t2'] sites_obs = np.unique(np.concatenate((t1, t2))) @@ -717,6 +721,43 @@ def observe(self, input_model, addnoise=True, addgains=True, gainamp=0.04, opaci ind1 = (t1 == site) ind2 = (t2 == site) + # transform polarization basis if need be + if allow_mixed_basis: + if site in list(const.known_polbases.keys()): + if (const.known_polbases[site] == 'linear'): + + # populate vectors of transform matrices + tform_mat1 = np.zeros((ind1.sum(), 2, 2), dtype=complex) + tform_mat2 = np.zeros((ind2.sum(), 2, 2), dtype=complex) + tform_mat1[:] = const.circ_to_lin + tform_mat2[:] = np.conj(const.circ_to_lin).T + + # populate vectors of coherency matrices + coh_mat1 = np.zeros((ind1.sum(), 2, 2), dtype=complex) + coh_mat1[:,0,0] = obs.data['rrvis'][ind1] + coh_mat1[:,0,1] = obs.data['rlvis'][ind1] + coh_mat1[:,1,0] = obs.data['lrvis'][ind1] + coh_mat1[:,1,1] = obs.data['llvis'][ind1] + coh_mat2 = np.zeros((ind2.sum(), 2, 2), dtype=complex) + coh_mat2[:,0,0] = obs.data['rrvis'][ind2] + coh_mat2[:,0,1] = obs.data['rlvis'][ind2] + coh_mat2[:,1,0] = obs.data['lrvis'][ind2] + coh_mat2[:,1,1] = obs.data['llvis'][ind2] + + # transform the basis + coh_mat_tformed1 = np.matmul(tform_mat1,coh_mat1) + coh_mat_tformed2 = np.matmul(coh_mat2,tform_mat2) + + # re-populate the data vector + obs.data['rrvis'][ind1] = coh_mat_tformed1[:,0,0] + obs.data['rlvis'][ind1] = coh_mat_tformed1[:,0,1] + obs.data['lrvis'][ind1] = coh_mat_tformed1[:,1,0] + obs.data['llvis'][ind1] = coh_mat_tformed1[:,1,1] + obs.data['rrvis'][ind2] = coh_mat_tformed2[:,0,0] + obs.data['rlvis'][ind2] = coh_mat_tformed2[:,0,1] + obs.data['lrvis'][ind2] = coh_mat_tformed2[:,1,0] + obs.data['llvis'][ind2] = coh_mat_tformed2[:,1,1] + # get opacities at each timestamp if site != 'space': tau1[ind1] = tau_z / np.cos((np.pi/2.0) - el1[ind1]) @@ -924,7 +965,8 @@ def observe(self, input_model, addnoise=True, addgains=True, gainamp=0.04, opaci # generate observation def make_obs(self, input_model=None, addnoise=True, addgains=True, gainamp=0.04, opacitycal=True, - addFR=False, el_min=const.el_min, el_max=const.el_max, flagwind=True, flagday=False, p=None): + addFR=False, flagwind=True, flagday=False, allow_mixed_basis=False, + el_min=const.el_min, el_max=const.el_max, p=None): """ Generate an observation that folds in weather-based opacity effects and applies a specified SNR thresholding scheme to mimic fringe-finding. @@ -938,6 +980,7 @@ def make_obs(self, input_model=None, addnoise=True, addgains=True, gainamp=0.04, flagwind (bool): flag for whether to derate sites with high wind flagday (bool): flag for whether to flag sites during the local daytime addFR (bool): flag for whether or not to add feed rotations + allow_mixed_basis (bool): flag for whether to apply polarization basis conversions el_min (float): minimum elevation that a site can observe at, in degrees el_max (float): maximum elevation that a site can observe at, in degrees p (numpy.ndarray): list of parameters for an input ngEHTforecast.fisher.fisher_forecast.FisherForecast object @@ -959,7 +1002,18 @@ def make_obs(self, input_model=None, addnoise=True, addgains=True, gainamp=0.04, print('No input model passed to make_obs; using the model provided in the settings.') # generate raw observation - obs = self.observe(input_model, addnoise=addnoise, addgains=addgains, gainamp=gainamp, opacitycal=opacitycal, flagwind=flagwind, flagday=flagday, addFR=addFR, el_min=el_min, el_max=el_max, p=p) + obs = self.observe(input_model, + addnoise=addnoise, + addgains=addgains, + gainamp=gainamp, + opacitycal=opacitycal, + flagwind=flagwind, + flagday=flagday, + addFR=addFR, + allow_mixed_basis=allow_mixed_basis, + el_min=el_min, + el_max=el_max, + p=p) # apply naive SNR thresholding if (snr_algo.lower() == 'naive'):