CN104574463A - Computing method and device of approximate parallel curves of curve - Google Patents

Computing method and device of approximate parallel curves of curve Download PDF

Info

Publication number
CN104574463A
CN104574463A CN201410852447.1A CN201410852447A CN104574463A CN 104574463 A CN104574463 A CN 104574463A CN 201410852447 A CN201410852447 A CN 201410852447A CN 104574463 A CN104574463 A CN 104574463A
Authority
CN
China
Prior art keywords
point
curve
sampled
primary curve
normal bias
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.)
Pending
Application number
CN201410852447.1A
Other languages
Chinese (zh)
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.)
WUXI SENSEHUGE TECHNOLOGY Ltd
Original Assignee
WUXI SENSEHUGE TECHNOLOGY 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 WUXI SENSEHUGE TECHNOLOGY Ltd filed Critical WUXI SENSEHUGE TECHNOLOGY Ltd
Priority to CN201410852447.1A priority Critical patent/CN104574463A/en
Publication of CN104574463A publication Critical patent/CN104574463A/en
Pending legal-status Critical Current

Links

Abstract

The embodiment of the invention discloses a computing method and device of approximate parallel curves of a curve. The computing method of the approximate parallel curves of the curve comprises the steps that discretization is carried out on the original curve so as to obtain at least two sampling points of the original curve; two normal offset points of the sampling points are obtained according to the position relation between the adjacent sampling points on the original curve; smooth curves sequentially passing through all the normal offset points on the two sides of all the sampling points are drawn, and the approximate parallel curves of the original curve are generated. The computing method and device of the approximate parallel curves of the curve can automatically draw the parallel curves according to the original curve.

Description

Curve approximation parallel lines computing method and device
Technical field
The embodiment of the present invention relates to computer graphics techniques field, particularly relates to a kind of curve approximation parallel lines computing method and device.
Background technology
In the practice of computer drawing software and Graphing of Engineering, often need the parallel curves of a drafting curve.Described parallel curves is otherwise known as equidistant curve, and it to move the track of the new point that same distance obtains by every bit on center line in normal direction along this.Described parallel lines have identical normal with described primary curve, and described flat pattern curve is equal everywhere with the distance of corresponding point on described primary curve.
Although in computer drawing software and Graphing of Engineering, often need the parallel curves of curve plotting.But prior art does not provide the effective method drawing parallel curves.Thus, in drawing practice, need drawing personnel according to the drafting flat pattern curve of primary curve craft.
Summary of the invention
In view of this, the embodiment of the present invention proposes a kind of curve approximation parallel lines computing method and device, to draw parallel curves automatically.
First aspect, embodiments provide a kind of curve approximation parallel lines computing method, described method comprises:
Sliding-model control is carried out to primary curve, to obtain at least two sampled points of described primary curve;
According to the sampled point on described primary curve and the position relationship between neighbouring sample point, ask two normal bias points of described sampled point;
Draw successively by the smooth curve of all described normal bias points in all described sampled point both sides, generate the less parallel curve of described primary curve.
Second aspect, embodiments provide a kind of curve approximation parallel lines calculation element, described device comprises:
Descretization module, for carrying out sliding-model control to primary curve, to obtain at least two sampled points of described primary curve;
Bias point acquisition module, for according to the sampled point on described primary curve and the position relationship between neighbouring sample point, asks two normal bias points of described sampled point;
Parallel curves generation module, for drawing successively by the smooth curve of all described normal bias points in all described sampled point both sides, generates the less parallel curve of described primary curve.
The curve approximation parallel lines computing method that the embodiment of the present invention provides and device, by carrying out sliding-model control to primary curve, to obtain at least two sampled points of described primary curve, according to the sampled point on described primary curve and the position relationship between neighbouring sample point, ask two normal bias points of described sampled point, and draw successively by the smooth curve of all described normal bias points in all described sampled point both sides, generate the less parallel curve of described primary curve, thus the parallel curves of automatic curve plotting.
Accompanying drawing explanation
By reading the detailed description done non-limiting example done with reference to the following drawings, other features, objects and advantages of the present invention will become more obvious:
Fig. 1 is the process flow diagram of the curve approximation parallel lines computing method that first embodiment of the invention provides;
Fig. 2 a is schematic diagram primary curve being carried out to the distribution of coarseness discretize post-sampling point that first embodiment of the invention provides;
Fig. 2 b is schematic diagram primary curve being carried out to the distribution of fine granularity discretize post-sampling point that first embodiment of the invention provides;
Fig. 3 is the schematic diagram that the coordinate of the normal bias point that first embodiment of the invention provides is determined;
Fig. 4 is the distribution schematic diagram of the normal bias point that first embodiment of the invention provides;
Fig. 5 is the effect schematic diagram of the curve approximation parallel lines that first embodiment of the invention provides;
Fig. 6 is the process flow diagram of discretization operations in the curve approximation parallel lines computing method that provide of second embodiment of the invention;
Fig. 7 is the structural drawing of the curve approximation parallel lines calculation element that third embodiment of the invention provides.
Embodiment
Below in conjunction with drawings and Examples, the present invention is described in further detail.Be understandable that, specific embodiment described herein is only for explaining the present invention, but not limitation of the invention.It also should be noted that, for convenience of description, illustrate only part related to the present invention in accompanying drawing but not full content.
First embodiment
Fig. 1 is the process flow diagram of the curve approximation parallel lines computing method that first embodiment of the invention provides.Described curve approximation parallel lines computing method comprise: operation 11 to operation 13.
In operation 11, sliding-model control is carried out to primary curve, to obtain at least two sampled points of described primary curve.
Sliding-model control is carried out to described primary curve, exactly described primary curve is carried out to the sampling of different spacing.The sampling processing performed described primary curve can be uniform sampling processing, also can be sampling processing heterogeneous.Concrete, the uniform sampling processing performed described primary curve is sampled to described primary curve with the sampling interval preset, to obtain at least two sampled points of described primary curve.Described sampling interval refers to sampling interval spatially.
In addition, the sampling processing heterogeneous performed described primary curve can be the curvature dynamic conditioning sampling interval according to described primary curve, then according to the sampling interval of described dynamic conditioning, described primary curve is sampled, to obtain at least two sampled points of described primary curve.
Fig. 2 a and Fig. 2 b respectively illustrates the distribution plan of the discretize of coarseness and the later sampling of fine-grained discretize.See Fig. 2 a and Fig. 2 b, after discretize is carried out to described primary curve, obtain the sampled point on described primary curve.
In operation 12, according to the sampled point on described primary curve and the position relationship between neighbouring sample point, ask two normal bias points of described sampled point.
After completing the discretize to described primary curve, according to the position relationship between the sampled point got after the discretize to described primary curve, ask two normal bias points of described sampled point.
Fig. 3 shows the relative position relation between the described normal bias point sampled point corresponding with it.See Fig. 3, described two normal bias points 33, the line between 34 is perpendicular to the line between the sampled point 31 of its correspondence and neighbouring sample point 32.Further, the distance between the sampled point that described two normal bias points are corresponding with it is constant.
Concrete, the transverse and longitudinal coordinate of described two normal bias points is determined according to following formula (1) and formula (2):
x = x 1 ± d 2 r 2 + 1 - - - ( 1 )
y = y 1 ± d 2 r 2 r 2 + 1 - - - ( 2 )
Wherein, x is the horizontal ordinate of described normal bias point, and y is the ordinate of described normal bias point, x 1the horizontal ordinate of the sampled point that described normal bias point is corresponding, y 1be the ordinate of the sampled point that described normal bias point is corresponding, d is the distance between sampled point that described normal bias point is corresponding with it, and this distance is constant, and r is the slope of line between described normal bias point and the sampled point corresponding to described normal bias point.
In the process of coordinate calculating described two normal bias points, get plus sige simultaneously or get minus sign to obtain described two normal bias points in formula (1) and formula (2).
Further, the distance between the sampled point that described normal bias point is corresponding with it is less than the minimum profile curvature radius of described primary curve.Like this, the situation that just there will not be intersect itself to pitch between two less parallel curves of described primary curve.
Fig. 4 shows all normal bias points of described primary curve.See Fig. 4, described normal bias point is distributed in the both sides of each sampled point on described primary curve successively.
In operation 13, draw successively by the smooth curve of all described normal bias points in all described sampled point both sides, generate the parallel curves of described primary curve.
After getting two normal bias points of each sampled point on described primary curve, draw successively by the smooth curve of all described normal bias points in all described sampled point both sides, just generate the parallel curves of described primary curve.
Two less parallel curves that Fig. 5 is formed after showing and connecting all normal bias points of described primary curve.See Fig. 5, after drawing the smooth curve respectively successively by all described normal bias points in known curve both sides, define approximately parallel two less parallel curves 51,52 with described primary curve.
The present embodiment carries out sliding-model control by reading primary curve, to obtain at least two sampled points of described primary curve, according to the sampled point on described primary curve and the position relationship between neighbouring sample point, ask two normal bias points of described sampled point, and draw successively by the smooth curve of all described normal bias points in all described sampled point both sides, generate the less parallel curve of described primary curve, thus the less parallel curve of a primary curve can be drawn automatically.
Second embodiment
The present embodiment further provides a kind of technical scheme of described primary curve being carried out to sliding-model control based on the above embodiment of the present invention.Concrete, sliding-model control is carried out to primary curve, comprises with at least two sampled points obtaining described primary curve: operation 61 and operation 62.
In operation 61, according to the curvature dynamic conditioning sampling interval of described primary curve.
Be understandable that, on a primary curve, different curved portion correspond to different curvature.When carrying out discretize to described primary curve, sampling interval according to the curvature dynamic conditioning of described primary curve.Preferably, the curvature of described primary curve is larger, and described sampling interval is less.Relative, the curvature of described primary curve is less, and described sampling interval is larger.
In operation 62, the sampling interval according to described dynamic conditioning is sampled to described primary curve, to obtain at least two sampled points of described primary curve.
After primary curve described in dynamic conditioning carries out the sampling interval of sampling, the sampling interval according to described dynamic conditioning is sampled to described primary curve.
The present embodiment is by the curvature dynamic conditioning sampling interval according to described primary curve, and according to the sampling interval of described dynamic conditioning, described primary curve is sampled, to obtain at least two sampled points of described primary curve, thus complete the dynamic sampling to described primary curve.
3rd embodiment
Fig. 7 is the structural drawing of the curve approximation parallel lines calculation element that third embodiment of the invention provides.See Fig. 7, described oriented parallel line computation device comprises: descretization module 71, bias point acquisition module 72 and parallel curves generation module 73.
Described descretization module 71 for carrying out sliding-model control to primary curve, to obtain at least two sampled points of described primary curve.
Described bias point acquisition module 72, for according to the sampled point on described primary curve and the position relationship between neighbouring sample point, asks two normal bias points of described sampled point.
Described parallel curves generation module 73, for drawing successively by the smooth curve of all described normal bias points in all described sampled point both sides, generates the parallel curves of described primary curve.
Further, described descretization module 71 specifically for:
Described primary curve is sampled, to obtain at least two sampled points of described primary curve with the sampling interval preset.
Further, described descretization module 71 specifically for:
According to the curvature dynamic conditioning sampling interval of described primary curve;
Sampling interval according to described dynamic conditioning is sampled to described primary curve, to obtain at least two sampled points of described primary curve.
Further, the coordinate of described normal bias point is:
x = x 1 ± d 2 r 2 + 1 ,
y = y 1 ± d 2 r 2 r 2 + 1 ,
Wherein, x is the horizontal ordinate of described normal bias point, and y is the ordinate of described normal bias point, x 1the horizontal ordinate of the sampled point that described normal bias point is corresponding, y 1be the ordinate of the sampled point that described normal bias point is corresponding, d is the distance between sampled point that described normal bias point is corresponding with it, and this distance is constant, and r is the slope of line between described normal bias point and the sampled point corresponding to described normal bias point.
Further, the distance between the sampled point that described normal bias point is corresponding with it is less than the minimum profile curvature radius of described primary curve.
Those of ordinary skill in the art should be understood that, above-mentioned of the present invention each module or each step can realize with general calculation element, they can concentrate on single calculation element, or be distributed on network that multiple calculation element forms, alternatively, they can realize with the executable program code of computer installation, thus they storages can be performed by calculation element in the storage device, or they are made into each integrated circuit modules respectively, or the multiple module in them or step are made into single integrated circuit module to realize.Like this, the present invention is not restricted to the combination of any specific hardware and software.
Each embodiment in this instructions all adopts the mode of going forward one by one to describe, and what each embodiment stressed is the difference with other embodiments, the same or analogous part between each embodiment mutually see.
The foregoing is only the preferred embodiments of the present invention, be not limited to the present invention, to those skilled in the art, the present invention can have various change and change.All do within spirit of the present invention and principle any amendment, equivalent replacement, improvement etc., all should be included within protection scope of the present invention.

Claims (10)

1. curve approximation parallel lines computing method, is characterized in that, comprising:
Sliding-model control is carried out to primary curve, to obtain at least two sampled points of described primary curve;
According to the sampled point on described primary curve and the position relationship between neighbouring sample point, ask two normal bias points of described sampled point;
Draw successively by the smooth curve of all described normal bias points in all described sampled point both sides, generate the less parallel curve of described primary curve.
2. method according to claim 1, is characterized in that, carries out sliding-model control to primary curve, comprises with at least two sampled points obtaining described primary curve:
Described primary curve is sampled, to obtain at least two sampled points of described primary curve with the sampling interval preset.
3. method according to claim 1, is characterized in that, carries out sliding-model control to primary curve, comprises with at least two sampled points obtaining described primary curve:
According to the curvature dynamic conditioning sampling interval of described primary curve;
Sampling interval according to described dynamic conditioning is sampled to described primary curve, to obtain at least two sampled points of described primary curve.
4. according to the method in claim 2 or 3, it is characterized in that, the coordinate of described normal bias point is:
x = x 1 ± d 2 r 2 + 1 ,
y = y 1 ± d 2 r 2 r 2 + 1 ,
Wherein, x is the horizontal ordinate of described normal bias point, and y is the ordinate of described normal bias point, x 1the horizontal ordinate of the sampled point that described normal bias point is corresponding, y 1be the ordinate of the sampled point that described normal bias point is corresponding, d is the distance between sampled point that described normal bias point is corresponding with it, and this distance is constant, and r is the slope of line between described normal bias point and the sampled point corresponding to described normal bias point.
5. method according to claim 4, is characterized in that, the distance between the sampled point that described normal bias point is corresponding with it is less than the minimum profile curvature radius of described primary curve.
6. a curve approximation parallel lines calculation element, is characterized in that, comprising:
Descretization module, for carrying out sliding-model control to primary curve, to obtain at least two sampled points of described primary curve;
Bias point acquisition module, for according to the sampled point on described primary curve and the position relationship between neighbouring sample point, asks two normal bias points of described sampled point;
Parallel curves generation module, for drawing successively by the smooth curve of all described normal bias points in all described sampled point both sides, generates the less parallel curve of described primary curve.
7. device according to claim 6, is characterized in that, described descretization module specifically for:
Described primary curve is sampled, to obtain at least two sampled points of described primary curve with the sampling interval preset.
8. device according to claim 6, is characterized in that, described descretization module specifically for:
According to the curvature dynamic conditioning sampling interval of described primary curve;
Sampling interval according to described dynamic conditioning is sampled to described primary curve, to obtain at least two sampled points of described primary curve.
9. the device according to claim 7 or 8, is characterized in that, the coordinate of described normal bias point is:
x = x 1 ± d 2 r 2 + 1 ,
y = y 1 ± d 2 r 2 r 2 + 1 ,
Wherein, x is the horizontal ordinate of described normal bias point, and y is the ordinate of described normal bias point, x 1the horizontal ordinate of the sampled point that described normal bias point is corresponding, y 1be the ordinate of the sampled point that described normal bias point is corresponding, d is the distance between sampled point that described normal bias point is corresponding with it, and this distance is constant, and r is the slope of line between described normal bias point and the sampled point corresponding to described normal bias point.
10. device according to claim 9, is characterized in that, the distance between the sampled point that described normal bias point is corresponding with it is less than the minimum profile curvature radius of described primary curve.
CN201410852447.1A 2014-12-31 2014-12-31 Computing method and device of approximate parallel curves of curve Pending CN104574463A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410852447.1A CN104574463A (en) 2014-12-31 2014-12-31 Computing method and device of approximate parallel curves of curve

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410852447.1A CN104574463A (en) 2014-12-31 2014-12-31 Computing method and device of approximate parallel curves of curve

Publications (1)

Publication Number Publication Date
CN104574463A true CN104574463A (en) 2015-04-29

Family

ID=53090429

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410852447.1A Pending CN104574463A (en) 2014-12-31 2014-12-31 Computing method and device of approximate parallel curves of curve

Country Status (1)

Country Link
CN (1) CN104574463A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106202593A (en) * 2015-05-05 2016-12-07 北京大豪科技股份有限公司 The generation method of equidistant curve
CN113706658A (en) * 2021-08-18 2021-11-26 江苏红豆工业互联网有限公司 Discretization parameter drawing method based on clothing arc curve

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106202593A (en) * 2015-05-05 2016-12-07 北京大豪科技股份有限公司 The generation method of equidistant curve
CN106202593B (en) * 2015-05-05 2020-01-24 北京大豪科技股份有限公司 Equidistant curve generation method
CN113706658A (en) * 2021-08-18 2021-11-26 江苏红豆工业互联网有限公司 Discretization parameter drawing method based on clothing arc curve
CN113706658B (en) * 2021-08-18 2023-09-05 江苏红豆工业互联网有限公司 Discretization parameter drawing method based on clothing circular arc curve

Similar Documents

Publication Publication Date Title
CN105701346A (en) Method and system for evaluating track of vehicle
EP2711678A2 (en) Correction of pressure signals measured during supersonic wind tunnel testing
CN102920459B (en) Human body circumference parameter measuring method based on three-dimensional point cloud
CN103995281A (en) Method for rapid rolling laying of three-dimensional observation system
Chatterjee et al. Dynamic behavior of flow around rows of square cylinders kept in staggered arrangement
CN106597496A (en) Position correction method and related device
CN104183128A (en) Traffic state determination method and device
CN104574463A (en) Computing method and device of approximate parallel curves of curve
CN105261031A (en) Straight line detection method and device based on gradient calculation
CN106845785A (en) A kind of Multi-satellite TTC resource regulating method based on multiple objective function
CN106226828B (en) Time domain aviation electromagnetic data constraint fitting of a polynomial leveling method
CN104753075A (en) Identifying method and device of leading oscillating mode of interconnected electric power system
CN104598381A (en) Positioning method for failure test instance in metamorphic testing
CN103177192B (en) Five-hole probe angular characteristics curve data processing method
CN103995944B (en) A kind of free air anomaly extreme value unbiased isopleth map method for drafting
CN113420004A (en) Tunnel point cloud data storage method and device, computer equipment and storage medium
CN105279574A (en) Satellite cable shortest path planning method based on digraph optimization technology
CN102495944B (en) Time series forecasting method and equipment and system adopting same
CN103473458B (en) Method for comparatively analyzing similarities of fold lines
Yang et al. A method for improved accuracy in three dimensions for determining wheel/rail contact points
CN112904424B (en) Method and device for determining position of abnormal body and readable storage medium
CN103366095B (en) A kind of least square fitting signal processing method based on coordinate transform
CN102737393A (en) Method and system for drawing vector diagram of overhead line
CN103364008B (en) Based on the vehicle-mounted mileage calculating system of GPS
CN102722661A (en) Forecasting method of micro-pressure waves at tunnel exit when high-speed train passes through long tunnel

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20150429