TraceMaker
C++ API of the engine
Loading...
Searching...
No Matches
tmk::crules::imp Namespace Reference

Classes

struct  Line
struct  Pair
struct  Solved

Enumerations

enum class  Structure : std::uint8_t { Microstrip , Stripline , Gcpw }

Functions

Line microstrip (Coord w, Coord h, Coord t, double er)
 Microstrip: strip of width w and thickness t on a dielectric of height h (strip bottom to plane), εr er.
Line stripline (Coord w, Coord h1, Coord h2, Coord t, double er)
 Stripline between two planes: h1 dielectric from the upper plane to the strip, h2 from the strip to the lower plane (the plane spacing is h1 + t + h2); symmetric when h1 == h2.
Pair coupled_microstrip (Coord w, Coord s, Coord h, Coord t, double er)
 Edge-coupled microstrip: two strips of width w, edge-to-edge gap s.
Pair coupled_stripline (Coord w, Coord s, Coord h1, Coord h2, Coord t, double er)
 Edge-coupled stripline (broadside layout not modelled).
Line gcpw (Coord w, Coord g, Coord h, Coord t, double er)
 Grounded (conductor-backed) coplanar waveguide: strip w, gap g to the coplanar ground on both sides, plane at h.
double ipc2141_microstrip (Coord w, Coord h, Coord t, double er)
 IPC-2141A's simple forms (the industry rule of thumb, ±5-10 %), used only as an independent cross-check.
double ipc2141_stripline (Coord w, Coord b, Coord t, double er)
 b = plane spacing, strip centred
double prop_delay_ps_per_mm (double eps_eff)
 Propagation delay in ps/mm for an effective permittivity: sqrt(eps_eff) / c.
double k_ratio (double k)
 Complete elliptic integral ratio K(k) / K(k'), k' = sqrt(1 - k^2), by the arithmetic-geometric mean (K(k) = pi / (2 AGM(1, k'))).
Solved solve_monotone (const std::function< double(Coord)> &z_of, double target, Coord lo, Coord hi, bool decreasing)
 Bisection on integer nm for a function that decreases (decreasing = true, e.g.
const char * structure_name (Structure s)
double formula_error_pct (Structure s, bool differential, bool asymmetric)
 Formula error stated in the report, percent (doc 15 §5.3 point 3; dev/assumptions-m13.md).
Coord width_for_current (double amps, double delta_t_c, Coord copper, bool external)
 IPC-2221B §6.2 (from the IPC-D-275 charts): I = k * dT^0.44 * A^0.725, A cross-section in mil^2, k = 0.048 external / 0.024 internal layers.
double current_for_width (Coord width, double delta_t_c, Coord copper, bool external)

Variables

constexpr double kEta0 = 376.730313668
 free-space wave impedance, ohm
constexpr double kC0MmPerPs = 0.299792458
 speed of light, mm/ps

Enumeration Type Documentation

◆ Structure

enum class tmk::crules::imp::Structure : std::uint8_t
strong
Enumerator
Microstrip 
Stripline 
Gcpw 

Definition at line 77 of file impedance.hpp.

Function Documentation

◆ coupled_microstrip()

Pair tmk::crules::imp::coupled_microstrip ( Coord w,
Coord s,
Coord h,
Coord t,
double er )

Edge-coupled microstrip: two strips of width w, edge-to-edge gap s.

◆ coupled_stripline()

Pair tmk::crules::imp::coupled_stripline ( Coord w,
Coord s,
Coord h1,
Coord h2,
Coord t,
double er )

Edge-coupled stripline (broadside layout not modelled).

◆ current_for_width()

double tmk::crules::imp::current_for_width ( Coord width,
double delta_t_c,
Coord copper,
bool external )

◆ formula_error_pct()

double tmk::crules::imp::formula_error_pct ( Structure s,
bool differential,
bool asymmetric )

Formula error stated in the report, percent (doc 15 §5.3 point 3; dev/assumptions-m13.md).

◆ gcpw()

Line tmk::crules::imp::gcpw ( Coord w,
Coord g,
Coord h,
Coord t,
double er )

Grounded (conductor-backed) coplanar waveguide: strip w, gap g to the coplanar ground on both sides, plane at h.

◆ ipc2141_microstrip()

double tmk::crules::imp::ipc2141_microstrip ( Coord w,
Coord h,
Coord t,
double er )

IPC-2141A's simple forms (the industry rule of thumb, ±5-10 %), used only as an independent cross-check.

◆ ipc2141_stripline()

double tmk::crules::imp::ipc2141_stripline ( Coord w,
Coord b,
Coord t,
double er )

b = plane spacing, strip centred

◆ k_ratio()

double tmk::crules::imp::k_ratio ( double k)

Complete elliptic integral ratio K(k) / K(k'), k' = sqrt(1 - k^2), by the arithmetic-geometric mean (K(k) = pi / (2 AGM(1, k'))).

Exposed for tests.

◆ microstrip()

Line tmk::crules::imp::microstrip ( Coord w,
Coord h,
Coord t,
double er )

Microstrip: strip of width w and thickness t on a dielectric of height h (strip bottom to plane), εr er.

◆ prop_delay_ps_per_mm()

double tmk::crules::imp::prop_delay_ps_per_mm ( double eps_eff)

Propagation delay in ps/mm for an effective permittivity: sqrt(eps_eff) / c.

◆ solve_monotone()

Solved tmk::crules::imp::solve_monotone ( const std::function< double(Coord)> & z_of,
double target,
Coord lo,
Coord hi,
bool decreasing )

Bisection on integer nm for a function that decreases (decreasing = true, e.g.

Z(width)) or increases (Z(gap)) monotonically on [lo, hi]. Returns the integer closest to the crossing (ties: the smaller value).

◆ stripline()

Line tmk::crules::imp::stripline ( Coord w,
Coord h1,
Coord h2,
Coord t,
double er )

Stripline between two planes: h1 dielectric from the upper plane to the strip, h2 from the strip to the lower plane (the plane spacing is h1 + t + h2); symmetric when h1 == h2.

Homogeneous dielectric: eps_eff = er.

◆ structure_name()

const char * tmk::crules::imp::structure_name ( Structure s)

◆ width_for_current()

Coord tmk::crules::imp::width_for_current ( double amps,
double delta_t_c,
Coord copper,
bool external )

IPC-2221B §6.2 (from the IPC-D-275 charts): I = k * dT^0.44 * A^0.725, A cross-section in mil^2, k = 0.048 external / 0.024 internal layers.

Width for amps at temperature rise delta_t_c with copper thickness copper (nm), rounded up to the next nm.

Variable Documentation

◆ kC0MmPerPs

double tmk::crules::imp::kC0MmPerPs = 0.299792458
inlineconstexpr

speed of light, mm/ps

Definition at line 26 of file impedance.hpp.

◆ kEta0

double tmk::crules::imp::kEta0 = 376.730313668
inlineconstexpr

free-space wave impedance, ohm

Definition at line 25 of file impedance.hpp.