PO_matlab
DirectedDipole Class Reference

Subclass of SimpleDipole that automatically points toward a target. More...

Inheritance diagram for DirectedDipole:

Public Member Functions

function DirectedDipole (in I0, in l, in loc_vec, in r_targ, in theta_targ, in phi_targ)
 Constructor for DirectedDipole.
function get dir_vec (in obj)
 Returns normalized direction vector.
function E_calc (in obj, in r, in theta, in phi, in freq, in usegreen)
 Computes the Etheta and Ephi far-field components.
function point_towards_target (in obj, in r, in theta, in phi)
 Reorients dipole to point toward a spherical target.

Public Attributes

Property I0
 Current magnitude in Amperes.
Property l
 Dipole length in meters.
Property loc_vec
 Dipole location as a 3x1 Cartesian vector [x; y; z].
Property dir_vec_
 Dipole direction vector (unnormalized)
Property dir_vec
 Normalized version of dir_vec_.

Private Attributes

Constant Property ep0 = 8.85418782e
 Vacuum permittivity in F/m.
Constant Property mu0 = 1.25663706e
 Vacuum permeability in H/m.

Detailed Description

Subclass of SimpleDipole that automatically points toward a target.

This class initializes a SimpleDipole with a default upward orientation, and then redirects it toward a specified target direction given in spherical coordinates.

Constructor & Destructor Documentation

◆ DirectedDipole()

function DirectedDipole ( in I0,
in l,
in loc_vec,
in r_targ,
in theta_targ,
in phi_targ )

Constructor for DirectedDipole.

Parameters
I0Current amplitude [A]
lDipole length [m]
loc_vec3x1 position vector [x; y; z]
r_targRadial distance to target [m]
theta_targElevation angle of target [rad]
phi_targAzimuth angle of target [rad]

Member Function Documentation

◆ dir_vec()

function get dir_vec ( in obj)
inherited

Returns normalized direction vector.

Return values
dir_vecNormalized 3x1 direction vector

◆ E_calc()

function E_calc ( in obj,
in r,
in theta,
in phi,
in freq,
in usegreen )
inherited

Computes the Etheta and Ephi far-field components.

Parameters
rRadial distance(s)
thetaElevation angle(s) in radians
phiAzimuth angle(s) in radians
freqFrequency in Hz
usegreenOptional flag to use the Green's function (default = 1)
Return values
EthetaTheta-polarized electric field
EphiPhi-polarized electric field

◆ point_towards_target()

function point_towards_target ( in obj,
in r,
in theta,
in phi )
inherited

Reorients dipole to point toward a spherical target.

Parameters
rRadius to the target
thetaElevation angle in radians
phiAzimuth angle in radians

Member Data Documentation

◆ dir_vec

Property dir_vec
inherited

Normalized version of dir_vec_.

◆ dir_vec_

Property dir_vec_
inherited

Dipole direction vector (unnormalized)

◆ ep0

Constant Property ep0 = 8.85418782e
privateinherited

Vacuum permittivity in F/m.

◆ I0

Property I0
inherited

Current magnitude in Amperes.

◆ l

Property l
inherited

Dipole length in meters.

◆ loc_vec

Property loc_vec
inherited

Dipole location as a 3x1 Cartesian vector [x; y; z].

◆ mu0

Constant Property mu0 = 1.25663706e
privateinherited

Vacuum permeability in H/m.


The documentation for this class was generated from the following file: