Open Collections

UBC Theses and Dissertations

UBC Theses Logo

UBC Theses and Dissertations

The automatic recognition of intermodulation, hum and snow noise in cable television systems Gresseth, Reidar 1992

Your browser doesn't seem to have a PDF viewer, please download the PDF to view this item.

Item Metadata


831-ubc_1993_spring_gresseth_reidar.pdf [ 5.9MB ]
JSON: 831-1.0065246.json
JSON-LD: 831-1.0065246-ld.json
RDF/XML (Pretty): 831-1.0065246-rdf.xml
RDF/JSON: 831-1.0065246-rdf.json
Turtle: 831-1.0065246-turtle.txt
N-Triples: 831-1.0065246-rdf-ntriples.txt
Original Record: 831-1.0065246-source.json
Full Text

Full Text

THE AUTOMATIC RECOGNITION OF INTERMODULATION, HUMAND SNOW NOISE IN CABLE TELEVISION SYSTEMS.ByReidar GressethB. Sc. (Combined Physics and Mathematics) University of British Columbia, 1988A THESIS SUBMITTED IN PARTIAL FULFILLMENT OFTHE REQUIREMENTS FOR THE DEGREE OFMASTER OF APPLIED SCIENCEinTHE FACULTY OF GRADUATE STUDIESELECTRICAL ENGINEERINGWe accept this thesis as conformingto the required standard UNIVERSITY OF BRITISH COLUMBIANovember 1992© Reidar Gresseth, 1992In presenting this thesis in partial fulfilment of the requirements for an advanceddegree at the University of British Columbia, I agree that the Library shall make itfreely available for reference and study. I further agree that permission for extensivecopying of this thesis for scholarly purposes may be granted by the head of mydepartment or by his or her representatives. It is understood that copying orpublication of this thesis for financial gain shall not be allowed without my writtenpermission.(Signature) Department of  Electrical Engineering.The University of British ColumbiaVancouver, CanadaDate  Al9 V 1 7^19.2DE-6 (2/88)ABSTRACTA system which automatically monitors the cable television signal is proposed. Themonitoring devices, located at key areas in the television network, would alert the cablecompany to the presence of several important types of television impairments. In thisthesis, the automatic detection of three kinds of impairments is discussed; intermodula-tion carrier beats, hum modulation and snow noise. The detection algorithms we developare non-intrusive and do not require the use of test signals.A mathematical model which describes an intermodulation carrier beat is developedand the corresponding 2-dimensional Fourier transform is shown to exhibit propertieswhich are advantageous for automatic recognition. In particular, it is shown that fourpeaks will appear in the Fourier transform of the image if a beat is present. These peakspossess distinguishing characteristics which allow the automatic detection of the beat.Another television impairment, hum modulation, causes either single or double bandson the television screen depending upon the impairment's frequency. By using the theoryof orthogonal functions developed by Sturm and Liouville, a general algorithm is devel-oped which recognizes hum modulation or any impairment of a fixed and known shape.The algorithm is applied to the case of a sinusoidal hum function.Finally, snow noise, which is a random white Gaussian noise, is addressed. An algo-rithm is developed which detects these random variations by comparing each pixel in theimage with neighbouring points. Experimental verification done with several images isshown to produce good results even if the level of noise is small ( up to carrier to noiseratio of 35 dB ).iiTABLE OF CONTENTSABSTRACT^ iiLIST OF FIGURES^ viACKNOWLEDGEMENT viii1 INTRODUCTION 11.1 HISTORY OF TELEVISION STANDARDS ^ 11.2 SCANNING THE IMAGE AND THE CRT 21.3 THE NTSC STANDARD AND INTERLACING^ 31.4 PICTURE QUALITY OF THE SIGNAL 41.5 AN AUTOMATIC DETECTION SYSTEM ^ 51.6 TELEVISION IMPAIRMENT CLASSIFICATIONS ^ 51.7 RATING AND DETECTING THE IMPAIRMENT 71.8 AUTOMATIC IMPAIRMENT RECOGNITION ^ 82 INTERMODULATION 102.1 INTERMODULATION IN THE CABLE NETWORK ^ 112.2 TYPES OF INTERMODULATION^ 132.3 FREQUENCY OF THE INTERMODULATION IMPAIRMENT 142.4 MATHEMATICAL DESCRIPTION OF INTERMODULATION ^ 162.5 FOURIER, TRANSFORM OF THE MODEL ^ 182.6 AUTOMATIC DETECTION USING THE 2-D TRANSFORM^ 22iii2.7 AN ALTERNATE RECOGNITION ALGORITHM ^ 232.8 SOFTWARE ^ 252.9 EXPERIMENTAL VERIFICATION ^ 263 HUM 363.1 CHARACTERISTICS AND CAUSES OF HUM ^ 363.2 GENERAL APPROACH TO HUM RECOGNITION 373.3 THE THEORY OF ORTHOGONAL FUNCTIONS ^ 383.4 STURM-LIOUVILLE THEORY^ 403.5 HUM RECOGNITION USING ORTHOGONAL FUNCTIONS ^ 443.6 APPLICATIONS VIA FOURIER SERIES ^ 473.7 SOFTWARE ^ 483.8 EXPERIMENTAL VERIFICATION ^ 494 SNOW NOISE 574.1 CHARACTERISTICS AND CAUSES OF SNOW ^ 574.2 CARRIER-TO-NOISE RATIO ^ 584.3 FOURIER, TRANSFORM OF SNOW NOISE ^ 594.4 SUBJECTIVE RECOGNITION OF SNOW IMPAIRMENT ^ 594.5 AUTOMATIC RECOGNITION OF SNOW NOISE ^ 594.6 MODIFICATIONS TO THE DETECTION ALGORITHM ^ 624.7 OTHER POSSIBLE DETECTION ALGORITHMS ^ 634.8 SOFTWARE ^ 644.9 EXPERIMENTAL VERIFICATION ^ 645 CONCLUSION 745.1 INTERMODULATION BEAT PRODUCTS ^ 74iv5.2 HUM ^  755.3 SNOW NOISE ^  76BIBLIOGRAPHY 77LIST OF FIGURES2.1 Television Screen Dimensions  ^172.2 Fourier Transform Showing Intermodulation Peaks^ 222.3 Sample 1-D Detection Algorithm Graph ^  242.4 Ritukoen Image Without Intermodulation Noise  282.5 2-D Fourier Transform of Ritukoen Image Without Noise ^ 292.6 Ritukoen Image With Intermodulation Noise - 25 dB  302.7 2-D Fourier Transform of Ritukoen Image With Noise - 25 dB ^ 312.8 2-D Fourier Transform of Ritukoen Image With Noise - 43 dB ^ 322.9 1-D Fourier Transform of Ritukoen Image Without Noise ^ 332.10 1-D Fourier Transform of Ritukoen Image With Noise - 25 dB ^ 342.11 1-D Fourier Transform of Ritukoen Image With Noise - 43 dB ^ 353.12 The Television Screen In Terms Of A 1-D Function ^ 453.13 Experimental Frames Used by Hum Detection Algorithm ^ 503.14 Aliens Image With Hum And With A Block Removed  523.15 Aliens Image With Horizontal Motion - Cosine Inner Product ^ 533.16 Aliens Image With Horizontal Motion - Sine Inner Product ^ 543.17 Aliens Image With Vertical Motion - Cosine Inner Product ^ 553.18 Aliens Image With Vertical Motion - Sine Inner Product  564.19 Pixel Neighbourhood For Snow Detection ^  604.20 Data Image Without Snow Noise  664.21 Gorby Image Without Snow Noise ^  67v i4.22 Oldmill Image Without Snow Noise ^  684.23 Fiji Image Without Snow Noise  694.24 Fiji Image With Snow Noise - 21dB  ^704.25 Snow Noise Predictions  ^714.26 Snow Noise Predictions - Enlargement Near The Origin ^ 724.27 Relation Between X_noise And Carrier To Noise Ratio  73viiACKNOWLEDGEMENTSincere thanks go to Dr Rabab Ward for her assistance as thesis advisor and to RogersCable, Inc who supplied computer equipment for the project.viiiChapter 1INTRODUCTIONIn the last fifty years, the number of television sets being used worldwide has increasedsteadily. In more remote areas, the quality of the signal obtained directly from thetelevision transmitter may be of an unsatisfactory quality. This may be caused by manyfactors, such as overhead power lines, high flying airplanes, nearby mountain rangesor simply the distance from the transmitter. Many homes have opted to use satellitedishes to improve their reception, this can be an expensive and somewhat impracticalsolution. In urban or densely populated areas a more economical solution is the use ofa cable network for the transmission of the signal, cable also has the added benefit thatmany more channels can be made available to the viewer. Monitoring the quality of thetransmitted picture through the cable network is the topic of this thesis.1.1 HISTORY OF TELEVISION STANDARDSThe first colour television system was designed and built by .John Logie Baird in 1928,see [10]. It was another twenty five years before a standard would be adopted in NorthAmerica. This standard was developed by the National Television Systems Committee( or NTSC ) which contained representatives from many of the largest corporations ofthe day. They defined a 525 line resolution system that was colour compatible. or morespecifically, the signal was compatible on both black-and-white and colour television sets.The NTSC system is the oldest television system still in widespread use and has a poorerresolution than other popular standards such as SECANT or PAL.1Chapter 1. INTRODUCTION^ 2The television system used in France, SECAM, was developed by Henri de France.This system is quite similar to that proposed by the NTSC, however, SECAM mergesthe two colour difference signals into a single alternating signal. This produces a systemthat is less affected by small changes of phase in the transmission and propagation pathbut results in a poorer quality black-and-white picture. SECAM has undergone severalsmall changes and improvements since its initial adoption, the system presently in use isknown as SECAM IIIA, while a variant of the system used in Russia is called NIR.In 1962, Walter Bruch of the Telefunken Company developed the PAL system. PAL,which stands for phase alternation line, has been adopted in most of Europe and the restof the world. It gives a 625 line resolution which provides a superior quality picture tothe NTSC system. Also, by an ingenious method of phase alternation, the PAL systemreduces the susceptibility of colour and phase changes in the transmitted signal. PALis available in PAL deluxe, which produces more accurate colour reproduction throughaveraging, and in People's PAL, which does not include the colour averaging.1.2 SCANNING THE IMAGE AND THE CRTMost TV sets draw the television image as a series of horizontal lines using a cathode raytube, or CRT. There are exceptions, such as certain laboratory experiments, in which itis advantageous for the image to be drawn from the center outward. However, for thisdiscussion and for most commercial applications, the CRT scans individual lines fromleft to right and draws each successive line from top to bottom. Lines are divided into aseries of points, called pixels, which make up the basic picture unit.Since each line in the image is started from the left side, there is a small interval oftime after the CRT has drawn the line during which the CRT must move back to theleftmost point of the screen. This period is called the horizontal retrace time. For severalChapter 1. INTRODUCTION^ 3of the television impairments to be discussed this interval needs to be considered in thecalculations to ensure that the results obtained are accurate.Once the cathode ray tube has drawn the last line at the bottom of the screen, itbegins to draw the next image. As the image is always scanned from top to bottom it isnecessary that the CRT returns to its initial point at the top of the screen. The intervalin which the CRT moves to the initial point is called the vertical retrace time. Due tothis retrace, the CRT does not draw the final lines in the image and, consequently, the525 line resolution of the NTSC system is slightly reduced, only 480 lines will be visiblyscanned by the CRT for each image.1.3 THE NTSC STANDARD AND INTERLACINGTo produce a better quality picture, the NTSC and other standards require that thetelevision image be drawn in an interlaced format, see [13]. This means that when thefirst line is drawn the CRT doesn't start drawing the second line but rather goes to thethird line. Once the third line is drawn the cathode ray tube begins with the fifth line,and so on to the bottom of the screen. When the CRT returns to the top of the screen itdraws the second line of the same image, followed by the fourth line and so on until thepicture is completely drawn. It was found that by interlacing the image, the flicker thatis inherent otherwise is significantly reduced. If the image were not interlaced each areaof the screen would fade before the CRT returned to trace the next image, this effectwould be quite visible to the human eye.Let us calculate the actual number of lines drawn in the NTSC standard each second.Thirty frames are drawn each second at a rate of 525 lines per image. This gives525 x 30 = 15,750 lines/second.^ (1.1)The aspect ratio for most television sets is 4 : 3 and so, assuming television pixels areChapter I. INTRODUCTION^ 4square, there are 640 pixels per line. By multiplying this by the result in equation (1.1)we see that there are more than ten million pixels drawn on the screen each second.1.4 PICTURE QUALITY OF THE SIGNALAs the television signal may be quite weak unless the viewer lives within the stationtransmitter's range, several cable companies operate which provide an amplified signalto homes for a monthly fee. These companies are able to provide additional importantservices, such as more channels, pay TV and information channels. The major cablecompany in the Vancouver area is Roger's Cable, Inc.Cable companies provide their service through an elaborate series of amplifiers con-nected by coaxial cables. This network distributes the signal from the headend where thesignals are received to the cable subscribers. If any point in this network fails to workproperly the image quality will degrade.In the 1990 annual questionnaire of Consumer Reports, the readers were asked howthey would rate their satisfaction with the local cable company, see [1]. The resultswere the lowest they had found in sixteen years. Even though these complaints showedthat customer dissatisfaction was also due to price increases and billing problems, it isapparent that the quality of the picture is a very important factor to the cable subscriber.Most cable companies are aware of the need for an impairment free picture and theyexpend a great deal of effort to provide a good signal. If a problem is found the servicemenare usually able to repair the fault quickly, but in this period, the affected subscriber,who is usually the person who has reported the problem, has had his or her viewinginterrupted. Ideally, the problem should be detected and repaired before there has beenany significant interruption to the subscriber's television signal.Chapter I. INTRODUCTION^ 51.5 AN AUTOMATIC DETECTION SYSTEMTo improve the quality of the cable service, we propose that monitoring stations bedeveloped and located throughout the cable network. These stations would be operatedautomatically and would test the signal for some of the more serious types of televisionimpairments. If a particular problem is recognized a warning is sent by the device to theheadend, a serviceman is then dispatched to fix the network. If all goes well, the problemwill be located and repaired before there is any significant inconvenience on the part ofthe subscriber. The monitoring devices would provide a fast, reliable TV impairmentwarning system.1.6 TELEVISION IMPAIRMENT CLASSIFICATIONSThere are several major types of impairments that are common to the television signal,see [4]. Some impairments will only affect a single subscriber, such as those due to a faultytelevision receiver. Others will affect an entire region, for example, impairments due toextremely poor weather conditions or due to a faulty cable amplifier. Intermodulation,hum and snow noise will be discussed in chapters 2-4, while some of the other significantimpairments will be briefly described below.An interesting impairment is ghosting, a phenomenon in which a delayed version oftelevision image appears on the screen. The delayed image is visible either to the rightor the left of the original image. If the image appears to the right then this is normalghosting, the second image is generally not as strong as the main picture. If the imageappears to the left then this is called leading ghosting, the reflected image is usuallystronger than the normal signal. This impairment is caused by a strong reflected signalat the antenna site.Crossmodulation is very closely related to the phenomenon of intermodulation andChapter 1. INTRODUCTION^ 6the causes of both will be discussed in the next chapter. Crossmodulation is characterizedby the presence of a faint image on the screen due to another channel. This impairmentis produced by a converter overload or an overload of one of the headend or distributionamplifiers.The herringbone impairment is so named by the shape of the distortion that is pro-duced. The screen is filled with horizontal herringbone bands which move across thepicture. If only a few channels are affected the cause may be due to interference withlower adjacent sound frequencies, while if all channels are affected then the problemmay be due to a mistuned television set or converter. Neighbouring subscribers may beaffected depending upon the type of receiver they have.There are two types of electrical interference impairments, the broadband and theimpulse type. The broadband is characterized by a moving interference pattern, withtearing of some lines and the presence of a peppery interference across the entire screen. Itmay be caused by fluorescent lighting fixtures or by power line interference. The secondtype of electrical interference, the impulse type, is characterized by random bursts ofinterference for only a brief duration. This usually only occurs for a small number oflines and does not cause very extensive line tearing. This impairment can be caused byelectrical motors, faulty lighting fixtures, dimmer controls and by the ignition systems ininternal combustion engines.Diathermy is characterized by intermittent, usually repetitive, patterns of herring-bones shapes, reminiscent of an elongated S. This impairment tends to affect only chan-nels two, six, seven, and thirteen and occasionally channel three. Typically, diathermyis caused by appliances such as microwave ovens or by certain devices used in hospitals.Additional disturbances can be caused by overhead airplanes or by poor weatherconditions. However, cable companies are most concerned with those types of impair-ments that arise in the cable system and can be readily fixed, and accordingly, most ofChapter 1. INTRODUCTION^ 7this discussion will deal with those impairments that were fundamental concerns to ourlocal cable company, Roger's Cable. For example, of primary importance are picturecarrier beats, which are a form of intermodulation. These beats may affect an entireneighborhood and can be very annoying to the subscriber.1.7 RATING AND DETECTING THE IMPAIRMENTThere have been a number of experiments done on television impairments in which theseverity of each type of disturbance is rated. Typically, the approach has been to takea selection of viewers and ask them to rate the disturbance in terms of how annoyingthey feel it is. This subjective approach has been studied in a number of instances, see[3]. Although this thesis is more concerned with methods of detecting and rating theseimpairments without the aid of a human viewer, it is important that the predictions madeby the monitoring devices coincide with the ratings found using the subjective approach.Several methods of monitoring and recognizing television impairments have been stud-ied, for instance, a mechanical simulation of the human eye was used to rate the severityof television impairments in [16]. This approach, while reasonably successful, requireda fairly restrictive testing environment. Another possible solution is to hire engineeringfirms to assist the cable company in rating the quality of the signal, see [15]. This latterapproach could be inconvenient since it involves visits by the engineers to subscribershomes in order to test the quality of the signal.An approach for automatic detection that could be considered is the introduction tothe cable system of a test signal. There are certain time intervals, in particular, thehorizontal and vertical retrace times in which the cathode ray tube does not draw on thescreen. During these periods, the cable company could arrange to send a predeterminedsignal to the detection devices. If the device finds any difference between the receivedChapter 1. INTRODUCTION^ 8signal and the expected pattern then it knows that some type of distortion is present.Also, since the expected signal is known it is much easier to determine the manner of theimpairment, in particular, taking the difference image will give the impairment withoutany underlying image to affect the prediction.A variation of the test signal approach involves digitizing the received signal, pro-tecting it with a high order correction code and then sending it back through the samenetwork if a return path exists or through a second network to the cable headquarters.The image, once reconstructed and displayed on the screen, could be studied by an em-ployee who would have no difficulty in seeing whether impairments were present in thesignal or not. This would be a very simple solution to the problem, the employee couldinstantly see the image that has been received at any point in the network without leav-ing his or her office. The cable company could locate any problem themselves or couldverify reports of a problem from their customers.1.8 AUTOMATIC IMPAIRMENT RECOGNITIONOur aim is to develop impairment recognition algorithms which can be implemented in"black box" devices located throughout the cable network. The devices would monitorthe signal and report the existence any type of television noise to the cable company.Primarily, it is important that the monitoring devices operate with the least possiblealteration to the existing cable network. For example, there would have to be significantredesign of the broadcasting equipment to be able to send a test signal during the hori-zontal or vertical retrace periods. There are currently three lines in the vertical retracetime reserved for test signals but this is not enough information for impairment recog-nition, especially if more than one impairment is present in the signal at the same time.Chapter 1. INTRODUCTION^ 9Therefore, the remainder of the discussion will assume that the detection devices are self-contained and do not require test signals or any other modification to the existing cablesystem. The image that is received via the network is the only available information thedevice will have and the prediction must be based entirely upon means independent ofhuman interaction.The goal is to devise detection algorithms that will effectively monitor the signalwithout lengthy calculations. Since the NTSC system transmits 30 frames per secondand all but the simplest algorithms require more than 1/30th of a second to compute,it is apparent that the device will not be able to test each image, the device wouldtest every second or third ( or more ) frame that is transmitted. The interval betweenthe images that are tested should be as small as possible, since statistically, a greaterdegree of accuracy is obtained by using more data samples. We will, for example, discusstwo algorithms for detecting intermodulation distortion, one uses the two dimensionalFourier transform and the other uses the one dimensional Fourier transform. The latteris preferred since fewer calculations need to be performed while the algorithm producesonly slightly less accurate predictions.Chapter 2INTERMODULATIONLet us consider the properties of an intermodulation carrier beat and the various effectsthis impairment has on the television picture. As will be seen, intermodulation hasseveral forms, from picture carrier beats to composite triple beats, in addition, thereis a close relationship between intermodulation and crossmodulation. We will developalgorithms which automatically detect the picture carrier beat, which is the basic formof intermodulation and appears on the screen as a series of diagonally parallel lines, fromthe image itself.Television programs that are available through cable systems come from many diversesources. Each program occupies a different range of frequencies, called a channel. Thesechannels are combined at the headend of the cable system. The system forms a wideband multichannel signal of up to eighty channels. Cable companies transmit this signalto thousands of households through an elaborate network where amplifiers are cascadedevery half mile ( or less ). These amplifiers, never perfectly ideal, may produce certaindistortions due to their nonlinear transfer function.Intermodulation implies the mixing of the desired signal with one or more unwantedsignals. This may happen through any of the nonlinear elements in the system; thetelevision transmitter, the receiver or in one of the amplifiers. Due to the large numberof amplifiers used in the network, the study of intermodulation becomes very meaningfulfor cable television signals.10Chapter 2. INTERMODULATION^ 112.1 INTERMODULATION IN THE CABLE NETWORKIntermodulation is most significant if the nonlinear device has a characteristic of oddorder, most prominently for third or fifth degree distortion. If one or more unwantedsignals is present simultaneously in the television's input then intermodulation or cross-modulation may result. The former impairment will appear as a series of diagonal lineswhile the latter will produce a faint image from the unwanted channel.For example, let us assume that the television signal can be described by the super-position of the two functions^(t) v^i (t) cos [w i t + 01 (0]^ (2.2)x 2 (t)^v 2 (t) cos[w2 t + 02 (0] (2.3)where x i (t) is the intended signal and x 2 (t) is the unintended signal. Both of these signalsare combined and passed through a nonlinear device which has a characteristic of thethird degree, producing the equation[x i (t) + x2(t)] 3 =^vi (t) ( 3 co s[wi t + 0 1 (0] + cos [3w i t + 30 1 (t) ]) / 4+ 3q(t)v2 (t) cos(2w i t + w2 t + 20 1 (0 + 0 2 (0)/4+ 3t4(t) v2 (t) cos ( 2w i t — w 2t + 20 1 (0 — 02 (0)/4+ 3q(t ) v2 (t ) cos (w2 t + 0 2 (0) /2+ 3v i (t)v(t) cos(2w2 t + w i t + 2 02( t) + 01 (0) /4+ 31) 1 (t) v (t ) cos(2w2 t — wi t + 202(0 — 01 (t) ) /4+ 3v i ( t )v (t) co s (wi t + ¢ i (t))/2L'(t)( 3 cos[w2t + ¢2(t)] + cos[3w2 t + 3¢ 2 (t)])/4.^(2.4)The first two terms in equation (2.4),^14(0( 3 cos(w i t^+ 01(0) + cos(3w 1 t + 30i(t)))/4^(2.5)Chapter 2. INTERMODULATION^ 12are simply the value of the signal x 1 (t) when transformed by the nonlinear device, thatis, they are equal to xi(t). It should be apparent that the last two terms, equal to 4(0,like equation (2.5), are of little interest. The second line in equation (2.4),14(t)v 2 (t ) co s (2wit w2t 201(0 + 02 (0) /4^(2.6)will appear as intermodulation if 2w 1 W2 is within the passband of the cable amplifier.Similarly, the third line of equation (2.4)3v1(t)v 2 (t) cos(2w i t — w2t 201(0 — 02(t))/4^(2.7)appears as intermodulation if 2w 1 — w2 is within the passband of the amplifier. The fifthterm in equation (2.4)34(t)v 2 (t) cos(w 2 t^02 (0)/2^ (2.8)is the crossmodulation term. Note that the crossmodulation term has a frequency equal tothe frequency of the signal in equation (2.3) while its amplitude becomes a combinationof both the signals. If the signal has crossmodulation impairment this simply impliesthat the unwanted signal is re-radiated. Since intermodulation occurs at an entirely newfrequency this type of disturbance is considered to be more serious than crossmodulation.As stated, the combination of the signals x i (t) and x 2 (t) produce intermodulationcomponents if the output device has a nonlinear characteristic of degree three. Thefrequencies 2w 1 f w2 and 2w2 f w 1 are the frequencies of the intermodulation distur-bance. However, this is the simplest case in which intermodulation may result. Ratherthan a single unwanted signal there may be several signals causing the interference andintermodulation distortion may be added at any or all of the nodes in the cable network.We will consider the more general case in which there are three channels at frequenciesw 1 , w 2 and w3 . Once again, intermodulation will result from the cross terms that have aChapter 2. INTERMODULATION 13frequency which is within the passband of the cable amplifier. These will be(-02^w3 (2.9)w2 (2.10)where each of the indices can be permuted to form additional intermodulation frequencies.We can further generalize these results to include the case of the mixing of signals inan output device which has a characteristic of degree five. Although the fifth order termswill make a smaller contribution than the third order, they may still add significantly tothe intermodulation component of the signal. Let us consider the merging of five channelswith frequencies w 1 , w2 , w3 , w4 and w 5 . They will produce interference components withfrequenciescol w2 w3^w5^ (2.11)2w1 w2 w3 w4 (2.12)3w1 f co2 f w3^(2.13)3w1 f 2w 2^(2.14)Once again, the indices can be permuted to provide other possible frequencies at whichintermodulation may occur.2.2 TYPES OF INTERMODULATIONIntermodulation is classed under several different categories depending upon how thedistortion affects the television picture. The first type is the picture carrier beat. Thisis characterized by horizontal or diagonal intensity bands across the screen. Dependingupon how close the interference frequency is to the picture carrier, these beats can beeither narrow or quite broad ( the nearer to the carrier the wider the band ). The carrierChapter 2. INTERMODULATION^ 14beats can be caused by an overdriven amplifier or they may be caused by interferencefrom the radio frequencies used by taxicabs. In the latter instance, the problem will beintermittent as taxis approach the vicinity of the television receiver.A second kind of intermodulation distortion is called low frequency colour beats. Thistype of noise is characterized by broad bands of colour variation on the screen. Colourbeats may cause noticeable changes in colour, where for example, greens become yellow orreds become orange. As with picture carrier beats, this intermodulation impairment canbe due to an overdriven cable amplifier or can be caused by interference of the televisionsignal with the radio frequencies of taxicabs. In the case of colour beats, the frequencyof the interfering signal falls near that of the colour carrier of the victim channel.The final example of intermodulation is the composite triple beat. This type ofintermodulation is due to the cumulative effect of hundreds of third and fifth orderintermodulation beat products. This impairment is characterized by a graininess or atexture effect over the entire picture. Triple beats usually have the appearance of causinglines to tear in portions of the image.2.3 FREQUENCY OF THE INTERMODULATION IMPAIRMENTIn this thesis, we will consider the case in which intermodulation consists of a single beatproductAt cos(wtt Ot )^ (2.15)with angular frequency W t . The superposition of this impairment and the victim signalfo (t) results in the sumft (t ) = fo(t) + At cos(wt t + 4t).^(2.16)Chapter 2. INTERMODULATION^ 15and when painted on the TV screen becomes the function f (x, y). We will study therelationship between ft (t) and the function f (x, y) which describes the two dimensionaltelevision picture.To model the received signal in terms of the television picture it is necessary tounderstand how the cathode ray tube draws the image on the screen. The CRT tracesthe image in an interlaced format that is designed to reduce flicker. The beam drawslines horizontally across the screen, beginning with the top line and preceding to everyother row. When the ray reaches the bottom of the screen the CRT moves up to thesecond line and traces the remaining parts of the image. By this method, the image isactually drawn in two complete segments called fields, each field consisting of the set ofodd or the set of even lines in the image.The impaired image along each horizontal line is the superposition of the originaltelevision image f0 (t) and a sinusoid term corresponding to the intermodulation beatproduct A cos(cox t + 0). The last term when drawn on the screen will be assumed to havethe angular frequency cox and an unknown phase, which, for simplicity, we will assumeis zero when the CRT begins to scan the image. In other words, with y = y o held fixedeach line on the screen isf (x, yo ) = fo(x, Yo) + A cos(wxx + Oyo ). (2.17)The phase of the harmonic Oyo will depend upon the width of the image and upon thevertical position of the line being drawn. The frequency of the intermodulation in the onedimensional signal, co t , will not be the same as the frequency cox . The latter frequencywill depend upon the size of the screen being drawn and by the rate at which the imagesare drawn.For example, given a 30 Hertz interlaced frame cycle we have30XYtx =  ^ (2.18)AxAyChapter 2. INTERMODULATION^ 16where X and Y are the horizontal and vertical lengths, respectively, of the screen. Thisequation is only true for the interval in which the CRT is tracing the initial row of theimage. However from this, we can use the expression w tt = wxx to givewtAxAtxwtt — ^ = wx x.30XYThus the relationship between w t and ws is(2.19)(2.20)As an example of the above formula, let us define X = 640 and Y = 525. If we setcos = 7r/2 this givescot = (30)(640)(525)(7r)/2 = 1.58 x 10 7 Hz^(2.21)2.4 MATHEMATICAL DESCRIPTION OF INTERMODULATIONIn order to mathematically construct a model of the intermodulation impairment we willfirst separately look at the noise contribution of each horizontal line. An equation whichdescribes the noise can be easily obtained by combining each of the separate components.To facilitate our model, it will be useful to introduce a few definitions. Let X and Y bethe horizontal and vertical lengths of the television image. Let X' be horizontal lengththat would be drawn if the CRT retrace period was zero. Likewise, let Y' be the lengththat would be drawn if vertical retrace period was zero. See figure 2.1 for details. Also,let us define the rectangle function to be1, if x > a and x < b;rect a , b (x)^0, otherwise.^ (2.22)AxAywt= 30XYThis function will be used as the final step in the derivation to set all values outside thescreen image to zero.Chapter 2. INTERMODULATION^ 17line 0line 263line 1line 264line 2Y^^Y'^Figure 2.1: Television Screen DimensionsWe now describe f (x, y) when ft (t) = At cos(wtt). If we consider the first row of theimage, that is, we assume that the CRT is scanning the top line when t = 0 then thisline can be expressed mathematically byf (x, 0) = A cos(wsx).^ (2.23)Once the CRT has drawn the first line, it bypasses the second line and begins tracingthe third. We must now recognize that the phase at the point x = 0 will no longer bezero, it will be equal to the angle when the CRT is at the rightmost point of the firstline, that is, when x = X'. Setting f(X', 0) = 2Ay) givesf (x 2Ay) = A cos(wxx coxX 1 )^ (2.24)It can be seen that until the CRT begins its vertical retrace the intermodulation for eachline can be described by the general equation, with integer n,f (x. 2nLy) = A cos(wsx nwsX')^ (2.25)X'After the CRT has completed the vertical retrace it begins to draw the remaininglines in the television image. Starting with the second line from the top of the screen theChapter 2. INTERMODULATION^ 18beam will trace every even line until the image is completely drawn. The phase at thepoint f (0, Ay) will not be zero but will be equal to the value of the phase at the bottomcorner of the image f (0, Ay) = f (X', Y' — 1), this givesf (x, Ay) = A cos(wxx wx(1/1 — 1)X' )^(2.26)The intermodulation impairment can now be represented for each line, by summationover the entire screen. The first set of terms will represent the odd rows of the imagewhile the second set will represent the even numbered rows. The intermodulation carrierbeat can be modeled by the following two dimensional functionf(x,Y) - A cos(wxx 2 AY  )recto ,x(x)recto,y(Y)E 8(x — k Ax)6(y — 2j Ay)3,1ccoxyX' cosX' (Y/ — 1)+ A cos(wrx^2Ay^20y^)rEcto x(x)recto,x (y)'> 8(x — kAx)8(y — 2jLy + Ay) (2.27)3 ,kIt should be noted that equation (2.27) is considerably more complex than it wouldbe if interleaving did not occur. Another consequence of the interlaced signal is that if weconsider the vertical frequency of the intermodulation component we find that this signalis quite sensitive to any changes in the value of wx . This will become more apparent oncethe Fourier transform of this function has been derived.2.5 FOURIER TRANSFORM OF THE MODELWe will now study the Fourier transform of equation (2.27). The Fourier transformprovides great insight into the relation between intermodulation and the frequency w x .To facilitate the calculation we can state some basic Fourier transform and convolution(E6(u — 2r7r )8(v — 72211-7 )e—zvAY )n,m Ay^Ay(2.29)Chapter 2. INTERMODULATION^ 19relations :+ by + c)) = 271-2 (S(u — a)S(v — b)e ic + 8(u + a)S(v b)e-")(rect„, b (x)) = (a + b) exp(iu (b —2a) )sinc((a2 b)u)a(E 6(x ak b)) = ciub E 6(u - 2n7r)a8(x — a) 0 (5(x — b) = 8(x — a —^ (2.28)where a denotes the Fourier transform and 0 the convolution operator.We take the Fourier transform of each of the products separately in our model, equa-tion (2.27), to produce the expressionwxX12Ay^))t (f(x, y)) = 27 2 (8(u — wx )6(v wsX' ) 80.1 cox )(5(v2Ay• (XYCi (* )-i(lx.) sinc( 11 -j--( )sinc( 12-1:))2^9(E 6. (u 2n7 )6(v m7r )\)Ax^Aywx_r ^+ 27r 2 (8(u — cox )6(v ^ )e^2,2A.Ay^c4., X'^-i xiry, + 6(u + co,)6(v  ^`'2Ay4,s) 6^2 ^)(xyci(q-c+q:^UX .^vY)Sin^2 )s lnc(n,mwhich gives the full transform of the intermodulation model asN,ME 272xyci((.--wx-224(v-4-1-1)*)n,mx sinc((u —^2nr)X)sinc((v wsX' mir Y2Ay Ay 2 )Ax 2icesX'(Y 1 —`1) x (1 + e^20y^e i(v--1-nr)AY)N,M+ E 271-2xy,---((u+-s+-2t-;)§+(o+*-En) )=n,mChapter 2. INTERMODULATION^ 202n7 X^wxX' mir Ysinc((u co z.^Ax ) 2 )sinc((t ,^2Ay^zyy-))itex X / (14 -1) X (1^e^2Ay^i(V+ (2.30)The Fourier transform, as can be seen, is composed of the sum of a countable numberof terms. Rather than examining each term in its entirety, we will look at select termsin the equation. By doing this, much insight into the properties of intermodulationdistortion can be obtained. Let us consider the case in which n = 0 and m = 0. Thefirst term of interest will beX .^wsX' Y27r 2XYC i((14-wx)+(u-^))L.2 ) 3i17,C((li — Ws ) — )sznc((v2,6,y^) 2 ).^(2.31)2This term is made up of a product of very narrow sinc functions ( assuming X is large )with a single peak at the point (u, v) = (w x , izE), the value of the point will be 2ir 2XY.This peak depends only on the values of X and Y and so we see that the larger thedimensions of the television screen the larger the height of the peak. Also, since X andY appear as variables within the sinc functions we see that the larger these values thesharper the peak will become ( the peak approaches an impulse function as X and Y nearinfinity ).As the frequency of the intermodulation changes, the amplitude of the peak does notchange but its position does. In fact, by substituting u for w x we see that v = uX720yis the equation of a straight line. As the frequency changes the peak will move along thisline, its slope leaning sharply toward the vertical.The next term of interestw^Y\ X X^wx-X' Y27r 2XY^2Ay ) 2 ) sinc((u — coz.)-2)sinc((v2L‘y ) 2 )iwx .30(1"-1) itt c,,,T2L-1x e^2Ay^c k^20y^w (2.32)also has a single peak at the point (u, v) = (w x , ltl--(;), however, the value of the term atthis point, i.e., 27 2XY exp(iwsX'(Y' — 1)/2Ay), is not solely dependent upon X and Y.Chapter 2. INTERMODULATION^ 21When both these terms are added the result will be a complex number with magnitudeproportional tocos2(o),X'(V — 1))4Ay(2.33)The value of the peak can be as much as 471- 2XY or as little as zero. Considering that X'and Y' are generally quite large, any small change in the frequency can mean dramaticchanges in the magnitude of the peak.The case in which m = 1 is only slightly different, here the magnitude of the twoterms will be2 Wx XI (1/1 - 1)sin (^40y^) (2.34)and the origin of the peak will be shifted a distance 7/2Ay from the peaks formed in the= 0 case. As in equation (2.33), changes in frequency will cause the magnitude of thepeak to alternate between its maximum, 47r 2XY, and null.The Fourier transform, then, can be imagined as an series of peaks, where each peakhas one of two heights. As the frequency changes each peak will move along parallel lineswith periodic variations in its magnitude. All peaks will have a symmetric twin aboutthe origin and the distance between vertically neighbouring peaks will be i-ry . As in figure2.2, the intermodulation peaks in the Fourier transform appear as a single point in eachquadrant.If we look at the area bounded by the rectangleox < u < ts- and —ty vwe see that the Fourier transform will always have four peak points contained within thisarea. These points will form a rhombus with the center at the origin and the distancebetween two vertical points equal to half the height of the screen.These points do not necessarily have nonzero values, the frequency may be such thatthe magnitude of two of the peaks will be zero. However, we know that if the symmetricChapter 2. INTERMODULATION^ 22co27rAy2IrAxFigure 2.2: Fourier Transform Showing Intermodulation Peakspeaks have a null value then the other two will be at their maximum. If a peak is notfound in one quadrant of the rectangle then one may be found in one of the adjacentquadrants, this neighbour will be at its maximum.2.6 AUTOMATIC DETECTION USING THE 2 -D TRANSFORMFrom the above we see that the two dimensional Fourier transform can be used to auto-matically detect intermodulation impairment. In general, a real image will have a Fouriertransform in which all nonzero points are clustered near the origin. An image with inter-modulation impairment should have a transform that consists of points clustered aboutthe origin and four strong peaks forming a rhombus somewhere outside this center region.A device may automatically detect the presence of intermodulation simply by lookingfor this parallelogram of points, for example, a transform similar to that depicted infigure 2.2. This can give a very reliable indication as to whether intermodulation noiseis present in the image or not. Another benefit is that knowing the position of the peakswill allow the system to calculate the actual frequency of the intermodulation distortion.Chapter 2. INTERMODULATION^ 23Of course, there are a few special cases for which the apparatus must be aware. Asdiscussed, the peaks need not have nonzero values and the system must test at least twoadjacent quadrants of the Fourier transform. If a peak is not found in the first quadrantthen this does not mean that intermodulation is not present. Also, the intermodulationmay be very near the origin so that the peaks appear within the cluster of points formedby the real image. In this latter case, the system may not be able to properly detect theimpairment.Another problem with using the two dimensional Fourier transform is that the peaksmay occur midway between two pixels. If the screen image is large, that is, if X' and Y'are large numbers, then we know that sine functions will be very narrow and each of thefour peaks will be similar to an impulse function. A peak occurring midway between twopixels may have a large value but may also be small or even zero at the pixel points.2.7 AN ALTERNATE RECOGNITION ALGORITHMAn alternative method for detecting intermodulation noise involves using the one dimen-sional Fourier transform on lines of the image. This has several advantages, in particular,since the number of calculations that must be done to obtain the transform in one di-mension is much less there will be a dramatic decrease in the amount of time required forthe device to process the image. An algorithm that looks at small sections of the imageand requires a fraction of the time to calculate has significant advantages.This second algorithm is based on the fact that if the intermodulation is present inthe image then it will be present in each line of the image. By looking at the Fouriertransform of each line we should have a good indication of whether the image containsintermodulation impairment or not. This may not be as good an indication of the impair-ment as the two dimensional algorithm but the benefit of faster calculation time shouldChapter 2. INTERMODULATION^ 24F(u)0Figure 2.3: Sample 1-D Detection Algorithm Graphoutweigh the slightly less accurate result.Let us define the set of functions which describe the horizontal lines of the imageas fi (x) = y) where i = y/Ay. Then let us take the absolute value of the Fouriertransform of line i, that is,Fi(u) = If fi(x)exp -2"x dxj (2.35)By taking the absolute value of the transform we ensure that the real values and theimaginary values are counted equally, this is especially important since the amplitude ofthe result is much more important than the separate components or the phase.One may be tempted now to simply say that we can look at the first line only,i.e., Fo (x), to test for intermodulation distortion. But we must remember that we aredealing with an unknown image with or without an impairment of unknown frequencyand thus it is impossible to distinguish an intended frequency from an unintended one. Ifintermodulation is present in the image then the algorithm can detect this by summingthe values of Fi (u). If we defineF(u) =^Fi(u) (2.36)then F(u) should be a good indicator of the presence of intermodulation. If intermodu-lation exists then we should expect to see a graph similar to figure 2.3.If the image does not have an intermodulation component then, generally, the func-tion F(u) will be zero or near zero at points outside the origin. This is similar to thecase of the two dimensional Fourier transform where most of the nonzero points in theChapter 2. INTERMODULATION^ 25transform are concentrated near the origin for physical images. If the image does havean intermodulation component then, hopefully, the frequency is large enough so that theintermodulation peak appears outside the neighborhood of the origin, and away fromall other nonzero points. Since points near the origin should be ignored, an appropriatethreshold value should be selected such that if a peak is found with a frequency less thanthe threshold it is assumed to be part of the original image.2.8 SOFTWAREThe detection algorithms have been simulated on computer rather than constructingthe monitoring devices, this is more practical until the algorithms have been thoroughlytested. Programs have been written which implement both the simulation of intermod-ulation impairment and the detection algorithms, as well, several grey scale images havebeen used. The images are discussed in the next section.To add intermodulation to an image the program add_intermod was written. Thisprogram utilizes the Utah raster toolkit, this package reads run length encoded imagefiles and can be run in most UNIX environments. The frequency of the intermodulationimpairment to be added is given, in radians, as a command line option. The programadds intermodulation distortion to the image using equation (2.27), being careful toensure that the pixel values remain between zero and 255. Addintermod prints thesignal-to-noise ratio to standard error.As many programs exists already which calculate the 2-I) Fourier transform of animage, no software has been written for this purpose. Since the 1-D Fourier transformalgorithm requires more custom calculations, the program iiitermod_detect has been writ-ten. This program uses the Utah raster toolkit library and reads the same file format asadd_intermod. The program assumes that the image is 512 by 512. and indeed, the fastChapter 2. INTERMODULATION^ 26Fourier transform algorithm, see [17}, requires that the image have dimensions which areboth powers of two.2.9 EXPERIMENTAL VERIFICATIONSimulation has shown that our methods are effective in determining whether an imagehas been impaired by intermodulation or not. The peaks formed by intermodulationin the function F(u) or by the 2-D Fourier transform are apparent whether the noiseis severe and but only slightly less so if the impairment is marginal. The height ofthe intermodulation peak will be dependent upon the severity of the impairment, inparticular, a larger intermodulation component will produce a higher peak.The image used for experimentation is called Ritukoen. This image is shown in figure2.4 and is a grey scale image of size 512 by 512. The corresponding two dimensionalFourier transform is shown in figure 2.5. The darker points correspond to values inwhich the transform is equal or near zero. The bright area about the origin implies thatthe image contains strong low frequency components, which is typical of most images.Intermodulation impairment with a carrier-to-noise ratio of 25 dB was added to theimage, the carrier-to-noise ratio, a measure of noise, is defined in chapter 4. Note thediagonal lines, characteristic of carrier beats, that have appeared in the image shownin figure 2.6. The corresponding Fourier transform is shown in figure 2.7, this image isnearly identical to the transform of the image without noise, figure 2.5, we see the samecluster of points near the origin. The one discernible difference is that four peaks, forminga rhombus, appear in the image. This is as predicted, adding intermodulation producesthese points and from their position the frequency of the impairment may be calculated.The Ritukoen image was tested by adding intermodulation of a carrier-to-noise ratio of43 dB. The Fourier transform of this image, see figure 2.8. shows the same four peaks.Chapter 2. INTERMODULATION^ 27Note that the peaks are seen very dimly at the same positions as those in figure 2.7.The graph in figure 2.9 shows the result of applying the 1-D Fourier transform algo-rithm to the Ritukoen image. The nonzero points near the center, or origin, correspondto low frequency components in the image. Any intermodulation impairment will appearas a pair of peaks away from the center. This graph correctly shows that intermodulationis not present in figure 2.4.In figure 2.10 and figure 2.11 the 1-D Fourier transform algorithm has been appliedto the Ritukoen image with varying degrees of intermodulation distortion added. Thefirst graph, figure 2.10, was produced from the image with a carrier-to-noise ratio of 25dB. Note that the intermodulation peaks appear symmetrically about the origin and arelarge indicating that the intermodulation impairment is very severe. The second graph,figure 2.11, was produced from an impaired Ritukoen image in which the carrier-to-noiseratio was 43 dB. The intermodulation peaks are much smaller in this latter case, showingthat the impairment is not significant ( but may still be visible in the image ).Other example images have been tested with good results. The first algorithm pro-duces a trapezoidal set of peaks surrounding the origin, the distance being dependentupon the intermodulation frequency. The second algorithm produces two solid peaksabout the center which can also be easily detected. The latter should be the preferredmethod since fewer calculations are required, in particular, there will be log e N/N =log e 512512 fewer computations, see [17].Chapter 2. INTERMODULATION^ 28Figure 2.4: Ritukoen Image Without Intermodulation NoiseChapter 2. INTERMODULATION^ 29Figure 2.5: 2-D Fourier Transform of Ritukoen Image Without NoiseChapter 2. INTERMODULATION^ 30Figure 2.6: Ritukoen Image With Intermodulation Noise - 25 dBChapter 2. INTERMOD ULATION^31Figure 2.7: 2-D Fourier Transform of Ritukoen Image With Noise - 25 dBChapter 2. INTERMODULATION^ 32Figure 2.8: 2-D Fourier Transform of Ritukoen Image With Noise - 43 dB3e+06 "no intermodulation"2.5e+062e+061.5e+06le+06500000100^200^300^400^500Figure 2.9: 1-1) Fourier Transform of Ritukoen Image Without Noise3e+062.5e+062e+061.5e+06le+06500000"25dB intermodulation"0^1 00^200^300^400^500Figure 2.10: 1-1) Fourier Transform of Ritukoen Image With Noise - 25 dB3e+06 "43dB intermodulation"2.5e+062e+061.5e+06le+06500000I^ I^ I100^200^300 400 500Figure 2.11: 1-D Fourier Transform of Ritukoen Image With Noise - .13 dBChapter 3HUMAn important type of impairment, according to many cable subscribers, is hum modu-lation. This is primarily due to the fact that hum produces a rather annoying, slowlymoving band that can be very distracting to the viewer. For cable companies, this im-pairment is of interest as it usually results from within the cable network and affects alarge number of homes.3.1 CHARACTERISTICS AND CAUSES OF HUMHum is characterized by faint hands moving up the screen. The bands will move slowly,at a rate of the height of the screen every half dozen seconds. The number of bands whichappear on the screen at one time has a direct relation to the frequency of the impairment.There are two main types of hum, classified by the different frequencies in which theyexist. The first kind, called 60 Hz hum modulation, is characterized by a single band onthe screen, see figure 3.14. The band moves up the screen, another band will reappear atthe bottom only when the previous band has disappeared at the top. The second typeof hum, called 120 Hz hum modulation, consists of two bands moving up the screen. Anew band will appear at the top only when the top band disappears, so that, two bandsalways appear somewhere on the screen.To determine some of the characteristics of hum we may visualize how the impair-ment is formed as an image on the television screen. The television scans an image byinterleaving the signal, that is, it draws every other line of the image until it reaches36Chapter 3. HUM^ 37the bottom. The remaining lines are drawn lines after the CRT has returned to the topof the screen. This means that, every second, the CRT will scan the entire televisionscreen 60 times. We know that in the case of 60 Hz hum modulation, there will be 60cycles completed every second, two cycles will appear in each image that is drawn on thescreen. Consequently, if the hum produces a band at a particular point on the screen forone image then this band will appear at the identical point when the CRT next scansthe field. The frequency of the hum is not precisely 60 Hz so this synchronization is notexact. This is particularly apparent by observing that since the hum produces a bandthat moves up the screen, its frequency must be slightly larger than 60 Hz.There are several causes of hum modulation. The first, which only operates at afrequency of 60 Hz, is due to a defective TV set power supply. In this case, the problemwill affect the local subscriber and will not be present on neighbouring televisions. Adefective TV power supply must be fixed by the subscriber himself, and so is of littleinterest to the cable company. Other possible causes of hum noise are an overloadedpower supply or low AC power voltage in the cable distribution system, both of theseproblems may appear in the cable network.3.2 GENERAL APPROACH TO HUM RECOGNITIONThe aim is to develop a system that will monitor the cable signal for the presence ofhum. Once the system detects hum, it should inform the cable company. There areseveral difficulties in doing this automatically, in particular, since hum is a low frequencyimpairment, it is not easy to distinguish the hum from the actual image. The detectionsystem cannot simply study a small section of the image, the pertinent information maybe contained over the entire picture.The monitoring devices are, therefore, forced to consider the complete image in theChapter 3. HUM^ 38calculations. It is possible that even this will not be sufficient information, the originalimage may possess a significant component at the 60 Hz or 120 Hz frequency. In thiscase, further information may be obtained by comparing properties of the image withcharacteristics of preceding images. The approach that we will take will look for changesin the image due to the moving band. Since the eye can more readily distinguish hum bythe upward movement, it seems reasonable that this is the best approach for an automaticdetection system as well.The algorithm will first be developed from very general assumptions. Once the theoryis formed we can look at more specific examples, in particular, the case in which the hummodulation is a sinusoidal wave. This approach should give a clearer understanding ofthe fundamental aspects of the theory.3.3 THE THEORY OF ORTHOGONAL FUNCTIONSLet us introduce some results from the theory of orthogonal functions, a theory that issimilar to matrix algebra, see [6]. An inner product is defined, in a general linear space,as a scalar function of two elements of the space satisfying certain axioms, in particular,to each pair f and g in the linear space there is a number (f,g), satisfying the following:(f, f) > 0^for every f (3.37)(f, f) = 0^if and only if f = 0 (3.38)( f, g) =- (g, f)^for every Lg. (3.39)(af^3g,h) = a(f,h) + 3(g, h) (3.40)(Lag + /3h) = ce(f, g) + 3(f. h) (3.41)These properties of an inner product imply little in terms of the exact definition ofthe function, the inner product may be a sum, an integral or some other relation. ForChapter 3. HUM^ 39the purposes of this thesis we will assume that the inner product will always be of theformI f(x)g*(x)r(x)dx^ (3.42)where r(x) is a weight function with a positive value for each point in the domain.Two functions, f and g are said to be orthogonal if and only if they are both nonzeroand(f, g) = 0The functions are orthonormal if the additional relations are true(f, f ) = 1and(g,g) = 1(3.43)(3.44)(3.45)Note that if f and g are orthogonal then f /If 1 2 and g/ 1g1 2 are orthonormal.The number of linearly independent functions which can be orthonormal to each otheris equal to the dimensions of the inner product space. For the function sets that we willbe considering the dimensions are countable, that is, the space is spanned by a countablyinfinite set of functions. We state the following theorem.Theorem 1 If r 1, 2^On form an orthonormal basis for an n-dimensional linearspace V, then every f in V is of the formf = E akok^ (3.46)k= 1where a k = (f, ch k ).Chapter 3. HUM^ 403.4 STURM-LIOUVILLE THEORYThe Sturm-Liouville Theory introduced below provides a very powerful method in whichan arbitrary periodic function can be detected in a television signal, see [6]. Any differ-ential equation that can be written asdyc7;(P(x).-c6) q(x)y + r(x)y 0 (3.47)is called a Sturm-Liouville equation, see [6]. The functions p, q, and r must be realvalued and continuous in the interval a < x < b, p must be continuously differentiableover the same interval, and both p(x) and r(x) must be positive for all values in thedomain. These assumptions do restrict the equation somewhat, however, we can see thatby differentiating the first term and dividing by p(x)y„ p'(x)y' q(x)y )r(x)y = 0p(x) p(x) p(x)that the equation is still fairly general.Depending upon the differential equation, the parameter A may have a somewhatobscure significance or it may have a more physical interpretation, such as being pro-portional to either the frequency or angular velocity of the system. It should be notedthat equation (3.47) is not really a single differential equation. when the parameters p, qand r have been chosen the equation will have a separate solution for every value of theunknown constant A.The Sturm-Louville boundary value problem is the study of nonzero solutions ofequation (3.47) that satisfy particular boundary conditions, that is, the solutions mustsatisfy given relations at the endpoints x = a and x = b. The solutions to equation (3.47)are called eigenfunctions, and the corresponding values of A are called eigenvalues. Ingeneral, each boundary value problem will have a nontrivial solution for only a discretevalues of A, the number of eigenvalues will form a countable set.(3.48)Chapter 3. HUM^ 41Let us introduce the linear differential operator L, which will significantly simplifythe statement of the Sturm-Liouville boundary value problem. If we define^Ly = —(p(x)—y ) q(x)y^ (3.49)dxthen the differential equation, equation (3.47), can now be shortened toLy Ary = 0.^ (3.50)Of the two requirements that the boundary conditions must satisfy, the first is thatthe class of functions satisfying the problem must be a member of the inner productspace. The second requirement is that the boundary conditions must be chosen suchthat the operator L is self-adjoint in the space. An operator L is self-adjoint ifg) = Cf,^ (3.51)Consequently, the boundary conditions should satisfy the condition^P(b)(i (b).9(b) — .9/ (b)f (b)) P(a)( (a)g (a)^.C 1 (Of (a)) = 0^(3.52)Some very useful properties result if L is a self-adjoint operator. In particular, thefollowing lemmas will be stated without proof.Lemma 1 Every eigenvalue of a self- adjoint operator is real.Lemma 2 Eigenfunctions corresponding to distinct eigenvalues of a self-adjoint op-erator are orthogonal with respect to the weighting factor r(x).The lemmas imply that if f and g are solutions to the Sturm- Liouville boundary valueproblem then their corresponding eigenvalues will be real and. assuming f and g are notequal, the inner product, defined above with weighting function r(x), gives (f,g) = 0.The following theorem, due to Sturm and Liouville. will also be stated without proof.Chapter 3. HUM^ 42Theorem 2 (Sturm-Liouville) If the boundary conditions defining the space C 2 [a, b],where C 2 denotes the set of functions with continuous second derivatives, are such thatL is self-adjoint in C 2 [a,b], that is, (L f, g) = (f, Lg) for all functions f and g in the setC2 [a, b], then an infinite sequence of eigenfunctions exist011 021 031 ••• (3.53)which are mutually orthogonal with weighting function r(x)f b r(x)oi (x)oz(x)dx 0, wheneverj k (3.54)Each bounded function f integrable over [a, b] can be expanded in a seriesf (x) = 01(x) + C2¢2(x) + C 303(x) + (3.55)which converges in the mean to f. If f is of class C 2 [a,b] then the series also convergespointwise, and additionally, the sequence converges uniformly and absolutely to the func-tion f, throughout the interval [a, h].The reason for insisting that r(x) be a positive function in the boundary value problemshould now be clear, otherwise the integral fab f(x)g*(x)r(x)dx would not satisfy therequirements of an inner product. It should also be apparent why the function p(x)must be positive, otherwise the Sturm-Liouville problem would not even be a differentialequation. Finally, as the problem is given, the existence theorem of linear differentialequations can be applied to ensure that the solution remains bounded throughout theinterval a < x < b.There are several applications of Sturm-Liouville boundary value problems that areof interest. For example. the Fourier series comes from solving the set of differentialequationsy" + Ay = 0^ (3.56)Chapter 3. HUM^ 43while the solution of the Bessel equationx 2y" xy' x 2 y = Ay^ (3.57)gives the well known Bessel functions, which consequently, form an orthogonal set offunctions. Likewise, the solutions to the Legendre equation,(1 — x 2 )y" — xy' + Ay = 0^ (3.58)called Legendre polynomials, form a orthogonal set of functions with respect to theweight function (1 — x 2 ). In fact, by putting any differential equation into the form of aSturm-Liouville boundary value problem we know that the solutions form an orthogonalset of functions. This fact will be used to derive an algorithm which recognizes humimpairment.Although the Sturm-Liouville theorem states that the solutions of the diffential equa-tion form mutually orthogonal functions, it is not clear from this, whether given anarbitrary function h(x), a function basis can be found in which h(x) is a basis element.The following original corollary partially answers this question.Corollary 1 If h(x) is a positive function in C 2 with period b— a then an orthogonalset of functions can be found in which h(x) is an element.ProofTo prove this lemma we only need to show that there exists a Sturm-Liouville bound-ary value problem in which h(x) is a solution. By settingp^1 (3.59)h"(x) g^h(x)^ (3.60)r = 1 (3.61)with boundary conditions y(a) = y(b) and y'(a) = y'(b) we see by simple substitutionthat if A = 0 then h(x) is the solution. All other solutions to this Sturm-LiouvilleChapter 3. HUM^ 44boundary value problem are orthogonal to h(x). In addition, the proof of this corollaryspecifies the precise form of the Sturm-Liouville differential equation so that h(x) will bean eigenfunction.3.5 HUM RECOGNITION USING ORTHOGONAL FUNCTIONSIf it is assumed that the image resulting only from the hum is described by the functionH(x, y) and the original unimpaired image by F(x, y) then the function representing thetelevision image is defined as the sum of the two functionsG(x, nAy) = F(x,nAy) H(x, nzy)^ (3.62)with 0 < x < X and 0 < nAy < Y. We shall map H(x, y) into a one dimensionalfunction by taking the even lines of H(x, y) and arranging them progressively one nextto the otherh(x nAyX) = H(x, nAy)^ (3.63)as shown in figure 3.12. After mapping the even lines of H(x, y) to h(u), the set of oddlines are appended. The domain of the one dimensional function h(u) is NX = XY/Ay.We make similar definitions for Au) and g(u).Assume that an inner product space and a countable set of functions O i (x) have beendefined where, for i j, we haveXY(c5i,^) =^4i(17)0;(X)r(X)d-X = 0f(3.64)and where r(x) is the positive weight function.If the functions f(x) and h(x) are bounded and integrable over the interval [0, NX]then this ensures that both functions, as well as g(x). will have a series expansionChapter 3. HUM^ 45F x,0)F x,2Ay Y^Figure 3.12: The Television Screen In Terms Of A 1-D Functionwhich converges in the mean. We can expand f (x) in terms of the orthogonal func-tion .0o, 01,^•••1f(x) =^fnsbn(x )^(3.65)n>0and similarly, h(x) and g(x) are expanded in terms of the respective h n 's and gn 's andby On s,h(x) = En>o hnOn(x)^(3.66)g(x) = En>o nOn(x). (3.67)A system is able to automatically predict whether an image contains hum or not if itcan determine whether h(x) is present. Although the magnitude of h(x) is not known,it can be guessed by using Parseval's theorem,Ih(x)1 2 r(x)ds = E ih r,12^ (3.68)n>01. xYwhich relates the magnitude of h(x) to nonzero values of h r . The monitoring devices'Chapter 3. HUM^ 46prediction would be based on the fact that the larger the magnitudes of the h a 's the moresevere the hum is.Since g(x) is known, the value of gn is calculated using the relation g„ = (g, cb,„). Ifthe original image, f(x), were known then the hum could be found by the equationh n = gn — fn•^ (3.69)However, preferably, the system should work independently of any knowledge of theoriginal image, and so it is assumed that the value of f„ is an unknown.Fortunately, we can assume that the value of fn is relatively constant in time. Onlyin cases where the background changes abruptly, for example, when the camera movesto a different vantage point, will there be any significant change in the original image.We will guess that, in most cases, each successive television picture is extremely similarto the previous picture, and scene changes which cause fn to change will occur only onceevery half dozen seconds or so.By taking the inner product of the consecutive frames g3 (x), where gj ( ) representsthe jth frame, with the orthogonal functions O n (x) the variation of the inner product asa function of j can be plotted. This givesNX(g. h On) =^On) +0^hj ( )07,(x)r(x)dx^(3.70)NXti k I^hi (x)0:(x)r(x)dx^ (3.71)where we assume that (fi , On ) is approximately equal to the constant k.If the hum, h; (x), is known then the curve (hi . On ) versus j can be calculated. Bycalibrating the monitoring devices with the values that are expected, the system canmake a reasonably accurate prediction as to whether hum is present in the image ornot. If the values recorded for the function (gi, On ) minus a constant are proportional tothe calibrated results then the television picture contains hum impairment. If the valuesChapter 3. HUM^ 47minus a constant are not proportional and particularly if (g3 ,¢„) itself is a constant, thenhum impairment is not present in the image.The most important functions (g3 , 6,), for different n. to be studied are those whichare nonconstant when hum modulation is present in the image, and consequently, theorthogonal basis in which the g(x) is represented becomes very important. The fewerinner products that need to be studied the faster the algorithm can be calculated and themore accurate the results will be. In particular, it is preferable to use a basis in which thehum h(x) is proportional to only a single element rather than one in which the hum mustbe represented by an infinite series. As described above. the Sturm-Liouville theory oforthogonal functions is perfectly suited to finding othogonal functions. Although factorsmay indicate that the Fourier, Bessel or another well-known series may be optimal forhum recognition, it is advantageous to be able to use the more general theory to obtainthe best possible basis for hum recognition.3.6 APPLICATIONS VIA FOURIER SERIESLet the hum be defined as a sinusoidal function and, to account for the upward motion,let the hum be time dependent with frequency wxlr^.hj(x) = A cos(-wi) (3.72)The Fourier expansion of h j (x) isx7rh • (x) =^,^al sin( —X)^ (3.73)whereci = A cos(u.)j)^ (3.74)anddi = —A sin(wj)^ (3.75)Chapter 3. HUM^ 48In this case, the optimal othogonal basis to represent g( x) is the Fourier series. If theoriginal television image can be expressed mathematically as a piecewise smooth functionthen the said function is guaranteed to have a Fourier expansion7r „^nx7r „fj(X) = E(an cosk 11XX + or, sin(— ))X(3.76)We will assume that f.7 is approximately constant so that the numbers a n and bn haveno dependence on the integer j.The image that is received by the detection devices will be the superposition of thesetwo function, that is, g 3 (x) = f 3 (x) + h 3 (x). As the algorithm suggests, the inner productof this sum should be taken with the relevant basis functions,(g(x), cos(5-)) = a n + A cos(c.uj ) (3.77)(g(x), sin( y)) = bn — A sin(u)j) (3.78)If hum is present in the image then a sinusoidal curve will be obtained when the innerproduct values are plotted. If the curve forms a horizontal line, or some other shape,then hum has not been added to the signal.3.7 SOFTWARETo experimentally verify the algorithm described in section 3.5 several software programshave been written. As the facilities currently do not permit several images to be capturedin succession, the motion of the hum has also been simulated via software. The humfunction will be assumed to be a cosine wave, this will coincide with the example in theprevious section, and so if hum modulation is present in the image we should expect tosee sinusoidal curves.The first program, remove_block, utilizes the Utah raster toolkit to read run lengthencoded image files. Remove_block reads an image and sets all the pixels within a 128Chapter 3. HUM^ 49by 128 area to black, the new image is written to standard output. The position ofthe blackened square can be given on the command line by specifying the top rightmostcoordinates. By creating a series of images, each using remove_block with a slightlydifferent offset, a set of similar pictures is obtained. When these images are shownrapidly in succession, the viewer sees an image with a small black box moving about thescreen. This should simulate the motion of a sequence of television images adequatelyfor the experiment.To add hum impairment to an image, a program, called add_hum, was written. Thisprogram reads Utah raster toolkit images and adds hum with a carrier-to-noise ratio of25dB. This program is almost identical to add_intermod, discussed in chapter 2, exceptthat the frequency of the cosine that is added is fixed while its phase must be given on thecommand line. The program called hum_detect implements the hum detection algorithmdiscussed in the section 3.6. This program, which reads images files compatible withremove_block and add_hum, prints the resulting data to standard output. If the data,once graphed, shows a curve similar to a sinusoid then the algorithm has predicted theexistence of hum in the sequence of images.3.8 EXPERIMENTAL VERIFICATIONTo experimentally verify the hum recognition algorithm the image file Aliens, shown infigure 3.14, has been used. In this figure, it may be difficult to see but the image hasbeen distorted with hum modulation with a carrier-to-noise ratio of 25 dB, this appearsas a slight brightening near the top of the screen. The hum at this severity is much morevisible when viewed as a moving series of images.A series of images has been created by setting a small area to black at different offsetpoints in the Aliens picture. Showing these images in succession simulates a movingChapter 3. HUM^ 50Frame 1Frame 9Frame 5Frame 13Figure 3.13: Experimental Frames Used by Hum Detection Algorithmimage. Figure 3.13 illustrates this, the block is moved vertically from the top of thescreen in frame 1 to the bottom of the screen in the last frame, frame 13.Two separate experiments were performed on the image. In the first, the black squarewas moved in a horizontal direction, while in the second, the black was moved in a verticaldirection. The two sequences of images were tested according to the algorithm, by takingthe inner product of the frames with cosine and sine functions.The results obtained from moving the square in a horizontal direction are shown infigure 3.15 and figure 3.16. In the first, figure 3.15, the inner product of the image withthe cosine function is graphed. The first line, called horizontal.cosine, shows the resultwhen the sequence of images consists of the moving block where no hum has been added.As expected this forms a curve which is very unlike a sinusoid, in fact, the result is nearlyChapter 3. HUM^ 51a straight line. The second curve, called hum.cosine, shows the result when the block isheld fixed with the image impaired, a constant image with a moving band of hum. Aspredicted, this forms a curve which strongly resembles a cosine. Finally, the last line,called hum.horizontal.cosine, shows the result of the moving square where hum has beenadded. The curve also resembles a cosine, indicating that the algorithm has made acorrect prediction. The second graph, figure 3.16, shows similar curves with the innerproduct taken with a sine function rather than a cosine function.The second experiment, in which the black square is moved vertically, is shown infigure 3.17 and 3.18. The graphs show the three curves produced by a moving imagewithout hum, a constant image with hum and a moving image with hum. These resultsare obtained using the inner product of the images with the cosine function in figure3.17 and a sine function in figure 3.18. It should be noted that although the data doesindicate that the algorithm has successfully predicted the presence of hum modulation,the results are not as good as in the first experiment. This is due to how the image ismapped into a one dimensional function g(x), the algorithm is more sensitive to verticalchanges in the image than to horizontal changes.Chapter 3. HUM^ 52Figure 3.14: Aliens Image With Hum And With A Block Removed"horizontal.cosine""hum.cosine""hum.horizontal.cosine"30000200001 0 0 0 0a)ty)-H 004Joo -10000-200002-300000 4 6^8^10Frame number14 1612 18Figure 3.15: Aliens Image With Horizontal Motion - Cosine Inner Product"horizontal. sine""hum.sine""hum.horizontal.sine"30000CDtiC"2000010000ro(41^004Jo0^-100001-1^-200002-300000 18164 12 146^8^10Frame numberFigure 3.16: Aliens Image With Horizontal Motion - Sine Inner Product30000-300000• -200004J'0^-100001412 1664 182(4-10020000-(1ro^10000a)rot3)8^10Frame number"vertical. cosine""hum.cosine""hum.vertical.cosine"Figure 3.17: Aliens Image With Vertical Motion - Cosine Inner Product30000w20000co0010000t7)'ti00-pE -10000-200006^8^10Frame number2^4-300000 12 14 16 18vertical. cosine""hum.cosine""hum.vertical.cosine"Figure 3.17: Aliens Image With Vertical Motion - Cosine Inner ProductChapter 4SNOW NOISETelevision impairments are classified as either coherent or non-coherent noise. A co-herent impairment, such as intermodulation carrier beats or hum modulation, producesrecognizable patterns which tend to be very annoying. Snow noise is an example of anon-coherent noise, this impairment arises from random variations in the television signalwhich become apparent when the signal is very weak.The quantum fluctuations in the cable signal which cause snow noise produce a uni-form effect over the entire screen, adding a random Gaussian value each pixel. Althoughsnow noise can occur due to poor weather and other external conditions, it is importantthat cable companies monitor their networks for bad connections or faulty wiring thatmay also produce this impairment.4.1 CHARACTERISTICS AND CAUSES OF SNOWSnow noise is so named from the snowstorm effect that it creates on the screen. Thestatistical nature of this impairment will affect the image and may also affect the soundsignal, the sound will become noisy and difficult to distinguish. Snow is a serious typeof impairment to cable companies, their subscribers expect the signal they receive willproduce a strong and clear picture, free from noise.If snow noise is caused by the television set itself, for example, by a faulty televisionset RF amplifier or a broken television matching transformer. then the impairment willonly affect the single television. If snow noise is caused by problems in the cable network,Chapter 4. SNOW NOISE^ 58such as due to a badly coupled "F" type connector or to faulty cable splices, then thiswill affect a large number of viewers and must be repaired by the cable company. Thereare conditions, such as poor weather, in which the addition of snow noise to the signal isbeyond the control of the cable company. To guarantee that snow noise is not producedby a weak point in the cable network, the cable company should carefully check theirconnections and try to repair all problems as soon as possible.4.2 CARRIER-TO-NOISE RATIOThe most common measure in which the severity of noise is reported is the signal-to-noise ratio. This value is a measure which relates the strength of the original signal incomparison to the noise that has been added. This ratio is defined asx2^/101og 10 (^ ) dBXnoise(4.79)where x„,i„ is the amount of noise in the picture and x s i9„/ is the original signal strength.A more common method to measure the amount of impairment in the television signalis the carrier-to-noise ratio, see [8]. This measure is similar to the signal-to-noise ratio,being defined, in dB, as10log1o(1.6 2^— signalX 2^) dBXnoise(4.80)where x signai is always set equal to 256. The carrier-to-noise ratio, or C/N ratio, willbe equal to the signal-to-noise ratio plus 20 x log 10 (1.6) 4.08 dB. The carrier-to-noiseratio should ideally be 45 dB or greater to ensure that the noise is not visible to theviewer. Snow may be barely visible when the C/N ratio is greater than 40 dB and theimpairment will he especially objectional if the C/N ratio is below 40 dB.Chapter 4. SNOW NOISE^ 594.3 FOURIER TRANSFORM OF SNOW NOISEAs described above, snow noise is characterized by a uniformly fine disturbance over theentire screen, produced by random fluctuations in the pixel values. These quantum vari-ations can be considered as the result of several high frequency components which willappear as points interspersed throughout the Fourier transform. The number of calcu-lations that must be performed to derive the transform indicates that a faster detectionalgorithm should be developed.4.4 SUBJECTIVE RECOGNITION OF SNOW IMPAIRMENTSeveral experiments have been done which use a subjective approach to the problem ofrecognizing snow noise, see [3]. For example, a picture shown to a number of humansubjects is rated as to the quality of the image. Typically, the subject is asked to ratethe image under several classifications, such as, excellent, good, fair, poor and bad. Thenumber of categories is best limited to a small amount since it was found that the subjectsbecome confused if there are too many image classifications.Although the subjective approach is contrary to the concept of automatic recognition,it is important to remember that one of the best approaches for developing detectionalgorithms is to mimic the methods used by human subjects. Unfortunately, humans arebetter able to relate the image or parts of the image with their own knowledge of theworld when determining whether snow exists. Since computer algorithms are unable todo this, an alternate approach has been adopted.4.5 AUTOMATIC RECOGNITION OF SNOW NOISEThe snow recognition algorithm that will be described below relies on the fact thatif an image contains random noise then many individual pixels will assume values quiteChapter 4. SNOW NOISE^ 60h k (i - 1 ,i hk(i,i hk(i+1,j- 1)h k (i — 1, j) hk(i,i) hA +Li)h k (i —1,j +1) hk(i,j +1) h k (i + 1, j + 1)Figure 4.19: Pixel Neighbourhood For Snow Detectiondifferent from their neighbours. An image which does not contain snow should be smooth,causing these variations in pixel values to be far less numerous. This will not be true atedges and regions with texture but the variations due to these effects should be muchless than the contribution caused by snow as the latter affects the entire screen.Consider an image which is represented by the function f'(;, j), where i and j assumeinteger values. Let the noise be defined by the function random Gaussian distributedn(i, j). As the noise is added, this defines the function{0,^if f(i,j) + n(i, j) < 0;Rid = Pi, j) + n(i, j), if f(i,j)+ n(i,j) < 255;^(4.81)255,^otherwise:which is the superposition of the original image and the snow noise and where a thresholdhas been used to ensure that the values of f (i, j) remain within predefined bounds.Chapter 4. SNOW NOISE^ 61The image may contain areas which the algorithm could assume were caused by snownoise, although the human subject, using knowledge of physical objects, will not. Forexample, an image which contains water waves, a forest or any object with a great deal oftexture, may easily be mistaken for an impaired picture by the computer algorithm. Tocircumvent this, we will subdivide the image into blocks of size 64 x 64. The algorithmwill not consider the noisiest sections in its predictions, all decisions will be based uponthe smoothest area. This should not affect the accuracy of the algorithm since if snowis present the impairment will be uniform over the entire image. Once the image issubdivided, this defines new functions h k (i, j) which represent a different block for eachinteger k.The algorithm considers each pixel, called hk(i,j), and compares it to the eight neigh-bouring points, see figure 4.19. The pixel is called isolated if its value is significantlydifferent from each of the other points. Let us define a new function which is the smallestdifference of all the comparisonsabs[hk(i —1, j —1)— hk( 1 , j)]abs[hk(i, j — 1) — hk(i,j)]abs[h k (i +1, j —1) — hk( 1 , j)]abs[hk(i —1, j) — hk(i,j)]= minabs[hk(i +1, j) — hk(i,j)]^(4.82)abs[h k (i —1, j + 1) — h k (i,abs[hk(i, + 1) — hk(i,j)]abs[hk(i +1, j +1) — hk(i,j)]The value of hk(i, j) will be large if and only if the pixel assumes a value very differentfrom any of its neighbours, that is, if the pixel is an isolated point.If a threshold is applied so that the smaller values of hk(i, j) are set to zero then apoint at which hk(i, j)^0 represents an area that has probably been severely affectedChapter 4. SNOW NOISE^ 62Pk =^ (4.83)t o { 0,^otherwisewhere 8 is an arbitrary threshold value. Finally, in order to base the prediction on thesmoothest block in the image the minimum value of the numbers pk is taken, we call thisvalue PP -= min{Pk}.^ (4.84)The device will predict whether snow is present in the image by comparing P witha previously calibrated threshold value. This algorithm will ignore areas in the imagethat are greatly detailed, such as forests and lakes, unless, as is not true in most physicalimages, these areas affect every part of the image. From experimentation a thresholdvalue is selected, if P is greater than this value then snow is declared present in theimage.4.6 MODIFICATIONS TO THE DETECTION ALGORITHMMany of the devices which are used to capture an image from the television signal to thecomputer, apply a low pass filter in the horizontal direction when the image is captured.This means that the variations in the horizontal direction of the image are smoothedout and when the image is studied by the snow detection algorithm, the pixels whichoriginally had large variations with its neighbours will no longer be isolated points.It is necessary to look at how this may affect the snow detection algorithm discussedabove. The algorithm depends a great deal upon being able to isolate those pixels whichare very much different in value from their neighbours, where the assumption is thatthis will be a good indication as to how much noise is inherent in the image. However,by snow, the more nonzero points imply the stronger the snow impairment. We canrepresent this simply by summing each value in the block kh/k (i, j). if hVi, j) > 8Chapter 4. SNOW NOISE^ 63this will no longer produce a satisfactory result if the image is low passed filtered inone direction. The points that were isolated will not remain so and consequently thedetection algorithm will fail to produce an accurate prediction.This problem can be solved by a simple modification to the function P k . If thealgorithm does not test the two horizontal neighbours, but only the remaining six points,then even if the image is low passed filtered the prediction should not be affected. Thiscan be described mathematically by redefining the function Pk asabs(hk(i —1, j — 1) — h k (i,j))abs(h k (i,j —1)— h k (i,j))abs(h k (i +1, j — 1) — h k (i, j))= min^^ (4.85)abs(h k (i —1, j +1) — h k (i,j))abs(hk(i,j + 1) — hk(i,j))abs(h k (i +1, j +1)— h k (i,j))4.7 OTHER POSSIBLE DETECTION ALGORITHMSOther automatic detection algorithms have been studied. Of course, possibly the simplestto implement would be to study the quality of the signal (luring the horizontal andvertical retrace times using test signals. This, however, turns out to be impractical asthe horizontal retrace time is too short to produce any useful information and the verticalretrace time, though longer, is used for other purposes. There are three lines during thevertical retrace in the NTSC standard which are devoted to a test signal. These couldbe used to detect snow noise, however, three lines are not sufficient to detect the snowthat may be present.Chapter 4. SNOW NOISE^ 644.8 SOFTWARESoftware has been written to experimentally test the snow detection algorithm discussedin Section 4.5. The first program, called add_snow, uses the Utah raster toolkit andcorrespondingly reads run length encode images files. Add snow will read the image, adda random Gaussian noise to each pixel and print the carrier-to-noise ratio to standarderror. The second program, called snow_detect, is also compatible with the Utah rasterfile format. This program applies the snow detection algorithm described previously,that is, it subdivides the image into blocks, calculates the value of pk for each sectionand prints the minimum P.4.9 EXPERIMENTAL VERIFICATIONTo verify the algorithm experimentally, several public domain images have been used.These images, listed respectively in figures 2.4 and 4.20-4.23. are called Ritukoen, Data,Gorby, Oldmill and Fiji. An example of snow noise, with a carrier-to-noise ratio of 25dB, is shown in figure 4.24, this illustrates how a moderate amount of snow can severelylimit the clarity of the image.To experimentally test the effectiveness of the detection algorithm, thirty differentlevels of snow impairment have been added to each image. Each level is defined by adifferent value of x„ i„, where x„ i„ is related to the carrier-to-noise ratio according tothe graph in figure 4.27.As defined in section 4.5, P is the measure, generated by the algorithm, of the severityof the impairment. The relation between the value of P to the amount of snow in theimage is shown in figure 4.25. each curve in the graph represents the results producedby a different image. The curves are shown in the same graph so that the results canbe compared. For the algorithm to be effective the curves generated for different imagesChapter 4. SNOW NOISE^ 65should be similar, this way the value of P can produce an estimate of the carrier-to-noiseratio in the image.The data obtained has been enlarged near the origin and shown in figure 4.26, thisgraph is used to determine an effective threshold value. We see that if{Snow is not present when P < 800Snow is present^when P > 800then the algorithm will detect snow noise if x„, „ is greater than 7 or equivalently ifthe carrier-to-noise ratio is less than 35 dB. From this, we deduce that the detectionalgorithm will produce accurate predictions for moderately to severely impaired images.(4.86)Chapter 4. SNOW NOISE^ 66Figure 4.20: Data Image Without Snow Noiseti00<.C)5 1 0 15 20 25x noise30^35^40^45^5035000300002500020000150001 000 05000bti• Figure 4.25: Snow Noise Predictions^"data" ^"fiji"^"gorby"^"oldmill" ^"ritu -koen"/••/•7000"data"8x noise1 060005000400030002000100000^2^4^6^"gorby" ^"oldmill" ^p ritukoen"/---1412Figure 4.26: Snow Noise Predictions - Enlargement Near The Origin0-H4Jrocn-H0z04Ja)$-1co Figure 4.27: Relation Between X_noise And Carrier To Noise RatioChapter 5CONCLUSIONMany cable companies strive to offer the best possible service to their customers, in par-ticular, they take great pains to ensure that the signal they send through their networkremains unaffected by the many common television impairments. Nevertheless, the qual-ity of the television signal has been poorly rated by many viewers. Since errors in thenetwork can be very difficult to detect most cable companies are unaware of the problemuntil an angry viewer complains.An automatic detection system which would continually monitor the signal at manypoints in the network is proposed. The device would determine whether an impairmentis present, and if so, what type of noise it is. Furthermore, the device would preferablyoperate under conditions in which it does not know what the original image looks like,that is, a test signal would not be available for the device to calibrate its results.There are several types of noise, including snow noise, ghosting, crossmodulation,intermodulation, hum and diathermy. This thesis has discussed and developed detectionalgorithms for the three impairments that have been rated most significant by our localcable company, that is, intermodulation beats, hum modulation and snow noise.5.1 INTERMODULATION BEAT PRODUCTSThe first type of television impairment that was studied was the intermodulation beatproduct. It was shown that this noise is closely related to crossmodulation and howboth impairments depend upon a superposition of signals with different frequencies.74Chapter 5. CONCLUSION^ 75Intermodulation comes in several forms, picture carrier beats, low frequency colour beatsand composite triple beat.In order to detect intermodulation distortion, two algorithms were proposed. The firstuses the two dimensional Fourier transform of the image, it was shown that four peaksappear in the transform when intermodulation is added. By detecting these points it ispossible to accurately deduce the presence of intermodulation. The second method thatwas discussed uses the one dimensional Fourier transform taken over each horizontalline in the image. The graphs that were produced from this method showed that ifintermodulation is present then the spectrum contains two sharp impulses. These peakscan also be detected automatically.5.2 HUMHum modulation was also studied. This is a low frequency distortion, having a frequencyof either 60 Hz or 120 Hz, that appears as light or dark bars moving slowly up the screen.This impairment is caused by a defective TV set power supply or an overloaded powersupply in the cable network.To discuss hum modulation as generally as possible the theory of orthogonal functionswas introduced. It was shown how selecting the proper function basis for the signal cansignificantly reduce both the accuracy of the prediction and the number of calculationsthat the device had to perform. We assumed that hum is in the form of a sine wave andadded different phases of the impairment to a moving picture. By using this method, wefound that the experimental results agreed with our theoretical predictions.Chapter 5. CONCLUSION^ 765.3 SNOW NOISEFinally, snow noise was studied. This is a random noise, characterized by a weak televisionsignal, that produces a uniformly fine snowstorm effect on the screen. A technique isproposed to detect snow noise in which each pixel is compared to its local area. Since,typically, snow noise produces many isolated pixels whose values are quite different fromtheir neighbours, we simply take a weighted count of the number of isolated pixels toestimate of the amount of snow in the image.Several pictures were tested with varying degrees of snow noise. By applying thedetection algorithm to each image a graph was produced which related the predictedamount of noise to the actual carrier-to-noise ratio of the image. It was seen fromthis graph that the results will produce fairly accurate predictions for images that aremoderately to severely impaired by snow noise.BIBLIOGRAPHY[1] Bachman, Scott. "Reliability in Cable Systems" Specs International June 1992 :5-8.[2] Bartlett, Eugene R.^Cable Television Technology and Operations : HDTV andNTSC Systems New York : McGraw-Hill Publishing Company, 1990.[3] Bednarek, Robert A. "On Evaluating Impaired Television Pictures By SubjectiveMeasurements." Transactions On Broadcasting  Vol BC-25, No 2 (June 1979) :41-46.[4] Cable Television Picture Impairment Guide.  Chart. Ottawa : Cable Telecommuni-cations Research Institute, n.d.[5] Ciciora, Walter S. "An Introduction to Cable Television in the United States."IEEE LCS Magazine February 1990 : 19-25.[6] Davis, Harry F. Fourier Series and Orthogonal Functions  Boston : Allyn and Ba-con, Inc, 1963.[7] Drewery, J. 0. "An Adaptive Noise Reducer For PAL And NTSC Signals."Internation Broadcasting Convention Conference Publication 166 London, (1978):231-237.[8] Fink, Donald G., and Donald Christiansen. Electronics  Engineers' Handbook  3rdEd. New York : McGraw-Hill Book Company, 1989.[9] Gresseth, R., and R K Ward. Automatic Recognition Of The Hum Impairment InCable Television Systems Proc. of the CSECE Conference, Toronto, September1992 : TM5.13.1-TM5.13.4.[10] Hawker, J. P. Outline of Radio and Television  London : George Newnes Limited,1966.[11] Krauss, Herbert L., Charles W Bostian, and Frederick H Raab. Solid State RadioEngineering New York : John Wiley and Sons, Incorporated, 1980.[12] Mambo, P. L., and D C Coll. "Perceived Picture Quality In CATV Systems WithImpairments." Cable Television Vol 4 (January 1979) : 10-16.77BIBLIOGRAPHY^ 78[13] Martin, A. V. J. Technical Television Englewood Cliffs : Prentice-Hall, Incorpo-rated, 1962.[14] Meyer, Robert G., Mark J Shensa, and Ralph Eschenbach "Cross Modulation andIntermodulation in Amplifiers at High Frequencies." IEEE Journal Of Solid-StateCircuits Vol SC-7, No 1 (February 1972) : 16-23.[15] Osborne, B. W. "The Assessment Of Picture Quality On Cable Television SystemsBy Means Of Engineering Auits." Transactions On Cable Television Vol CATV-2,No 2 (April 1977) : 95-98.[16] Pomerleau, Andre, and Dany Sylvain. "Quality Measurement Of Television PictureBy Eye Simulation." Transactions On Broadcasting Vol 28 (March 1982) : 27-36.[17] Press, William H., Brian P Flannery, Saul A Teukolsky, and William T Vetterling.Numerical Recipes in C Combridge : Cambridge University Press, 1989.[18] Sasaki, Tai, and Hiroshi Hataoka. "An Intermodulation Prediction And Mea-surement Technique For Multiple Carriers Through Weak Nonlinearities." CableTelevision Vol 4 (October 1979) : 146-154.[19] Taylor, Ralph E. Radio Frequency Interference Handbook Goddard Space FlightCenter, MD : NASA, 1971.[20] Thomas, Spencer W. Utah Raster Toolkit Version 3.0. Computer Software. Uni-versity of Utah, 1986. UNIX.[21] Zhang, Q., and R K Ward. Automatic Identification Of Impairments Caused ByIntermodulation Distortion In Cable Television Pictures IEEE Trans on Broad-casting Vol 38, No 1, March 1992 : 60-68.[22] Zhang, Q., R K Ward, and R Gresseth. An Automatic System Which Detects Intermodulation Impairments in Cable TV Pictures Proc. of the Cdn. Conf. onElectr. and Computer Eng., Sept 1991 : 28.2.1-28.2.4.


Citation Scheme:


Citations by CSL (citeproc-js)

Usage Statistics



Customize your widget with the following options, then copy and paste the code below into the HTML of your page to embed this item in your website.
                            <div id="ubcOpenCollectionsWidgetDisplay">
                            <script id="ubcOpenCollectionsWidget"
                            async >
IIIF logo Our image viewer uses the IIIF 2.0 standard. To load this item in other compatible viewers, use this url:


Related Items