{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Chapter - 25 : LARGE SIGNAL OR POWER AMPLIFIERS"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Ex 25.1 Pg 734"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "ICsat=8.77 mA\n",
      "VCEsat=0.00 V\n",
      "ICcutoff= 0\n",
      "VCEcutoff=5.26 V\n"
     ]
    }
   ],
   "source": [
    "from __future__ import division\n",
    "\n",
    "VCC=10#\n",
    "R1=10*10**3#\n",
    "R2=5*10**3#\n",
    "RC=1*10**3#\n",
    "RE=500#\n",
    "RL=1.5*10**3#\n",
    "B=100#\n",
    "VBE=0.7#\n",
    "VR2=VCC*(R2/(R1+R2))#\n",
    "IEQ=(VR2-VBE)/RE#\n",
    "ICQ=IEQ#\n",
    "VCEQ=VCC-ICQ*(RC+RE)#\n",
    "rL=(RC*RL)/(RC+RL)#\n",
    "ICsat=ICQ+(VCEQ/rL)#\n",
    "print 'ICsat=%0.2f mA'%(ICsat*10**3)\n",
    "VCEsat=0#\n",
    "print \"VCEsat=%0.2f V\"%VCEsat\n",
    "ICcutoff=0#\n",
    "print \"ICcutoff=\", ICcutoff\n",
    "VCEcutoff=VCEQ+ICQ*rL#\n",
    "print 'VCEcutoff=%0.2f V'%VCEcutoff"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Ex 25.2 Pg 734"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "PP=9.61 V\n",
      "PP=20.72 V\n"
     ]
    }
   ],
   "source": [
    "from __future__ import division\n",
    "\n",
    "VCC=20#\n",
    "R1=10*10**3#\n",
    "R2=1.8*10**3#\n",
    "RC=620#\n",
    "RE=200#\n",
    "RL=1.2*10**3#\n",
    "hfe=180#\n",
    "VB=VCC*(R2/(R1+R2))#\n",
    "VBE=0.7#\n",
    "VE=VB-VBE#\n",
    "IE=VE/RE#\n",
    "IC=IE#\n",
    "VCE=VCC-IE*(RC+RE)#\n",
    "ICQ=IC#\n",
    "VCEQ=VCE#\n",
    "rL=(RC*RL)/(RC+RL)#\n",
    "PP=2*ICQ*rL#\n",
    "print 'PP=%0.2f V'%PP\n",
    "PP=2*VCEQ#\n",
    "print 'PP=%0.2f V'%PP"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Ex 25.3 Pg 735"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Ap=1375.00\n"
     ]
    }
   ],
   "source": [
    "from __future__ import division\n",
    "\n",
    "re=8#\n",
    "RC=220#\n",
    "RE=47#\n",
    "R1=4.7*10**3#\n",
    "R2=470#\n",
    "B=50#\n",
    "rL=RC#\n",
    "AV=rL/re#\n",
    "Ai=B#\n",
    "Ap=AV*Ai#\n",
    "print \"Ap=%0.2f\" %Ap"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Ex 25.4 Pg 736"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "ne=25.00 %\n",
      "power rating of transistor=20W\n"
     ]
    }
   ],
   "source": [
    "from __future__ import division\n",
    "\n",
    "Ptrdc=20#\n",
    "Poac=5#\n",
    "ne=(Poac/Ptrdc)#\n",
    "print 'ne=%0.2f %%'%(ne*100)\n",
    "print \"power rating of transistor=20W\"#"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Ex 25.5 Pg 737"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "poac=4.71 W\n"
     ]
    }
   ],
   "source": [
    "from __future__ import division\n",
    "\n",
    "pcdc=10#\n",
    "nc=0.32#\n",
    "poac=pcdc*nc/(1-nc)#\n",
    "print 'poac=%0.2f W'%poac"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Ex 25.6 Pg 738"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Ptrdc=7.00 W\n",
      "Pcdc=3.50 W\n"
     ]
    }
   ],
   "source": [
    "from __future__ import division\n",
    "\n",
    "nc=0.5#\n",
    "VCC=24#\n",
    "Poac=3.5#\n",
    "Ptrdc=Poac/nc#\n",
    "print 'Ptrdc=%0.2f W'%Ptrdc\n",
    "Pcdc=Ptrdc-Poac#\n",
    "print 'Pcdc=%0.2f W'%Pcdc"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Ex 25.7 Pg 739"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 12,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Pindc=12.00 W\n",
      "PRLdc=5.76 W\n",
      "Poac=0.72 W\n",
      "Ptrdc=6.24 W\n",
      "Pcdc=5.52 W\n",
      "no=6.00 %\n",
      "no=11.54 %\n"
     ]
    }
   ],
   "source": [
    "from __future__ import division\n",
    "from math import sqrt\n",
    "VCC=20#\n",
    "VCEQ=10#\n",
    "ICQ=600*10**-3#\n",
    "RL=16#\n",
    "IP=300*10**-3#\n",
    "Pindc=VCC*ICQ#\n",
    "print 'Pindc=%0.2f W'%Pindc\n",
    "PRLdc=ICQ**2*RL#\n",
    "print 'PRLdc=%0.2f W'%PRLdc\n",
    "I=IP/sqrt(2)#\n",
    "Poac=I**2*RL#\n",
    "print 'Poac=%0.2f W'%Poac\n",
    "Ptrdc=Pindc-PRLdc#\n",
    "print 'Ptrdc=%0.2f W'%Ptrdc\n",
    "Pcdc=Ptrdc-Poac#\n",
    "print 'Pcdc=%0.2f W'%Pcdc\n",
    "no=Poac/Pindc#\n",
    "print 'no=%0.2f %%'%(no*100)\n",
    "no=Poac/Ptrdc#\n",
    "print 'no=%0.2f %%'%(no*100)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Ex 25.8 Pg 740"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "RL1=1.80 kohm\n"
     ]
    }
   ],
   "source": [
    "from __future__ import division\n",
    "\n",
    "a=15#\n",
    "RL=8#\n",
    "RL1=a**2*RL#\n",
    "print 'RL1=%0.2f kohm'%(RL1*10**-3)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Ex 25.9 Pg 741"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "a=25.00\n"
     ]
    }
   ],
   "source": [
    "from __future__ import division\n",
    "from math import sqrt\n",
    "RL=16#\n",
    "RL1=10*10**3#\n",
    "a=sqrt(RL1/RL)#\n",
    "print \"a=%0.2f\"%a"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Ex 25.10 Pg 742"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Poac=100.00 W\n"
     ]
    }
   ],
   "source": [
    "from __future__ import division\n",
    "\n",
    "RL=8#\n",
    "a=10#\n",
    "ICQ=500*10**-3#\n",
    "RL=a**2*RL#\n",
    "Poac=(1/2)*ICQ**2*RL#\n",
    "print 'Poac=%0.2f W'%Poac"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Ex 25.11 Pg 742"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Poac=50.00 mW\n",
      "ICQ=0.01 A\n",
      "a=7.9\n"
     ]
    }
   ],
   "source": [
    "from __future__ import division\n",
    "from math import sqrt\n",
    "Ptrdc=100*10**-3#\n",
    "VCC=10#\n",
    "RL=16#\n",
    "no=0.5#\n",
    "Poac=no*Ptrdc#\n",
    "print 'Poac=%0.2f mW'%(Poac*10**3)\n",
    "ICQ=2*Poac/VCC#\n",
    "print 'ICQ=%0.2f A'%ICQ\n",
    "RL1=VCC/ICQ#\n",
    "a=sqrt(RL1/RL)#\n",
    "print \"a=%0.1f\"%a"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Ex 25.12 Pg 743"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Poac=5.00 mW\n",
      "a=7.07\n",
      "P=250.00 mW\n"
     ]
    }
   ],
   "source": [
    "from __future__ import division\n",
    "from math import sqrt\n",
    "VCC=10#\n",
    "IP=50*10**-3#\n",
    "RL=4#\n",
    "I=IP/sqrt(2)#\n",
    "Poac=I**2*RL#\n",
    "print 'Poac=%0.2f mW'%(Poac*10**3)\n",
    "ICQ=IP#\n",
    "RL1=VCC/ICQ#\n",
    "a=sqrt(RL1/RL)#\n",
    "print \"a=%0.2f\"%a\n",
    "V1=VCC#\n",
    "V2=V1/a#\n",
    "I2p=V2/RL#\n",
    "I2=I2p/sqrt(2)#\n",
    "P=(I2**2)*RL#\n",
    "print 'P=%0.2f mW'%(P*10**3)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Ex 25.13 Pg 744"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 18,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "P=16.00 W\n"
     ]
    }
   ],
   "source": [
    "from __future__ import division\n",
    "\n",
    "RL=8#\n",
    "VP=16#\n",
    "P=(VP**2)/(2*RL)#\n",
    "print 'P=%0.2f W'%P"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Ex 25.14 Pg 745"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 21,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Pindc=12.50 W\n",
      "Poac=7.50 W\n"
     ]
    }
   ],
   "source": [
    "from __future__ import division\n",
    "\n",
    "no=0.6#\n",
    "Pcdc=2.5#\n",
    "#Poac=Pindc*no#\n",
    "#Pindc=2*Pcdc+Poac#\n",
    "Pindc=(2*Pcdc)/(1-no)#\n",
    "print 'Pindc=%0.2f W'%Pindc\n",
    "Poac=0.6*Pindc#\n",
    "print 'Poac=%0.2f W'%Poac"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 2",
   "language": "python",
   "name": "python2"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 2
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython2",
   "version": "2.7.9"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 0
}
