AWG2mm

by Tim C. Lueth, SG-Lib Toolbox: SolidGeometry 5.6 - Auxiliary function
Introduced first in SolidGeometry 5.0, Creation date: 2020-10-26, Last change: 2025-09-15

converts American Wire Gauge to Wire Diameter



See Also: French2mm , mm2inch , Charriere2mm , Gauge2mm , SGcablewinch , PS2KW , KW2PS , Fahrenheit2Celsius

Example Illustration

 missing image of AWG2mm(awg,len,Ucc,Isc)

Syntax

dmm=AWG2mm([awg,len,Ucc,Isc])

Input Parameter

awg: AWG
len: optional cable length in METER
Ucc: optional cable voltage
Isc: optional cable current

Output Parameter

dmm: Wire diameter

Examples


AWG2mm(23,0.2)




Copyright 2020-2025 Tim C. Lueth. All rights reserved. The code is the property of Tim C. Lueth and may not be redistributed or modified without explicit written permission. This software may be used free of charge for academic research and teaching purposes only. Commercial use, redistribution, modification, or reverse engineering is strictly prohibited. Access to source code is restricted and granted only under specific agreements. For licensing inquiries or commercial use, please contact: Tim C. Lueth

Algorithm (Workflow)

This function, AWG2mm, converts American Wire Gauge (AWG) to wire diameter in millimeters. It is part of the SolidGeometry library and was introduced in version 5.0.

Input Parameters

Output

Algorithm Steps

  1. Retrieve the input parameters using the getfuncparams function. If parameters are not provided, use default values: AWG = 36, len = 1 meter, Ucc = 12 volts.
  2. Define constants: AWG36 = 0.127 mm for the diameter of AWG 36 wire, and rcup = 0.0178 Ohm/mm² for resistivity.
  3. Calculate the wire diameter dmm using the formula: dmm = AWG36 * 92^((36 - awg) / 39).
  4. Calculate the cross-sectional area amm using the formula: amm = (dmm / 2)^2 * pi.
  5. Calculate the resistance rmm using the formula: rmm = rcup * amm * len.
  6. Calculate the current I using the formula: I = Ucc / rmm.
  7. If Isc is not provided, set it to I.
  8. Calculate the power W using the formula: W = Ucc * Isc.
  9. If no output is requested, print the results using dbprintf:
    • Print the wire diameter and cross-sectional area.
    • If the length is not the default, print the resistance.
Algorithm explaination created using ChatGPT on 2025-08-19 07:00. (Please note: No guarantee for the correctness of this explanation)

Last html export of this page out of FM database by TL: 2025-09-21