Docsity
Docsity

Prepara tus exámenes
Prepara tus exámenes

Prepara tus exámenes y mejora tus resultados gracias a la gran cantidad de recursos disponibles en Docsity


Consigue puntos base para descargar
Consigue puntos base para descargar

Gana puntos ayudando a otros estudiantes o consíguelos activando un Plan Premium


Orientación Universidad
Orientación Universidad

Taller de Antenas: Ejercicios de Campo Eléctrico en Matlab, Ejercicios de Antenas y Propagación de Radios

Una serie de ejercicios prácticos para el cálculo del campo eléctrico generado por diferentes configuraciones de cargas en un plano 2d utilizando matlab. Los ejercicios incluyen la implementación de código para calcular el campo eléctrico debido a dipolos y arreglos de cargas, y la visualización de los resultados mediante gráficos de contorno. Útil para estudiantes de ingeniería que buscan comprender los conceptos básicos del campo eléctrico y su aplicación en el diseño de antenas.

Tipo: Ejercicios

2016/2017

A la venta desde 03/02/2025

mauricio-velasquez-1
mauricio-velasquez-1 🇨🇴

7 documentos

1 / 28

Toggle sidebar

Esta página no es visible en la vista previa

¡No te pierdas las partes importantes!

bg1
Presentado por:
Taller de antenas
Facultad de ingeniería
Bogotá D.C.
2017
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c

Vista previa parcial del texto

¡Descarga Taller de Antenas: Ejercicios de Campo Eléctrico en Matlab y más Ejercicios en PDF de Antenas y Propagación de Radios solo en Docsity!

Presentado por:

Taller de antenas

Facultad de ingeniería

Bogotá D.C.

Punto 1

Código :

%%%%%%%DOS CARGAS%%%%%%%%%%%%%%%%

% This simple program computes the Electric Fields due to dipole % in a 2-D plane using the Coulomb's Law %-------------------------------------------------------------------------% clc close all; clear all; %-------------------------------------------------------------------------% % SYMBOLS USED IN THIS CODE %-------------------------------------------------------------------------% % E = Total electric field % Ex = X-Component of Electric-Field % Ey = Y-Component of Electric-Field % n = Number of charges % Q = All the 'n' charges are stored here % Nx = Number of grid points in X- direction % Ny = Number of grid points in Y-Direction % eps_r = Relative permittivity % r = distance between a selected point and the location of charge % ex = unit vector for x-component electric field % ey = unit vector for y-component electric field %-------------------------------------------------------------------------% %-------------------------------------------------------------------------% % INITIALIZATION % Here, all the grid, size, charges, etc. are defined %-------------------------------------------------------------------------% % Constant 1/(4piepsilon_0) = 910^ k = 910^9; % Enter the Relative permittivity eps_r = 1; charge_order = 10^-9; % milli, micro, nano etc.. const = k*charge_order/eps_r; % Enter the dimensions Nx = 101; % For 1 meter Ny = 101; % For 1 meter % Enter the number of charges. n = 2;

xlabel('x ','fontsize',14); ylabel('y ','fontsize',14); title('Electric field distribution, E (x,y) in V/m','fontsize',14); %-------------------------------------------------------------------------% % REFERENCE % SADIKU, ELEMENTS OF ELECTROMAGNETICS, 4TH EDITION, OXFORD %-------------------------------------------------------------------------% Grafica: Explicación:

En este código tenemos 2 cargas una positiva y una negativa en un plano 2d|

PUNTO 2

CODIGO:

%%%%%%%TRES CARGAS%%%%%%%%%%%%%%%%

% This simple program computes the Electric Fields due to dipole % in a 2-D plane using the Coulomb's Law %-------------------------------------------------------------------------% clc close all; clear all; %-------------------------------------------------------------------------% % SYMBOLS USED IN THIS CODE %-------------------------------------------------------------------------% % E = Total electric field % Ex = X-Component of Electric-Field % Ey = Y-Component of Electric-Field % n = Number of charges % Q = All the 'n' charges are stored here % Nx = Number of grid points in X- direction % Ny = Number of grid points in Y-Direction % eps_r = Relative permittivity % r = distance between a selected point and the location of charge % ex = unit vector for x-component electric field % ey = unit vector for y-component electric field %-------------------------------------------------------------------------% %-------------------------------------------------------------------------% % INITIALIZATION % Here, all the grid, size, charges, etc. are defined %-------------------------------------------------------------------------% % Constant 1/(4piepsilon_0) = 910^ k = 910^9; % Enter the Relative permittivity eps_r = 1; charge_order = 10^-9; % milli, micro, nano etc.. const = k*charge_order/eps_r; % Enter the dimensions Nx = 101; % For 1 meter Ny = 101; % For 1 meter % Enter the number of charges. n = 3;

xlabel('x ','fontsize',14); ylabel('y ','fontsize',14); title('Electric field distribution, E (x,y) in V/m','fontsize',14); %-------------------------------------------------------------------------% % REFERENCE % SADIKU, ELEMENTS OF ELECTROMAGNETICS, 4TH EDITION, OXFORD %-------------------------------------------------------------------------% GRAFICA : EXPLICACION: En ese código tenemos 3 cargas positivas en un plano 2d

PUNTO 3

CODIGO: % Constant 1/(4piepsilon_0) = 9*10^

k = 910^9; % Enter the Relative permittivity eps_r = 1; charge_order = 10^-9; % milli, micro, nano etc.. const = kcharge_order/eps_r; % Enter the dimensions Nx = 101; % For 1 meter Ny = 101; % For 1 meter % Enter the number of charges. n = 3; % Electric fields Initialization E_f = zeros(Nx,Ny); Ex = E_f; Ey = E_f; % Vectors initialization ex = E_f; ey = E_f; r = E_f; r_square = E_f; % Array of charges Q = [-1,1,-1,1]; % Array of locations X = [5,-5,0]; Y = [0,0,-5]; %------------------------------------------------------------------------ -% % COMPUTATION OF ELECTRIC FIELDS %------------------------------------------------------------------------ -% % Repeat for all the 'n' charges for k = 1:n q = Q(k); % Compute the unit vectors for i=1:Nx for j=1:Ny r_square(i,j) = (i-51-X(k))^2+(j-51-Y(k))^2; r(i,j) = sqrt(r_square(i,j)); ex(i,j) = ex(i,j)+(i-51-X(k))./r(i,j);

GRAFICA : EXPLICACION: Se modifica el código del punto 2 para que genere carga positivas y negativas

PUNTO 4

CODIGO:

%%%%%%%POLARIZATION FIRST%%%%%%%%%%%%%%%%

fontSize = 20; A = 10; % Amplitude. t = linspace(0, 2 * pi, 40); signal = A .* cos(t) + A .* sin(t); stem(t, signal, 'bo-', 'LineWidth', 2); xlabel('t', 'FontSize', fontSize); ylabel('signal', 'FontSize', fontSize); title('RHCP', 'FontSize', fontSize); grid on; % Enlarge figure to full screen. set(gcf, 'units','normalized','outerposition',[0 0 1 1]); % Give a name to the title bar. set(gcf,'name','Demo by ImageAnalyst','numbertitle','off')

GRAFICA:

plot( x2, 0x2,'k','LineWidth',3); plot( x2, 0.3x2,'k','LineWidth',3); plot(0*x2, x2,'k','LineWidth',3); hold off axis([-4 20 -2 3]) title('Linear polarized wave','fontsize',18) % title('Right-handed circularly polarized wave','fontsize',18) % title('Left-handed circularly polarized wave','fontsize',18) M(:,n) = getframe(gcf); end clf reset set(gcf,'Position',[100 100 800 600]) axis off movie(M,1,6) close all Grafica:

EXPLICACION:

Vemos en la primera grafica una reñal RHCP con

deltas y en la 2 grafica el movimiento 3d del

campo polarizada

PUNTO 5

CODIGO:

clear all % Parameters for different media % free space: kr=1, ki=1, phi= % plasma medium: kr=0, ki=1, phi=pi/ % very lossy medium: kr=1, ki=1, phi=pi/ kr = 11; ki = 01; phi = pi/2; xmax = 30; xmin = -4; delx = 0.1; x = [ 0:delx:xmax]; x2 = [xmin:delx:xmax]; framemax = 48; M = moviein(framemax); set(gcf,'Position',[100 100 640 480]) for n=1:framemax % % ==== Right-handed circularly polarized wave % E1 = exp(-0.3.x.ki).cos(kr.x-2pin/framemax ); % E2 = exp(-0.3.x.ki).cos(kr.x-2pin/framemax+phi); % ==== Left-handed circularly polarized wave E1 = exp(-0.3.x.ki).cos(kr.x-2pin/framemax ); E2 = exp(-0.3.x.ki).cos(kr.x-2pin/framemax-phi); E=E1+E2; figure(1)

GRAFICA: EXPLICACION: Notamos que con una polarización diferente la onda se graficada en 3d tiene un movimiento diferente en el espacio

PUNTO 6

CODIGO

%%%%POLARIZACION OBLICUA

clear all % Parameters for different media % free space: kr=1, ki=1, phi= % plasma medium: kr=0, ki=1, phi=pi/ % very lossy medium: kr=1, ki=1, phi=pi/ kr = 11; ki = 01; phi = 0; xmax = 30; xmin = -4; delx = 0.1; x = [ 0:delx:xmax]; x2 = [xmin:delx:xmax]; framemax = 48; M = moviein(framemax); set(gcf,'Position',[100 100 640 480]) for n=1:framemax % % ==== Right-handed circularly polarized wave % E1 = exp(-0.3.x.ki).cos(kr.x-2pin/framemax ); % E2 = exp(-0.3.x.ki).cos(kr.x-2pin/framemax+phi); % ==== Left-handed circularly polarized wave E1 = exp(-0.3.x.ki).cos(kr.x-2pin/framemax ); E2 = exp(-0.3.x.ki).cos(kr.x-2pin/framemax-phi); E=E1+E2; figure(1) whitebg([1 1 1]); %plot(x, E ,'r' ,'LineWidth',3); plot(x+round(100E2)/30,E,'b' ,'LineWidth',3); hold on plot(x(1)+round(100E2(1))/30,E(1),'ro' ,'LineWidth',3); % plot(x, S ,'g' ,'LineWidth',3);

EXPLICACION: Notamos que con una polarización diferente la onda se graficada en 3d tiene un movimiento diferente en el espacio

PUNTO 7

CODIGO:

%%%%%%%%%%%%POLARIZACION CIRCULAR

clear all % Parameters for different media % free space: kr=1, ki=1, phi= % plasma medium: kr=0, ki=1, phi=pi/ % very lossy medium: kr=1, ki=1, phi=pi/ kr = 11; ki = 01; phi = pi/2; xmax = 30; xmin = -4; delx = 0.1; x = [ 0:delx:xmax]; x2 = [xmin:delx:xmax]; framemax = 48; M = moviein(framemax); set(gcf,'Position',[100 100 640 480]) for n=1:framemax % % ==== Right-handed circularly polarized wave % E1 = exp(-0.3.x.ki).cos(kr.x-2pin/framemax ); % E2 = exp(-0.3.x.ki).cos(kr.x-2pin/framemax+phi); % ==== Left-handed circularly polarized wave E1 = exp(-0.3.x.ki).cos(kr.x-2pin/framemax ); E2 = exp(-0.3.x.ki).cos(kr.x-2pin/framemax-phi); E=E1+E2; figure(1) whitebg([1 1 1]); %plot(x, E ,'r' ,'LineWidth',3); plot(x+round(100*E2)/30,E,'b' ,'LineWidth',3);