{"id":4210,"date":"2022-05-30T07:27:15","date_gmt":"2022-05-30T07:27:15","guid":{"rendered":"http:\/\/www.raymaps.com\/?p=4210"},"modified":"2024-12-09T06:39:20","modified_gmt":"2024-12-09T06:39:20","slug":"direction-of-arrival-estimation","status":"publish","type":"post","link":"https:\/\/www.raymaps.com\/index.php\/direction-of-arrival-estimation\/","title":{"rendered":"Fundamentals of Direction of Arrival Estimation"},"content":{"rendered":"\n<p>Direction of Arrival (DOA) estimation is a fundamental problem in communications and signal processing with application in cellular communications, radar, sonar etc. It has become increasingly important in recent times as 5G communications uses DOA to spatially separate the users resulting in higher capacity and throughput. Direction of Arrival estimation can be thought of as the converse of beamforming. As you might recall from the discussion in previous <a href=\"https:\/\/www.raymaps.com\/index.php\/basics-of-beam-forming-in-wireless-communications\/\">posts<\/a>, in beamforming you use the steering vector to receive a signal from a particular direction, rejecting the signals from other directions. In DOA estimation you scan the entire angular domain to find the required signal or signals and estimate their angles of arrival and possibly the ranges as well.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"598\" height=\"419\" src=\"http:\/\/www.raymaps.com\/wp-content\/uploads\/2018\/01\/Plane-Wave-Impinging-Upon-a-ULA.png\" alt=\"Plane Wave Impinging Upon a ULA\" class=\"wp-image-2886\" srcset=\"https:\/\/www.raymaps.com\/wp-content\/uploads\/2018\/01\/Plane-Wave-Impinging-Upon-a-ULA.png 598w, https:\/\/www.raymaps.com\/wp-content\/uploads\/2018\/01\/Plane-Wave-Impinging-Upon-a-ULA-300x210.png 300w\" sizes=\"auto, (max-width: 598px) 100vw, 598px\" \/><figcaption class=\"wp-element-caption\">Plane Wave Impinging Upon a Uniform Linear Array<\/figcaption><\/figure>\n\n\n\n<p>The theory of DOA estimation draws from the techniques and algorithms used for spectral estimation, as finding the angle of arrival in the spatial domain is the same as finding the frequency of a windowed signal in the temporal domain. Just as we have to follow the Nyquist\u2019s sampling theorem in time domain, we have to follow the spatial sampling theorem when implementing beamforming or DOA estimation. Some of the popular techniques used for DOA estimation are correlation, MVDR, FFT, MUSIC and ESPRIT. We only discuss the first two in this section as the remaining ones are discussed in detail in the <a href=\"https:\/\/www.raymaps.com\/index.php\/a-comparison-of-fft-music-and-esprit-methods-of-frequency-estimation\/\">posts<\/a> on phase and frequency. <\/p>\n\n\n\n<p>Correlation or Delay and Sum (DS)\nmethod, as it is sometimes referred to, is the simplest and most effective\ntechnique and works quite well at low SNRs and with moderate array size.\nMinimum Variance Distortionless Response (MVDR) on the other hand is a bit more\ncomplicated as it requires estimation of the correlation matrix and also\nrequires couple of matrix inversions. As you may already know matrix inversion\nis a tricky subject and if the matrix is ill conditioned the inverse may not\neven exist. A technique usually used to get around this problem is to use the\nMoore Penrose Pseudo Inverse instead of direction inversion. Another problem\nwith MVDR is that for estimating the correlation matrix you need multiple\nsnapshots to get good results. &nbsp;&nbsp;<\/p>\n\n\n\n<p> Given below is the code and simulation results for both the techniques. We have assumed a frequency of 1GHz, antenna spacing of \u03bb\/2, angles of arrival of 30, 60 and 90 degrees, signal to noise ratio of 0dB (per element) and scan resolution of 1 degree over azimuth. Antenna array size is varied from 20 elements to 100 elements and correlation matrix for MVDR is calculated using 1000 snapshots (no averaging is used for DS). It is seen that performance of simple correlation scheme is quite respectable even for a receive array size of 20 and improves appreciably when the array size is increased to 100 (pencil beam is obtained). This is not the case for MVDR which is highly sensitive to noise level and performance is not that great even for N=100. However, a surprising result was that MVDR performs better than DS in very poor SNR (which can be attributed to averaging used in calculation of correlation matrix for MVDR).  <\/p>\n\n\n\n<p>Mathematically the two methods can be described as:<\/p>\n\n\n\n<center><b>P<sub>DS<\/sub>=E|w<sup>H<\/sup>y| <sup>2<\/sup>=w<sup>H<\/sup>R<sub>yy<\/sub>w<\/b><\/center><br><br>\n\n\n\n<center><b>P<sub>MVDR<\/sub>=(w<sup>H<\/sup>R<sub>yy<\/sub><sup>-1<\/sup>w)<sup>-1<\/sup><\/b><\/center><br><br>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"834\" height=\"622\" src=\"http:\/\/www.raymaps.com\/wp-content\/uploads\/2022\/05\/DOA_ULAwithLegend.png\" alt=\"Direction of Arrival Estimation Using Correlation Method\" class=\"wp-image-4211\" srcset=\"https:\/\/www.raymaps.com\/wp-content\/uploads\/2022\/05\/DOA_ULAwithLegend.png 834w, https:\/\/www.raymaps.com\/wp-content\/uploads\/2022\/05\/DOA_ULAwithLegend-300x224.png 300w, https:\/\/www.raymaps.com\/wp-content\/uploads\/2022\/05\/DOA_ULAwithLegend-768x573.png 768w\" sizes=\"auto, (max-width: 834px) 100vw, 834px\" \/><figcaption class=\"wp-element-caption\">Direction of Arrival Estimation Using Correlation Method<\/figcaption><\/figure>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"834\" height=\"622\" src=\"http:\/\/www.raymaps.com\/wp-content\/uploads\/2022\/05\/DOA_MVDRwithLegend.png\" alt=\"Direction of Arrival Estimation Using MVDR\" class=\"wp-image-4213\" srcset=\"https:\/\/www.raymaps.com\/wp-content\/uploads\/2022\/05\/DOA_MVDRwithLegend.png 834w, https:\/\/www.raymaps.com\/wp-content\/uploads\/2022\/05\/DOA_MVDRwithLegend-300x224.png 300w, https:\/\/www.raymaps.com\/wp-content\/uploads\/2022\/05\/DOA_MVDRwithLegend-768x573.png 768w\" sizes=\"auto, (max-width: 834px) 100vw, 834px\" \/><figcaption class=\"wp-element-caption\">Direction of Arrival Estimation Using MVDR<\/figcaption><\/figure>\n\n\n\n<h5 class=\"wp-block-heading\">Code for Direction of Arrival Estimation Using Correlation Method<\/h5>\n\n\n\n<pre lang=\"MATLAB\">%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n% DIRECTION OF ARRIVAL ESTIMATION USING A ULA\n% CORRELATION METHOD\n% N is the number of elements\n% d is the inter-element spacing\n% theta is the angle of arrival\n% Copyright 2022 RAYmaps\n%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\nclear all\nclose all\n\nf=1e9;\nc=3e8;\nl=c\/f;\nd=l\/2;\nN=20;\nphi=0:pi\/180:2*pi;\n\ntheta1=pi\/6;\ntheta2=pi\/3;\ntheta3=pi\/2;\nn=1:N;\nn=transpose(n);\n\nx1=exp(-i*(n-1)*2*pi*d*cos(theta1)\/l);\nx2=exp(-i*(n-1)*2*pi*d*cos(theta2)\/l);\nx3=exp(-i*(n-1)*2*pi*d*cos(theta3)\/l);\n\nx=x1+x2+x3;\ny=x+0.7071*(randn(N,1)+i*randn(N,1));\nw=exp(-i*(n-1)*2*pi*d*cos(phi)\/l);\nr=w'*y;\n\npolar(phi,abs(r)\/max(abs(r)),'b')\ntitle ('Direction of Arrival Estimation')\n%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n<\/pre>\n\n\n\n<h5 class=\"wp-block-heading\"> <br>Code for Direction of Arrival Estimation Using MVDR Method <\/h5>\n\n\n\n<pre lang=\"MATLAB\">%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n% DIRECTION OF ARRIVAL ESTIMATION USING A ULA\n% MVDR METHOD\n% N is the number of elements\n% d is the inter-element spacing\n% theta is the angle of arrival\n% Copyright 2022 RAYmaps\n%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\nclear all\nclose all\n\nf=1e9;\nc=3e8;\nl=c\/f;\nd=l\/2;\nN=20;\nphi=0:pi\/180:2*pi;\ntheta=[pi\/6, pi\/3, pi\/2];\nn=transpose(1:N);\n\nx1=exp(-i*(n-1)*2*pi*d*cos(theta(1))\/l);\nx2=exp(-i*(n-1)*2*pi*d*cos(theta(2))\/l);\nx3=exp(-i*(n-1)*2*pi*d*cos(theta(3))\/l);\nx=x1+x2+x3;\nR=zeros(N,N);\n\nfor m=1:1000\n   y=x+0.7071*(randn(N,1)+i*randn(N,1));\n   R=R+y*y';\nend\n\nR=R\/m;\nR1=pinv(R,0.1);\nw=exp(-i*(n-1)*2*pi*d*cos(phi)\/l);\n\nfor k=1:length(phi);\n   w1=w(:,k);\n   P(k)=abs(pinv(w1'*R1*w1,0.1));\nend\n\npolar(phi,P\/max(P),'b')\ntitle ('Direction of Arrival Estimation')\n%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n<\/pre>\n\n\n\n<p>Note: <\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Please<br>note that so far our analysis is based on visual inspection, which can be<br>misleading. It is possible that a particular technique may have smaller peaks<br>but accuracy of angular information is greater. For more in depth analysis we<br>need to compare the Mean Square Error (MSE) to Cramer Rao Lower Bound (CRLB).<br>We also need to decrease the step size for the scan.<\/li>\n\n\n\n<li>Please<br>note that we have scanned the entire angular domain from 0 to 360 degrees to<br>find the DOA. In ULA theory it is known that response is symmetrical about the<br>axis of the array so typically only 0 to 180 degrees is scanned. <\/li>\n\n\n\n<li>Some<br>interesting antenna patterns can be obtained by using non-uniform antenna<br>arrays and we hope to discuss this in a future post. <\/li>\n\n\n\n<li>Beamforming<br>and DOA go hand in hand. DOA finds the angle of arrival and then the<br>base-station can form a beam on that angle using beamforming techniques.<\/li>\n\n\n\n<li>Minimum<br>Variance Distortionless Response is also known Capon estimator after its<br>founder J. Capon who proposed his spectral analysis method in 1969. <\/li>\n<\/ol>\n\n\n\n<p>References<\/p>\n\n\n\n<p><a href=\"https:\/\/www.comm.utoronto.ca\/~rsadve\/Notes\/DOA.pdf\">https:\/\/www.comm.utoronto.ca\/~rsadve\/Notes\/DOA.pdf<\/a><\/p>\n\n\n\n<p><a href=\"https:\/\/arxiv.org\/pdf\/2002.01588.pdf\">https:\/\/arxiv.org\/pdf\/2002.01588.pdf<\/a><\/p>\n\n\n\n<p><a href=\"https:\/\/escholarship.org\/content\/qt1w13p71p\/qt1w13p71p_noSplash_9f69e592ae9b76ba11f4349daa613333.pdf\">https:\/\/escholarship.org\/content\/qt1w13p71p\/qt1w13p71p_noSplash_9f69e592ae9b76ba11f4349daa613333.pdf<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Direction of Arrival (DOA) estimation is a fundamental problem in communications and signal processing with application in cellular communications, radar, sonar etc. It has become increasingly important in recent times as 5G communications uses DOA to spatially separate the users resulting in higher capacity and throughput. Direction of Arrival estimation can be thought of as the converse of beamforming. <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[189,12],"tags":[170,68,239,240,169],"class_list":["post-4210","post","type-post","status-publish","format-standard","hentry","category-5g","category-ant","tag-beamforming","tag-correlation","tag-doa","tag-mvdr","tag-ula"],"_links":{"self":[{"href":"https:\/\/www.raymaps.com\/index.php\/wp-json\/wp\/v2\/posts\/4210","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.raymaps.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.raymaps.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.raymaps.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.raymaps.com\/index.php\/wp-json\/wp\/v2\/comments?post=4210"}],"version-history":[{"count":22,"href":"https:\/\/www.raymaps.com\/index.php\/wp-json\/wp\/v2\/posts\/4210\/revisions"}],"predecessor-version":[{"id":4531,"href":"https:\/\/www.raymaps.com\/index.php\/wp-json\/wp\/v2\/posts\/4210\/revisions\/4531"}],"wp:attachment":[{"href":"https:\/\/www.raymaps.com\/index.php\/wp-json\/wp\/v2\/media?parent=4210"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.raymaps.com\/index.php\/wp-json\/wp\/v2\/categories?post=4210"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.raymaps.com\/index.php\/wp-json\/wp\/v2\/tags?post=4210"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}