Antenna - Theory .com: The Antenna Site

Antenna Basics Antenna Types Smith Charts Antenna Measurements

antenna-theory.com :: View topic - Problems in plotting figure 5 in the course antenna theory
antenna-theory.com Forum Index antenna-theory.com
Antenna Theory
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Problems in plotting figure 5 in the course antenna theory

 
Post new topic   Reply to topic    antenna-theory.com Forum Index -> Questions Related to Antenna Theory
View previous topic :: View next topic  
Author Message
Tagalb
Antenna-Theory.com Newbie


Joined: 28 Aug 2017
Posts: 2

PostPosted: Tue Aug 29, 2017 7:29 am    Post subject: Problems in plotting figure 5 in the course antenna theory Reply with quote

Hello
I am trying to plot the Figure 5 (Magnitude of the output as a function of the arrival angle for Antenna Array):http://www.antenna-theory.com/arrays/main.php
But it seems like it is not so simple.

I wrote this simple code but I do not have the desired result:

teta_angle = 1:0.25:180;
y1= exp(-j*pi*cos(teta_angle));
y2= exp(j*pi*cos(teta_angle));
y=y1+y2;
Y=mag2db(abs(y));
plot(teta_angle,Y)


Could you maybe help me to figure out what is wrong with my code ?

Thanks
Back to top
View user's profile Send private message
admin
Site Admin


Joined: 03 Jan 2007
Posts: 192

PostPosted: Tue Aug 29, 2017 5:13 pm    Post subject: Reply with quote

Looks like your taking cosine of an angle in degrees, should be radians
Back to top
View user's profile Send private message Send e-mail
Tagalb
Antenna-Theory.com Newbie


Joined: 28 Aug 2017
Posts: 2

PostPosted: Thu Aug 31, 2017 2:01 pm    Post subject: Reply with quote

Actually I found it, thank you
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    antenna-theory.com Forum Index -> Questions Related to Antenna Theory All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group