Patent ID: 7963269

Claim:
An ignition timing control apparatus for an internal combustion engine comprising: a knock sensor that detects a magnitude of vibration of the internal combustion engine in each ignition cycle; and a control unit, wherein said control unit updates a first value representing a median value of the distribution of said magnitude, updates a second value representing a standard deviation of the distribution of said magnitude, calculates a third value corresponding to said first and second values, calculates a fourth value corresponding to said magnitude and said third value, retards ignition timing when said fourth value is larger than a first determination value, stops the updating of said second value in at least one of a case when a magnitude that is smaller than a second determination value is detected in current ignition cycle and a case when a magnitude that is equal to or larger than a third determination value is detected in the current ignition cycle, counts a frequency of detecting a magnitude equal to or larger than a fourth determination value, corrects said first determination value to reduce the same when the frequency of detecting a magnitude equal to or larger than said fourth determination value is larger than a predetermined frequency, and stops the counting of the frequency in at least one of a case when magnitudes smaller than said second determination value are continuously detected in a plurality of ignition cycles and a case when magnitudes equal to or larger than said third determination value are continuously detected in a plurality of ignition cycles, calculates said third value by subtracting a product of a first coefficient larger than zero and said second value from said first value, and calculates said fourth value by dividing said magnitude by said third value, said second determination value is obtained by subtracting a product of a second coefficient larger than said first coefficient and said second value from said first value, said third determination value is obtained by adding a product of a third coefficient larger than said second coefficient and said second value to said first value and said fourth determination value is obtained by adding a product of a fourth coefficient larger than said third coefficient and said second value to said first value.