PO_matlab
SimpleDipole Class Reference

Models a Hertzian dipole for far-field calculations. More...

Inheritance diagram for SimpleDipole:

Public Member Functions

function SimpleDipole (in I0, in l, in loc_vec, in dir_vec)
 Constructor for SimpleDipole.
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.
function get dir_vec (in obj)
 Returns normalized direction vector.

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

Models a Hertzian dipole for far-field calculations.

This class represents an idealized electric dipole located at a given position in space, with a specific orientation and current. It provides methods to compute the far-field components of the electric field using the dipole parameters and observation angles.

Constructor & Destructor Documentation

◆ SimpleDipole()

function SimpleDipole ( in I0,
in l,
in loc_vec,
in dir_vec )

Constructor for SimpleDipole.

Parameters
I0Current in Amperes
lLength in meters
loc_vec3x1 position vector
dir_vec3x1 direction vector (not necessarily normalized)

Member Function Documentation

◆ dir_vec()

function get dir_vec ( in obj)

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 )

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 )

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

Normalized version of dir_vec_.

◆ dir_vec_

Property dir_vec_

Dipole direction vector (unnormalized)

◆ ep0

Constant Property ep0 = 8.85418782e
private

Vacuum permittivity in F/m.

◆ I0

Property I0

Current magnitude in Amperes.

◆ l

Property l

Dipole length in meters.

◆ loc_vec

Property loc_vec

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

◆ mu0

Constant Property mu0 = 1.25663706e
private

Vacuum permeability in H/m.


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