Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

mstrip.cc

Go to the documentation of this file.
00001 // mstrip.cc
00002 // SuperMix version 1.0  C++ source file
00003 //
00004 // Copyright (c) 1999 California Institute of Technology.
00005 // All rights reserved.
00006 //
00007 // Redistribution and use in source and binary forms for noncommercial
00008 // purposes are permitted provided that the above copyright notice and
00009 // this paragraph are duplicated in all such forms and that any
00010 // documentation and other materials related to such distribution and
00011 // use acknowledge that the software was developed by California
00012 // Institute of Technology. Redistribution and/or use in source or
00013 // binary forms is not permitted for any commercial purpose. Use of
00014 // this software does not include a permitted use of the Institute's
00015 // name or trademark for any purpose.
00016 //
00017 // DISCLAIMER:
00018 // THIS SOFTWARE AND/OR RELATED MATERIALS ARE PROVIDED "AS-IS" WITHOUT
00019 // WARRANTY OF ANY KIND INCLUDING ANY WARRANTIES OF PERFORMANCE OR
00020 // MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE OR PURPOSE (AS SET
00021 // FORTH IN UCC 23212-2313) OR FOR ANY PURPOSE WHATSOEVER, FOR THE
00022 // LICENSED PRODUCT, HOWEVER USED.  IN NO EVENT SHALL CALTECH/JPL BE
00023 // LIABLE FOR ANY DAMAGES AND/OR COSTS, INCLUDING BUT NOT LIMITED TO
00024 // INCIDENTAL OR CONSEQUENTIAL DAMAGES OF ANY KIND, INCLUDING ECONOMIC
00025 // DAMAGE OR INJURY TO PROPERTY AND LOST PROFITS, REGARDLESS OF
00026 // WHETHER CALTECH/JPL SHALL BE ADVISED, HAVE REASON TO KNOW, OR IN
00027 // FACT SHALL KNOW OF THE POSSIBILITY.  THE USER BEARS ALL RISK
00028 // RELATING TO QUALITY AND PERFORMANCE OF THE SOFTWARE AND/OR RELATED
00029 // MATERIALS.
00030 //
00031 // Change history:
00032 // 8/4/99:   Removed calculation of attenuation constant (alpha), and
00033 //           fixed error found by A. Karpov when using dielectrics with
00034 //           nonzero loss tangent. The error was related to improper
00035 //           use of units. (J.Z.)
00036 //           Loss is now handled by using effective loss tangent (tandel)
00037 //           
00038 // 3/22/99:  changed VERYBIG to MSTRIP_H_VERYBIG
00039 
00040 #include <math.h>
00041 #include "units.h"
00042 #include "mstrip.h"
00043 
00044 void mstrip(double h, double w, double t1, double t2, 
00045             double esub, double eup, double Qsub, double Qup, double freq,
00046             double &Z0, double &epeff, double &tandel, double &g2)
00047 {
00048 //
00049 //    J. Zmuidzinas 11/18/87
00050 //    Translated to C/C++  9/15/97
00051 //
00052 //    Based on equations given by Hammerstad and Jensen, IEEE Microwave
00053 //    Symposium proceedings, pp.407-409, 1980.
00054 //
00055 //    Lengths are converted to be in microns and frequencies in GHz.
00056 //
00057 //    Input parameters:
00058 //
00059 //    h - substrate thickness
00060 //    w - width of microstrip
00061 //    t1 - conductor thickness (strip)
00062 //    t2 - conductor thickness (ground)
00063 //    esub - dielectric constant of substrate
00064 //    eup - dielectric constant superstrate (usually = 1)
00065 //    freq - frequency
00066 //    Qsub - dielectric quality factor of substrate (1/tan(delta))
00067 //    delta is defined as the phase angle of the complex
00068 //    dielectric constant of the substrate
00069 //    Qup - dielectric quality factor of superstrate
00070 //
00071 //
00072 //    Output parameters:
00073 //
00074 //    Z0 - characteristic impedance
00075 //    epeff - effective dielectric constant
00076 //         (wavelength = free space wavelength / sqrt(epeff)
00077 //    tandel - effective loss tangent of line. Defined so that
00078 //         beta = (2*Pi/wavelength)*(1 + i*tandel)
00079 //         where beta is the complex propagation factor; i = sqrt(-1).
00080 //    g2 - geometrical factor for loss calculations; = 2/w for wide lines
00081 //
00082 //
00083       double u, Z01, fu, a, b, tnorm, delu1, delur,
00084              u1, ur, fp, G, eta0 ;
00085       double ex, coth, cosh, Z02, ee0, ee1, Kfact,
00086              Qc, Qd, Q0, q ;
00087       double x1, x2 ;
00088 //
00089       h /= Micron;       /* easier to scale now              */
00090       w /= Micron;       /* to units that subroutine expects */
00091       t1 /= Micron;      /* and to restore units later       */
00092       t2 /= Micron;
00093       freq /= GHz;
00094 //
00095 // Convert substrate dielectric constant to be relative to superstrate
00096 //
00097       esub /= eup ;
00098 //
00099       eta0 = ZVacuum/Ohm ;
00100       eta0 /= sqrt(eup) ;
00101       u = w/h ;
00102 //
00103 //     Calculate thickness corrections
00104 //
00105       tnorm = t1/h ;                         /* ?? need more thinking */
00106       ex = exp(sqrt(6.517*u)) ;
00107       coth = (ex+1./ex)/(ex-1./ex) ;
00108       delu1 = (tnorm/Pi)*log(1. + 4*exp(1.)/(tnorm*coth*coth)) ;
00109       ex = exp(sqrt(esub-1.)) ;
00110       cosh = 0.5*(ex+1./ex) ;
00111       delur = 0.5*(1. + 1./cosh)*delu1 ;
00112       u1 = u + delu1 ;
00113       ur = u + delur ;
00114 //
00115 //     Calculate characteristic impedance
00116 //
00117       u = ur ;
00118       fu = 6. + (2.*Pi-6.)*exp( -(pow((30.666/u), 0.7528)) ) ;
00119       Z01 = eta0*log(fu/u + sqrt(1.+((2./u)*(2./u))))/(2.*Pi) ;
00120       x1 = u*u*u*u + (u/52.)*(u/52.) ;
00121       x2 = u*u*u*u + 0.432 ;
00122       a = 1.+ (1./49.)*log(x1/x2) ;
00123       a += (1./18.7)*log(1.+(u/18.1)*(u/18.1)*(u/18.1)) ;
00124       b = 0.564*( pow((esub-0.9)/(esub+3.), 0.053) ) ;
00125       ee0 = (esub+1.)/2. + ((esub-1.)/2.)*pow( (1.+10./u), (-a*b) ) ;
00126 //
00127       Z0 = Z01/sqrt(ee0) ;
00128 //
00129 //     calculate finite thickness corrections to effective diel. const.
00130 //
00131       u = u1 ;
00132       fu = 6. + (2.*Pi-6.)*exp( -pow((30.666/u), 0.7528) ) ;
00133       Z02 = eta0*log(fu/u + sqrt(1.+((2./u)*(2./u))))/(2.*Pi) ;
00134       ee1 = ee0*((Z02/Z01)*(Z02/Z01)) ;
00135 //
00136 //     corrections for dispersion
00137 //
00138       G = (Pi*Pi/12.)*((esub-1.)/ee1)*sqrt(2.*Pi*Z0/eta0) ;
00139 //
00140 //     Cutoff frequency in GHz of first TE mode ; here h in microns.
00141 //
00142       fp = 397.887*Z0/h ;
00143 //
00144 //     dispersion-corrected dielectric constant
00145 //
00146       epeff = esub - (esub-ee1)/(1.+G*((freq/fp)*(freq/fp))) ;
00147 //
00148 //     dispersion-corrected characteristic impedance
00149 //
00150       Z0 = Z0*sqrt(ee1/epeff)*(epeff-1.)/(ee1-1.) ;
00151 //
00152 //     Attenuation - dielectric Losses
00153 //
00154       q = (epeff - 1.)/(esub - 1.) ;
00155       Qd = ((1.-q) + q*esub)/((1.-q)/Qup + q*esub/Qsub) ;
00156 //
00157       u = w/h ;
00158       Kfact = exp(-1.2*pow((Z01/eta0), 0.7)) ;     /* ?? need more thinking */
00159       g2 = 2.*Kfact/w ;
00160 //
00161 //     Assume no resistive losses - these will be taken into
00162 //     account later
00163 //
00164       Qc = MSTRIP_H_VERYBIG ;   /* just big ! */
00165 //
00166 //     Total attenuation
00167 //
00168       Q0 = 1/(1/Qd + 1/Qc) ;
00169       tandel = 0.5/Q0 ;
00170 //
00171 // Now fix up units
00172 //
00173       Z0 *= Ohm ;        /* we calculated the impedance in Ohms */
00174       g2 /= Micron ;     /* g2 has units of  1/length */
00175       epeff *= eup ;     /* we calculated relative to superstrate */
00176 }
00177 
00178 
00179 
00180 

Please direct comments and corrections to supermix@submm.caltech.edu
Go to the supermix home page
Generated by doxygen1.2.7