CN108871406B - Algorithm for searching excellent calibration points - Google Patents

Algorithm for searching excellent calibration points Download PDF

Info

Publication number
CN108871406B
CN108871406B CN201810396374.8A CN201810396374A CN108871406B CN 108871406 B CN108871406 B CN 108871406B CN 201810396374 A CN201810396374 A CN 201810396374A CN 108871406 B CN108871406 B CN 108871406B
Authority
CN
China
Prior art keywords
calibration point
calibration
points
group
dice
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201810396374.8A
Other languages
Chinese (zh)
Other versions
CN108871406A (en
Inventor
赵浩华
王恒斌
孙伯乐
高志齐
朱亦正
陈绪聪
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Changzhou Tonghui Electronics Co ltd
Original Assignee
Changzhou Tonghui Electronics Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Changzhou Tonghui Electronics Co ltd filed Critical Changzhou Tonghui Electronics Co ltd
Priority to CN201810396374.8A priority Critical patent/CN108871406B/en
Publication of CN108871406A publication Critical patent/CN108871406A/en
Application granted granted Critical
Publication of CN108871406B publication Critical patent/CN108871406B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01DMEASURING NOT SPECIALLY ADAPTED FOR A SPECIFIC VARIABLE; ARRANGEMENTS FOR MEASURING TWO OR MORE VARIABLES NOT COVERED IN A SINGLE OTHER SUBCLASS; TARIFF METERING APPARATUS; MEASURING OR TESTING NOT OTHERWISE PROVIDED FOR
    • G01D18/00Testing or calibrating apparatus or arrangements provided for in groups G01D1/00 - G01D15/00

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Complex Calculations (AREA)
  • Image Analysis (AREA)

Abstract

The invention relates to an algorithm for searching an excellent calibration point, which comprises the following steps: 1) acquiring a group of test data to be calibrated, and determining a curve fitting mode; 2) randomly selecting a batch of calibration points; 3) randomly interchanging the good calibration points; 4) selecting a plurality of points from all the points appropriately; 5) performing curve fitting on each group of calibration points to calculate a Q value; then calculating a score for the Q value by using an evaluation function; 6) and combining the evaluation function values, selecting a good batch of calibration points by rolling the dice, entering the next round of selection, and selecting a group of calibration point records with the best quality in the round. 7) Repeating the steps 3) to 6); 8) repeat many times to find a best calibration point set. The method takes Newton interpolation and cubic spline interpolation as examples, finds excellent calibration points in a large number of measurement points, achieves the calibration effect within a reasonable error range with lower complexity, can be used in the field of impedance measurement, and is very suitable for daily production.

Description

Algorithm for searching excellent calibration points
Technical Field
The invention relates to the field of electronic measurement, which is used for instrument calibration, in particular to an algorithm for searching an excellent calibration point.
Background
Most current calibration schemes are linear interpolation. Nowadays, the testing principle of some sophisticated instruments is complex, a phenomenon that the relation between a measured value and a true value shows nonlinear correlation is generated, linear interpolation has very common effect on the curve fitting, and a very large number of points are required to be taken, and even derivation becomes a table look-up method. In the face of such problems, the curve fitting method has significant advantages.
The method of linear interpolation to select the calibration points is simple, as long as the inflection point is found. However, the calibration points of the curve fitting are not specific points and cannot be recognized by human eyes, and whether the selection of the calibration points is proper determines the fitting effect. In practical application, the measurement points are often a large number of points, and if more than ten points are selected through an exhaustive method, the complexity is very high, and the actual production is not facilitated. Therefore, in the case of curves with different characteristics, how to select a calibration point with an excellent curve fit from a large number of points with the lowest complexity becomes a critical problem.
Disclosure of Invention
The technical problem to be solved by the invention is as follows: the algorithm for searching the excellent calibration points is provided, the excellent calibration points are searched in a large number of measurement points, and the calibration effect within a reasonable error range is achieved with low complexity in the actual production process.
The technical scheme adopted by the invention for solving the technical problems is as follows: an algorithm for finding a superior calibration point, comprising the steps of:
1) acquiring a group of test data to be calibrated, and determining a curve fitting mode;
2) selecting an initial calibration point set of a batch: randomly selecting a plurality of calibration points in the test data to form a calibration point group by a dice rolling mode, and continuously selecting 200 calibration point groups;
3) excellent calibration point interchange position: traversing each calibration point group and throwing the dice, and marking if the obtained value is less than 0.9; when a plurality of calibration point groups are marked, the dice are thrown to determine how many calibration points are exchanged, and finally, which calibration point is exchanged is selected in a dice throwing mode;
4) some calibration points were randomly blended: traversing each calibration point group again and rolling the dice, if the obtained value is less than 0.3, continuously rolling the dice to determine which calibration point needs to be replaced, and finally rolling the dice again to determine which calibration point of all calibration points needs to be replaced;
5) performing surface fitting on each individual to calculate a Q value; an evaluation function is then used for the Q value:
Figure BDA0001644683110000023
calculating scores, and recording the calibration point group with the highest score as the final optimization range;
6) combining the evaluation function values, selecting a good calibration point group by a dice throwing mode, and continuing the next round of search;
7) repeating the steps 3) to 6);
8) and searching an individual with the minimum Q value in all the optimal calibration point groups as the final excellent calibration point.
Further, the curve fitting method in step 1) of the present invention includes a newton interpolation method or a cubic spline interpolation method.
Still further, in step 2) of the present invention, if the same calibration point is selected in a calibration point group, the calibration point is reselected until the calibration point is not repeated.
Still further, in step 5) of the present invention,
Figure BDA0001644683110000021
wherein
Figure BDA0001644683110000022
The fitting values are Y true values.
In step 6), when there is the same calibration point, the score is changed to be lower as a penalty, and the optimal calibration point group in the previous round is directly entered into the next round for optimization as a reward.
The method has the advantages that the defects in the background technology are overcome, the algorithm is used, Newton interpolation and cubic spline interpolation are taken as examples, the excellent calibration points are searched in a large number of measurement points, the calibration effect within a reasonable error range is achieved with low complexity, the method can be used in the field of impedance measurement, and the method is very suitable for daily production.
Drawings
The invention is further described below with reference to the accompanying drawings.
FIG. 1 is a graph of real part of 5MHz-10MHz measurement data when an impedance analyzer is short-circuited;
FIG. 2 is a plot of combined evaluation function values;
FIG. 3 is a graph fitted by Newton interpolation; in the figure, a curve 1 is a measuring line, and a curve 2 is a fitting line;
FIG. 4 is a graph fitted by cubic spline interpolation; in the figure, curve 1 is a measurement line and curve 2 is a fit line.
Detailed Description
The invention will now be described in further detail with reference to the drawings and preferred embodiments. These drawings are simplified schematic views illustrating only the basic structure of the present invention in a schematic manner, and thus show only the constitution related to the present invention.
An algorithm for searching for the optimal calibration points includes such steps as choosing a lot of calibration points, exchanging the optimal calibration points, integrating a lot of new calibration points, and evaluating.
Taking short circuit data of a high-frequency part of an impedance analyzer as an example:
the measurement data are as follows (500 in total):
Figure BDA0001644683110000031
Figure BDA0001644683110000041
because the short-circuit value is small and the frequency value is large, the frequency value is divided by 1000000, and the measured value is multiplied by 1000 for normalization processing, so that the obtained data are as the following table (500 in total):
Figure BDA0001644683110000043
the curve is shown in figure 1.
Then the algorithm is used for selecting 10 points and fitting the points by a Newton interpolation method and a cubic spline interpolation method respectively.
The method comprises the following steps:
1. selecting a batch of calibration points:
firstly, randomly selecting 10 measurement data from 500 measurement data to form a calibration point group by throwing a dice, and selecting 100 calibration point groups in total; (if the same calibration point is selected in an individual, it is re-selected until the calibration point is not repeated, since the calibration point does not allow duplication).
The first batch of calibration point sets was selected as follows (one calibration point set for each row):
Figure BDA0001644683110000042
Figure BDA0001644683110000051
2. excellent calibration point interchange position:
traversing each group of calibration point groups and throwing dice once (range 0-1), if the obtained value is less than a certain probability, marking, when the next individual needing to exchange positions appears, throwing dice once again (range 1-500), and determining how many calibration points are exchanged. After the number of interchanges is obtained, the dice is thrown (range 1-10) to determine which calibration point to interchange. (probability is typically chosen to be 0.9). The initial values are interchanged for the excellent calibration points as follows (each row represents a set of calibration points):
Figure BDA0001644683110000053
3. some new calibration points are merged:
each set of calibration points is traversed again and the dice is thrown (range 0-1), if the resulting value is less than a certain probability, the dice is thrown again (range 1-10) to determine which calibration point to replace, and finally the dice is thrown (range 1-500) to determine which new calibration point to merge into. (the probability is typically 0.3). The first time a new calibration point is merged in is as follows (one calibration point set for each row):
Figure BDA0001644683110000052
Figure BDA0001644683110000061
4. select good calibration point set:
calculating a fitted curve through the calibration point group;
and selecting each calibration point group, and respectively calculating fitting curves of cubic spline interpolation and Newton interpolation by taking cubic spline interpolation and Newton interpolation as examples.
A. Newton interpolation method:
the newton interpolation formula is:
Figure BDA0001644683110000062
Figure BDA0001644683110000063
wherein f [ x ]0,x1,…,xk]Is the difference quotient value.
Wherein:
Figure BDA0001644683110000064
Figure BDA0001644683110000065
B. cubic spline interpolation:
Figure BDA0001644683110000066
the equations a, b, c, d within each segment need to be calculated. Four equations are needed for solving the equations of the four unknowns, and now 2 equations are obtained by obtaining head and tail values with interpolation points. The other two equations calculate their head-to-tail second derivatives using the condition that their second derivatives are continuous. The second derivatives are denoted below by M1, M2.
Figure BDA0001644683110000071
Wherein
hi=ai+1-ai
Figure BDA0001644683110000072
μi=1-λi
Figure BDA0001644683110000073
And adding M0 and M9 to M to obtain the third derivative value of the ten lines at the interpolation point. Then, four unknowns can be solved by four equations to obtain a, b, c and d.
Figure BDA0001644683110000074
Namely, matrix calculation:
Figure BDA0001644683110000075
can be solved to obtain a, b, c and d. And obtaining a fitting curve formula of the target.
Selecting a proper calibration point group through the error of the fitting value;
the Q value is firstly obtained, and then,
Figure BDA0001644683110000076
(
Figure BDA0001644683110000077
for the fitted value, Y is the true value), the smaller the Q value is the better if the fitted curve is desired to fit the actual curve. The best set of calibration points in this set of calibration points is recorded first and the best set of calibration points is selected in the best set of calibration points of 200 rounds. So as to select the evaluation function as
Figure BDA0001644683110000081
When the Q value is smaller, the evaluation score is higher, and then the evaluation function values are combined, and 100 excellent calibration point groups are selected by rolling dice (the range is the sum of all evaluation values)The set of base calibration points that is optimized for the next calibration point. Since individuals with high scores in the assessment are more likely to be selected when rolling the dice, each selection will result in a better calibration point being selected. The combined evaluation function value line segment is shown in fig. 2.
Since the calibration points existing in the individuals are generated in the step 2 and the step 3, the judgment is carried out before the selection, if the same genes exist, a very large Q value is directly assigned, the score is low, and the penalty is taken, so that the calibration points are eliminated during the selection.
The optimal calibration point group of the current round is directly added into the optimization of the next round, and the optimal calibration point group is most rewarded.
5. Repeating the step 2 to the step 4, and repeating the 200 rounds to finish;
6. and selecting the recorded most excellent calibration point group of 200 rounds, and finding the best calibration point group in the middle, namely the most excellent calibration point group.
Fig. 3 and 4 are graphs fitted by the algorithm to find the optimal calibration point:
FIG. 3 is a graph derived by Newton interpolation:
FIG. 4 is a graph derived by cubic spline interpolation:
from fig. 3 and fig. 4, it can be seen that the fitting effect is excellent, and the complexity of the traversal method and the algorithm is compared:
the method comprises the following steps:
Figure BDA0001644683110000082
the algorithm comprises the following steps: 100 × 200 ═ 2 × 104
Therefore, the algorithm has great advantages and is very suitable for daily production.
While particular embodiments of the present invention have been described in the foregoing specification, various modifications and alterations to the previously described embodiments will become apparent to those skilled in the art from this description without departing from the spirit and scope of the invention.

Claims (4)

1. An algorithm for finding an excellent calibration point, comprising the steps of:
1) acquiring a group of test data to be calibrated, and determining a curve fitting mode;
2) select a set of initial calibration points: randomly selecting calibration points from the test data by throwing dice to form a calibration point group, and continuously selecting 200 calibration point groups;
3) excellent calibration point interchange position: traversing each calibration point group and throwing the dice, and marking if the obtained value is less than 0.9; when a plurality of calibration point groups are marked, the dice are thrown to determine how many calibration points are exchanged, and finally, which calibration point is exchanged is selected in a dice throwing mode;
4) some calibration points were randomly blended: traversing each calibration point group again and rolling the dice, if the obtained value is less than 0.3, continuously rolling the dice to determine which calibration point needs to be replaced, and finally rolling the dice again to determine which calibration point of all calibration points needs to be replaced;
5) performing surface fitting on each group of calibration points to calculate a Q value,
Figure FDA0002987793330000011
wherein
Figure FDA0002987793330000012
Is the fitting value, Y is the true value; an evaluation function is then used for the Q value:
Figure FDA0002987793330000013
calculating scores, and recording the calibration point group with the highest score as the final optimization range;
6) combining the evaluation function values, selecting a good calibration point group by a dice throwing mode, and continuing the next round of search;
7) repeating the steps 3) to 6);
8) and searching a calibration point group with the minimum Q value from all the optimal calibration point groups as the final excellent calibration point.
2. An algorithm for finding a best alignment point, as claimed in claim 1, wherein: the curve fitting mode in the step 1) comprises a Newton interpolation method or a cubic spline interpolation method.
3. An algorithm for finding a best alignment point, as claimed in claim 1, wherein: in step 2), if the same calibration point is selected in a calibration point group, the calibration point is reselected until the calibration point is not repeated.
4. An algorithm for finding a best alignment point, as claimed in claim 1, wherein: in the step 6), when the same calibration point exists, the grade of the calibration point group is changed to be low to serve as a penalty, and meanwhile, the optimal calibration point group in the previous group directly enters the next round of optimization to serve as a reward.
CN201810396374.8A 2018-04-28 2018-04-28 Algorithm for searching excellent calibration points Active CN108871406B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810396374.8A CN108871406B (en) 2018-04-28 2018-04-28 Algorithm for searching excellent calibration points

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810396374.8A CN108871406B (en) 2018-04-28 2018-04-28 Algorithm for searching excellent calibration points

Publications (2)

Publication Number Publication Date
CN108871406A CN108871406A (en) 2018-11-23
CN108871406B true CN108871406B (en) 2021-05-25

Family

ID=64327216

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810396374.8A Active CN108871406B (en) 2018-04-28 2018-04-28 Algorithm for searching excellent calibration points

Country Status (1)

Country Link
CN (1) CN108871406B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111722084B (en) * 2020-06-29 2021-07-20 浪潮集团有限公司 Automatic calibration method for superconducting quantum chip parameters and related components

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1442704A (en) * 2002-03-05 2003-09-17 特克特朗尼克公司 Improved calibration of vector network analyzer
RU2262713C2 (en) * 2002-01-28 2005-10-20 Чекушкин Всеволод Викторович Method for calibration of measuring systems
CN102025430A (en) * 2010-11-19 2011-04-20 中兴通讯股份有限公司 Closed loop-based automatic calibration method and equipment
CN103543426A (en) * 2013-10-28 2014-01-29 中国电子科技集团公司第四十一研究所 Interpolating compensation method for each-band calibration of network analyzer
CN106840240A (en) * 2016-12-27 2017-06-13 江苏省无线电科学研究所有限公司 Suitable for the two-dimensional linear modification method of digital sensor

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2262713C2 (en) * 2002-01-28 2005-10-20 Чекушкин Всеволод Викторович Method for calibration of measuring systems
CN1442704A (en) * 2002-03-05 2003-09-17 特克特朗尼克公司 Improved calibration of vector network analyzer
CN102025430A (en) * 2010-11-19 2011-04-20 中兴通讯股份有限公司 Closed loop-based automatic calibration method and equipment
CN103543426A (en) * 2013-10-28 2014-01-29 中国电子科技集团公司第四十一研究所 Interpolating compensation method for each-band calibration of network analyzer
CN106840240A (en) * 2016-12-27 2017-06-13 江苏省无线电科学研究所有限公司 Suitable for the two-dimensional linear modification method of digital sensor

Also Published As

Publication number Publication date
CN108871406A (en) 2018-11-23

Similar Documents

Publication Publication Date Title
CN109839583B (en) Analog circuit multi-fault diagnosis method based on improved genetic algorithm
CN109581203B (en) Post-test simulation fault diagnosis method based on genetic algorithm
CN110095066B (en) Spectral confocal signal peak wavelength rapid high-precision extraction method based on Mean-shift
Xiong et al. Analysis of breast cancer using data mining & statistical techniques
CN102129563B (en) Sensory testing device and sensory testing method
Loh A valid and fast spatial bootstrap for correlation functions
CN111784725B (en) Light bar center extraction method
CN112966740B (en) Small sample hyperspectral image classification method based on core sample self-adaptive expansion
CN110366244B (en) WiFi fingerprint indoor positioning method
CN110210067B (en) Method and device for determining threshold straight line based on measurement track
CN108871406B (en) Algorithm for searching excellent calibration points
CN110470980B (en) Analog circuit fault characteristic range determining method based on genetic algorithm
CN109655234A (en) A kind of automated testing method being directed to camera
CN112361977B (en) Linear distance measuring method based on weight distribution
CN109003266A (en) A method of based on fuzzy clustering statistical picture quality subjective evaluation result
CN110333078A (en) A kind of rolling bearing degenerate state stage determines method
Kannan et al. Predicting National Basketball Association success: A machine learning approach
Wachter Graphical estimation of military heights
CN111812122A (en) Second-order frequency selection method and device for microwave frequency sweep data
CN110084423A (en) A kind of link prediction method based on local similarity
CN109283169A (en) A kind of Raman spectral peaks recognition methods of robust
Schreuder et al. 3-P sampling and some alternatives, I
CN115085985B (en) Memory high-efficiency range base number measuring method for network security monitoring
CN113470085B (en) Improved RANSAC-based image registration method
Gomes Jr In-class social networks and academic performance: how good connections can improve grades

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant