CN110111396B - Image drawing method, device, storage medium and apparatus for cylindrical equation - Google Patents

Image drawing method, device, storage medium and apparatus for cylindrical equation Download PDF

Info

Publication number
CN110111396B
CN110111396B CN201910395854.7A CN201910395854A CN110111396B CN 110111396 B CN110111396 B CN 110111396B CN 201910395854 A CN201910395854 A CN 201910395854A CN 110111396 B CN110111396 B CN 110111396B
Authority
CN
China
Prior art keywords
equation
standard
cylindrical
variable
drawn
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
CN201910395854.7A
Other languages
Chinese (zh)
Other versions
CN110111396A (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.)
Wuhan Polytechnic University
Original Assignee
Wuhan Polytechnic University
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 Wuhan Polytechnic University filed Critical Wuhan Polytechnic University
Priority to CN201910395854.7A priority Critical patent/CN110111396B/en
Publication of CN110111396A publication Critical patent/CN110111396A/en
Application granted granted Critical
Publication of CN110111396B publication Critical patent/CN110111396B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • G06T11/20Drawing from basic elements, e.g. lines or circles
    • G06T11/206Drawing of charts or graphs

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Image Generation (AREA)

Abstract

The invention discloses an image drawing method, equipment, a storage medium and a device of a cylindrical equation, wherein the method comprises the following steps: acquiring an equation to be drawn, and intercepting a constant term and a target polynomial corresponding to each equation variable from the equation to be drawn; converting the equation to be drawn into a standard equation conforming to a preset format according to the constant term and the target polynomial; acquiring the index and the coefficient of each equation variable in a standard equation, and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable; and searching a current coordinate calculation formula of the standard equation according to the current equation type, and drawing a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula. According to the method and the device, the equation to be drawn is converted into the standard equation conforming to the preset format, and the type of the current equation is identified according to the standard equation, so that the drawing difficulty of the cylindrical equation is reduced, and any cylindrical equation can be drawn into a cylindrical image conveniently and rapidly.

Description

Image drawing method, device, storage medium and apparatus for cylindrical equation
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a method, an apparatus, a storage medium, and a device for image rendering of a cylindrical equation.
Background
The cylindrical surface comprises three types of an elliptic cylindrical surface, a hyperbolic cylindrical surface and a parabolic cylindrical surface, in the drawing process of an actual cylindrical surface graph, a user must know the type of the cylindrical surface corresponding to an input equation to be drawn, otherwise, the user cannot select a corresponding drawing device to draw, if the user only knows that the graph corresponding to the equation to be drawn is the cylindrical surface, but does not know which cylindrical surface is in particular, the user must clearly put out higher requirements for the cylindrical surface drawing device, and the drawing difficulty of the cylindrical surface equation is increased. Therefore, how to reduce the drawing difficulty of the cylindrical equation is a technical problem to be solved.
The foregoing is provided merely for the purpose of facilitating understanding of the technical solutions of the present invention and is not intended to represent an admission that the foregoing is prior art.
Disclosure of Invention
The invention mainly aims to provide an image drawing method, equipment, a storage medium and a device for a cylindrical equation, which aim to solve the technical problem of how to reduce the drawing difficulty of the cylindrical equation in the prior art.
To achieve the above object, the present invention provides an image drawing method of a cylindrical equation, the method comprising the steps of:
acquiring an equation to be drawn, and intercepting a constant term and a target polynomial corresponding to each equation variable from the equation to be drawn;
Converting the equation to be drawn into a standard equation conforming to a preset format according to the constant term and the target polynomial;
acquiring the index and the coefficient of each equation variable in the standard equation, and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable;
and searching a current coordinate calculation formula of the standard equation according to the current equation type, and drawing a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula.
Preferably, the current equation type is any one of parabolic cylinder equation, elliptic cylinder equation and hyperbolic cylinder equation;
correspondingly, the method for obtaining the index and the coefficient of each equation variable in the standard equation and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable comprises the following specific steps:
acquiring the index and coefficient of each equation variable in the standard equation;
identifying whether the standard equation belongs to the parabolic cylinder equation according to the index of each equation variable;
if the standard equation does not belong to the parabolic cylinder equation, identifying whether the standard equation belongs to the elliptic cylinder equation according to the coefficient of each equation variable;
And if the standard equation does not belong to the elliptic cylindrical equation, the standard equation is considered to belong to the hyperbolic cylindrical equation.
Preferably, the identifying whether the standard equation belongs to the parabolic cylinder equation according to the index of each equation variable specifically includes:
if the indexes of the equation variables are respectively one and two, the standard equation is considered to belong to the parabolic cylinder equation;
and if the index of each equation variable is two, the standard equation is determined not to belong to the parabolic cylinder equation.
Preferably, if the standard equation does not belong to the parabolic cylinder equation, identifying whether the standard equation belongs to the elliptic cylinder equation according to coefficients of equation variables specifically includes:
if the standard equation does not belong to the parabolic cylinder equation, judging whether the positive and negative of the coefficients of the equation variables are the same or not;
if the positive and negative of the coefficients of the equation variables are the same, the standard equation is considered to belong to the elliptic cylindrical equation;
and if the positive and negative of the coefficients of the equation variables are opposite, the standard equation is determined not to belong to the elliptic cylindrical equation.
Preferably, the equation variables include a first variable and a second variable, and the target polynomial includes a first polynomial and a second polynomial;
Correspondingly, the obtaining the equation to be drawn, and intercepting the constant term and the target polynomial corresponding to each equation variable from the equation to be drawn specifically comprises the following steps:
acquiring an equation to be drawn, and intercepting a first polynomial corresponding to the first variable from the equation to be drawn;
taking the intercepted equation to be drawn as a first equation, and intercepting a second polynomial corresponding to the second variable from the first equation;
taking the intercepted first equation as a second equation, and intercepting constant terms from the second equation.
Preferably, the searching the current coordinate calculation formula of the standard equation according to the current equation type, and drawing the cylindrical image corresponding to the standard equation according to the current coordinate calculation formula specifically includes:
searching a current coordinate calculation formula of the standard equation according to the current equation type in a preset mapping relation table, wherein the preset mapping relation table comprises a corresponding relation between the equation type and the coordinate calculation formula;
and drawing the cylindrical image corresponding to the standard equation according to the current coordinate calculation formula.
Preferably, the drawing the cylindrical image corresponding to the standard equation according to the current coordinate calculation formula specifically includes:
Calculating a plurality of target point coordinates of the standard equation according to the current coordinate calculation formula;
and drawing a cylindrical image corresponding to the standard equation according to the target point coordinates.
Further, to achieve the above object, the present invention also provides an image drawing apparatus including: a memory, a processor and a cylindrical equation image rendering program stored on the memory and executable on the processor, which cylindrical equation image rendering program, when executed by the processor, implements the steps of the cylindrical equation image rendering method as described above.
In addition, in order to achieve the above object, the present invention also provides a storage medium having stored thereon an image drawing program of a cylindrical equation which, when executed by a processor, implements the steps of the image drawing method of a cylindrical equation as described above.
In addition, in order to achieve the above object, the present invention also provides an image drawing apparatus of a cylindrical equation, the image drawing apparatus of a cylindrical equation including:
the equation acquisition module is used for acquiring an equation to be drawn, and intercepting a constant term and a target polynomial corresponding to each equation variable from the equation to be drawn;
The equation generation module is used for converting the equation to be drawn into a standard equation conforming to a preset format according to the constant term and the target polynomial;
the type identification module is used for acquiring the index and the coefficient of each equation variable in the standard equation and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable;
and the image drawing module is used for obtaining a current coordinate calculation formula of the standard equation according to the current equation type and drawing a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula.
According to the method, an equation to be drawn is obtained, and a constant term and a target polynomial corresponding to each equation variable are intercepted from the equation to be drawn; converting the equation to be drawn into a standard equation conforming to a preset format according to the constant term and the target polynomial; acquiring the index and the coefficient of each equation variable in the standard equation, and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable; and searching a current coordinate calculation formula of the standard equation according to the current equation type, and drawing a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula. According to the method and the device, the equation to be drawn is converted into the standard equation which accords with the preset format, and the current equation type is identified according to the standard equation, so that the drawing difficulty of the cylindrical equation is reduced, any cylindrical equation is drawn into the cylindrical image, and meanwhile, the operation difficulty of a user is reduced.
Drawings
FIG. 1 is a schematic diagram of an image rendering device of a hardware operating environment according to an embodiment of the present invention;
FIG. 2 is a flow chart of a first embodiment of an image rendering method of the cylindrical equation of the present invention;
FIG. 3 is a flow chart of a second embodiment of the image rendering method of the cylindrical equation of the present invention;
FIG. 4 is a flow chart of a third embodiment of an image rendering method of the cylindrical equation of the present invention;
FIG. 5 is a schematic diagram of a parabolic cylinder image of an embodiment of an image rendering method of the cylinder equation of the present invention;
FIG. 6 is a schematic diagram of a hyperbolic cylindrical image of an embodiment of an image rendering method of the cylindrical equation of the present invention;
fig. 7 is a functional block diagram of a first embodiment of the image rendering device of the cylindrical equation of the present invention.
The achievement of the objects, functional features and advantages of the present invention will be further described with reference to the accompanying drawings, in conjunction with the embodiments.
Detailed Description
It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the scope of the invention.
Referring to fig. 1, fig. 1 is a schematic diagram of an image rendering device of a hardware running environment according to an embodiment of the present invention.
As shown in fig. 1, the image drawing apparatus may include: a processor 1001, such as a CPU, a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. Wherein the communication bus 1002 is used to enable connected communication between these components. The user interface 1003 may include a Display (Display), and the optional user interface 1003 may also include a standard wired interface, a wireless interface. The network interface 1004 may optionally include a standard wired interface, a wireless interface (e.g., WI-FI interface). The memory 1005 may be a high-speed RAM memory or a stable memory (non-volatile memory), such as a disk memory. The memory 1005 may also optionally be a storage device separate from the processor 1001 described above.
It will be appreciated by those skilled in the art that the structure shown in fig. 1 is not limiting of the image rendering device and may include more or fewer components than shown, or may combine certain components, or a different arrangement of components.
As shown in fig. 1, an operating system, a network communication module, a user interface module, and an image drawing program of a cylindrical equation may be included in the memory 1005 as one storage medium.
In the image drawing apparatus shown in fig. 1, the network interface 1004 is mainly used for connecting to a background server, and performing data communication with the background server; the user interface 1003 is mainly used for connecting peripherals; the image drawing apparatus calls an image drawing program of a cylindrical equation stored in the memory 1005 through the processor 1001 and executes an image drawing method of a cylindrical equation provided by an embodiment of the present invention.
The image drawing apparatus calls an image drawing program of a cylindrical equation stored in the memory 1005 by the processor 1001, and performs the following operations:
acquiring an equation to be drawn, and intercepting a constant term and a target polynomial corresponding to each equation variable from the equation to be drawn;
converting the equation to be drawn into a standard equation conforming to a preset format according to the constant term and the target polynomial;
Acquiring the index and the coefficient of each equation variable in the standard equation, and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable;
and searching a current coordinate calculation formula of the standard equation according to the current equation type, and drawing a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula.
Further, the current equation type is any one of a parabolic cylinder equation, an elliptic cylinder equation and a hyperbolic cylinder equation; the processor 1001 may call the image drawing program of the cylindrical equation stored in the memory 1005, and also perform the following operations:
acquiring the index and coefficient of each equation variable in the standard equation;
identifying whether the standard equation belongs to the parabolic cylinder equation according to the index of each equation variable;
if the standard equation does not belong to the parabolic cylinder equation, identifying whether the standard equation belongs to the elliptic cylinder equation according to the coefficient of each equation variable;
and if the standard equation does not belong to the elliptic cylindrical equation, the standard equation is considered to belong to the hyperbolic cylindrical equation.
Further, the processor 1001 may call the image drawing program of the cylindrical equation stored in the memory 1005, and also perform the following operations:
If the indexes of the equation variables are respectively one and two, the standard equation is considered to belong to the parabolic cylinder equation;
and if the index of each equation variable is two, the standard equation is determined not to belong to the parabolic cylinder equation.
Further, the processor 1001 may call the image drawing program of the cylindrical equation stored in the memory 1005, and also perform the following operations:
if the standard equation does not belong to the parabolic cylinder equation, judging whether the positive and negative of the coefficients of the equation variables are the same or not;
if the positive and negative of the coefficients of the equation variables are the same, the standard equation is considered to belong to the elliptic cylindrical equation;
and if the positive and negative of the coefficients of the equation variables are opposite, the standard equation is determined not to belong to the elliptic cylindrical equation.
Further, the equation variables include a first variable and a second variable, and the target polynomial includes a first polynomial and a second polynomial; the processor 1001 may call the image drawing program of the cylindrical equation stored in the memory 1005, and also perform the following operations:
acquiring an equation to be drawn, and intercepting a first polynomial corresponding to the first variable from the equation to be drawn;
Taking the intercepted equation to be drawn as a first equation, and intercepting a second polynomial corresponding to the second variable from the first equation;
taking the intercepted first equation as a second equation, and intercepting constant terms from the second equation.
Further, the processor 1001 may call the image drawing program of the cylindrical equation stored in the memory 1005, and also perform the following operations:
searching a current coordinate calculation formula of the standard equation according to the current equation type in a preset mapping relation table, wherein the preset mapping relation table comprises a corresponding relation between the equation type and the coordinate calculation formula;
and drawing the cylindrical image corresponding to the standard equation according to the current coordinate calculation formula.
Further, the processor 1001 may call the image drawing program of the cylindrical equation stored in the memory 1005, and also perform the following operations:
calculating a plurality of target point coordinates of the standard equation according to the current coordinate calculation formula;
and drawing a cylindrical image corresponding to the standard equation according to the target point coordinates.
In the embodiment, an equation to be drawn is obtained, and a constant term and a target polynomial corresponding to each equation variable are intercepted from the equation to be drawn; converting the equation to be drawn into a standard equation conforming to a preset format according to the constant term and the target polynomial; acquiring the index and the coefficient of each equation variable in the standard equation, and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable; and searching a current coordinate calculation formula of the standard equation according to the current equation type, and drawing a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula. According to the method and the device, the equation to be drawn is converted into the standard equation conforming to the preset format, and the type of the current equation is identified according to the standard equation, so that the drawing difficulty of the cylindrical equation is reduced, any cylindrical equation is drawn into a cylindrical image, and the operation difficulty of a user is reduced.
Based on the above hardware structure, an embodiment of the image drawing method of the cylindrical equation of the present invention is presented.
Referring to fig. 2, fig. 2 is a flowchart of a first embodiment of the image rendering method of the cylindrical equation of the present invention.
In a first embodiment, the image drawing method of the cylindrical equation includes the steps of:
step S10: and acquiring an equation to be drawn, and intercepting a constant term and a target polynomial corresponding to each equation variable from the equation to be drawn.
Note that the execution subject of the present embodiment is an image drawing apparatus, which may be a personal computer, a tablet computer, or other electronic apparatuses, and the present embodiment is not limited thereto. The application scenario of the embodiment is that a user inputs an equation to be drawn through the image drawing device, the image drawing device identifies the type of the equation to be drawn, and performs image drawing on the equation to be drawn according to the type of the equation to be drawn. The equation to be drawn is an equation which is currently input by a user and needs to be drawn, and comprises a plurality of equation variables and constant terms.
It will be appreciated that the equation to be drawn entered by the user may be any combination of the primary, secondary and constant terms of several equation variables, resulting in difficulty in identifying the equation type of the equation to be drawn. Therefore, in order to facilitate the identification of the type of the equation to be drawn, the first term and the second term of each equation variable in the equation to be drawn are combined into the target polynomial of the equation variable, so that the equation to be drawn is divided into a constant term, the target polynomial corresponding to each equation variable and the like, and the basis for carrying out format conversion on the equation to be drawn according to the constant term and the target polynomial is provided.
In a specific implementation, if the equation to be drawn is: 3Z 2 -2X 2 -12Z-4 x=9, wherein X, Z is the equation variable of the equation to be drawn, respectively, and the primary and secondary terms of the variable X are combined to obtain-2 (X-1) 2 Combining the primary and secondary terms of the variable Z to obtain 3 (Z-2) 2 The remaining constant term is 19, so that it is intercepted from the equation to be drawn that the constant term is 19, and the target polynomial of the variable X is-2 (X-1) 2 The target polynomial of the variable Z is 3 (Z-2) 2
Step S20: and converting the equation to be drawn into a standard equation conforming to a preset format according to the constant term and the target polynomial.
It will be appreciated that the standard equation includes the following 9 preset formats:
(1)a 1 (X-X 0 ) 2 a 2 +b 1 (Y-Y 0 ) 2 b 2 +d=0;
(2)a 1 (X-X 0 ) 2 a 2 +c 1 (Z-Z 0 ) 2 c 2 +d=0;
(3)b 1 (Y-Y 0 ) 2 b 2 +c 1 (Z-Z 0 ) 2 c 2 +d=0;
(4)a 1 (X-X 0 ) 2 a 2 +b 1 (Y-Y 0 )b 2 =0;
(5)b 1 (Y-Y 0 ) 2 b 2 +a 1 (X-X 0 )a 2 =0;
(6)a 1 (X-X 0 ) 2 a 2 +c 1 (Z-Z 0 )c 2 =0;
(7)c 1 (Z-Z 0 ) 2 c 2 +a 1 (X-X 0 )a 2 =0;
(8)b 1 (Y-Y 0 ) 2 b 2 +c 1 (Z-Z 0 )c 2 =0;
(9)c 1 (Z-Z 0 ) 2 c 2 +b 1 (Y-Y 0 )b 2 =0。
wherein X, Y and Z are equation variables, a, respectively 1 、a 2 、b 1 、b 2 、c 1 And c 2 Coefficients X, Y and Z, d, X respectively 0 、Y 0 And Z 0 Is constant.
After obtaining the constant term in the equation to be drawn and the target polynomial corresponding to each equation variable, combining the constant term and the target polynomial to obtain a standard equation conforming to a preset format. For example, if the equation to be plotted is: 3Z 2 -2X 2 -12Z-4 x=9, combining the primary and secondary terms of the variable X to obtain-2 (X-1) 2 Combining the primary and secondary terms of the variable Z to obtain 3 (Z-2) 2 The remaining constant term is 19, so that it is intercepted from the equation to be drawn that the constant term is 19, and the target polynomial of the variable X is-2 (X-1) 2 The target polynomial of the variable Z is 3 (Z-2) 2 The standard equation after the conversion of the equation to be drawn is: 3 (Z-2) 2 -2(X-1) 2 =19。
Step S30: and acquiring the index and the coefficient of each equation variable in the standard equation, and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable.
It should be noted that, the equation type is determined by the index and coefficient of the equation variable, so the present embodiment will obtain the index and coefficient of each equation variable in the standard equation, and identify the current equation type of the standard equation according to the index and coefficient of each equation variable.
In specific implementation, obtaining a corresponding relation among the index, the coefficient and the equation type, establishing a type mapping relation table according to the corresponding relation among the index, the coefficient and the equation type, and searching the current equation type corresponding to the index and the coefficient of each equation variable in the standard equation in the type mapping relation table.
Step S40: and searching a current coordinate calculation formula of the standard equation according to the current equation type, and drawing a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula.
It will be appreciated that after identifying the current equation type of the standard equation, cylindrical image rendering will be performed according to the current equation type and the standard equation. In the drawing process, a current coordinate calculation formula of the standard equation is searched according to the current equation type, the coordinates of the standard equation are calculated according to the current coordinate calculation formula, and a cylindrical image of the standard equation is drawn in a preset coordinate system according to the calculated coordinates. Because the standard equation is converted from the equation to be drawn, the cylindrical image is equivalent to the cylindrical image of the equation to be drawn, thereby realizing quick and accurate cylindrical image drawing of the equation to be drawn.
In the embodiment, an equation to be drawn is obtained, and a constant term and a target polynomial corresponding to each equation variable are intercepted from the equation to be drawn; converting the equation to be drawn into a standard equation conforming to a preset format according to the constant term and the target polynomial; acquiring the index and the coefficient of each equation variable in the standard equation, and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable; and searching a current coordinate calculation formula of the standard equation according to the current equation type, and drawing a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula. According to the method and the device, the equation to be drawn is converted into the standard equation conforming to the preset format, and the type of the current equation is identified according to the standard equation, so that the drawing difficulty of the cylindrical equation is reduced, any cylindrical equation is drawn into a cylindrical image, and the operation difficulty of a user is reduced.
Referring to fig. 3, fig. 3 is a flowchart illustrating a second embodiment of the image rendering method of the cylindrical equation according to the present invention, and the second embodiment of the image rendering method of the cylindrical equation according to the present invention is proposed based on the embodiment shown in fig. 2 described above.
In a second embodiment, the current equation type is any one of a parabolic cylinder equation, an elliptic cylinder equation, and a hyperbolic cylinder equation;
correspondingly, the step S30 specifically includes:
step S301: and obtaining the index and the coefficient of each equation variable in the standard equation.
It should be noted that, the equation type is determined by the index and coefficient of the equation variable, so the present embodiment will obtain the index and coefficient of each equation variable in the standard equation, and identify the current equation type of the standard equation according to the index and coefficient of each equation variable.
Step S302: and identifying whether the standard equation belongs to the parabolic cylinder equation according to the index of each equation variable.
It can be understood that the equations to be drawn discussed in this embodiment are all quadratic cylindrical equations, and the quadratic cylindrical equations include: parabolic cylinder equation, elliptic cylinder equation and hyperbolic cylinder equation. The elliptic cylindrical equation and the hyperbolic cylindrical equation are collectively referred to as a non-parabolic cylindrical equation, and the parabolic cylindrical equation differs from the non-parabolic cylindrical equation in that: the indices of the equation variables of the parabolic cylinder equation are one and two, respectively, and the indices of the equation variables of the non-parabolic cylinder equation are two, so that whether the standard equation belongs to the parabolic cylinder equation or not will be identified according to the highest order term index of each equation variable.
In this embodiment, the step S302 specifically includes: if the indexes of the equation variables are respectively one and two, the standard equation is considered to belong to the parabolic cylinder equation; and if the index of each equation variable is two, the standard equation is determined not to belong to the parabolic cylinder equation.
Step S303: and if the standard equation does not belong to the parabolic cylinder equation, identifying whether the standard equation belongs to the elliptic cylinder equation according to the coefficient of each equation variable.
It should be noted that, if the standard equation does not belong to the parabolic cylinder equation, the standard equation belongs to an elliptic cylinder equation or a hyperbolic cylinder equation, and the elliptic cylinder equation is different from the hyperbolic cylinder equation in that: the coefficients of the equation variables of the elliptic cylindrical equation are the same in polarity and the coefficients of the equation variables of the hyperbolic cylindrical equation are opposite in polarity, so that whether the standard equation belongs to the elliptic cylindrical equation or not will be identified according to the coefficients of the equation variables.
In this embodiment, the step S303 specifically includes: if the standard equation does not belong to the parabolic cylinder equation, judging whether the positive and negative of the coefficients of the equation variables are the same or not; if the positive and negative of the coefficients of the equation variables are the same, the standard equation is considered to belong to the elliptic cylindrical equation; and if the positive and negative of the coefficients of the equation variables are opposite, the standard equation is determined not to belong to the elliptic cylindrical equation.
Step S304: and if the standard equation does not belong to the elliptic cylindrical equation, the standard equation is considered to belong to the hyperbolic cylindrical equation.
It will be appreciated that if the standard equation does not belong to the parabolic cylinder equation, the standard equation belongs to an elliptic cylinder equation or a hyperbolic cylinder equation, and at this time, if the standard equation does not belong to the elliptic cylinder equation, the standard equation is considered to belong to the hyperbolic cylinder equation.
In this embodiment, the standard equation is identified by the index of each equation variable in the standard equation to belong to a parabolic cylinder equation or a non-parabolic cylinder equation, and when the standard equation belongs to the non-parabolic cylinder equation, the standard equation is identified by the coefficient of each equation variable to belong to an elliptic cylinder equation or a hyperbolic cylinder equation, so that the classification accuracy of the standard equation is improved.
Referring to fig. 4, fig. 4 is a flowchart of a third embodiment of the image rendering method of the cylindrical equation according to the present invention, and the third embodiment of the image rendering method of the cylindrical equation according to the present invention is proposed based on the second embodiment shown in fig. 3.
In a third embodiment, the equation variables include a first variable and a second variable, and the target polynomial includes a first polynomial and a second polynomial; the step S10 specifically includes:
And obtaining an equation to be drawn, and intercepting a first polynomial corresponding to the first variable from the equation to be drawn.
Taking the intercepted equation to be drawn as a first equation, and intercepting a second polynomial corresponding to the second variable from the first equation.
Taking the intercepted first equation as a second equation, and intercepting constant terms from the second equation.
It should be noted that, let the equation to be drawn be S:
a 1 (X-X 0 ) CX a 2 +b 1 (Y-Y 0 ) CY b 2 +c 1 (Z-Z 0 ) CZ c 2 +d=0;
where CX, CY, and CZ are the indices of the highest order terms corresponding to equation variables X, Y and Z, respectively.
In a specific implementation, the process of calculating the index of the highest order term of each equation and converting the equation to be drawn into the standard equation conforming to the preset format according to the constant term and the target polynomial is as follows:
(1) If cx=cy=2, cz=0 and d+.0, then the conversion process of the equation is as follows:
1) Separating a from S 1 (X-X 0 ) 2 a 2
2) Let s=s-a 1 (X-X 0 ) 2 a 2
3) Separation of b from S 1 (Y-Y 0 ) 2 b 2
4) Let s=s-b 1 (Y-Y 0 ) 2 b 2
5) Separating d from S;
6) Obtaining a standard equation a 1 (X-X 0 ) 2 a 2 +b 1 (Y-Y 0 ) 2 b 2 +d=0。
(2) If cx=cz=2, cy=0 and d+.0, then the conversion process of the equation is as follows:
1) Separating a from S 1 (X-X 0 ) 2 a 2
2) Let s=s-a 1 (X-X 0 ) 2 a 2
3) Separation of c from S 1 (Z-Z 0 ) 2 c 2
4) Let s=s-c 1 (Z-Z 0 ) 2 c 2
5) Separating d from S;
6) Obtaining a standard equation a 1 (X-X 0 ) 2 a 2 +c 1 (Z-Z 0 ) 2 c 2 +d=0。
(3) If cy=cz=2, cx=0 and d+.0, then the conversion process of the equation is as follows:
1) Separation of b from S 1 (Y-Y 0 ) 2 b 2
2) Let s=s-b 1 (Y-Y 0 ) 2 b 2
3) Separation of c from S 1 (Z-Z 0 ) 2 c 2
4) Let s=s-c 1 (Z-Z 0 ) 2 c 2
5) Separating d from S;
6) Obtaining a standard equation b 1 (Y-Y 0 ) 2 b 2 +c 1 (Z-Z 0 ) 2 c 2 +d=0。
(4) If cx=2, cy=1, cz=0 and d=0, the conversion process of the equation is as follows:
1) Separating a from S 1 (X-X 0 ) 2 a 2
2) Let s=s-a 1 (X-X 0 ) 2 a 2
3) Separation of b from S 1 (Y-Y 0 )b 2
4) Let s=s-b 1 (Y-Y 0 )b 2
5) Obtaining a standard equation a 1 (X-X 0 ) 2 a 2 +b 1 (Y-Y 0 )b 2 =0。
(5) If cx=1, cy=2, cz=0 and d=0, the conversion process of the equation is as follows:
1) Separation of b from S 1 (Y-Y 0 ) 2 b 2
2) Let s=s-b 1 (Y-Y 0 ) 2 b 2
3) Separating a from S 1 (X-X 0 )a 2
4) Let s=s-a 1 (X-X 0 )a 2
5) Obtaining a standard equation b 1 (Y-Y 0 ) 2 b 2 +a 1 (X-X 0 )a 2 =0。
(6) If cx=2, cz=1, cy=0 and d=0, the conversion process of the equation is as follows:
1) Separating a from S 1 (X-X 0 ) 2 a 2
2) Let s=s-a 1 (X-X 0 ) 2 a 2
3) Separation of c from S 1 (Z-Z 0 )c 2
4) Let s=s-c 1 (Z-Z 0 )c 2
5) Obtaining a standard equation a 1 (X-X 0 ) 2 a 2 +c 1 (Z-Z 0 )c 2 =0。
(7) If cx=1, cz=2, cy=0 and d=0, the conversion process of the equation is as follows:
1) Separation of c from S 1 (Z-Z 0 ) 2 c 2
2) Let s=s-c 1 (Z-Z 0 ) 2 c 2
3) Separating a from S 1 (X-X 0 )a 2
4) Let s=s-a 1 (X-X 0 )a 2
5) Obtaining a standard equation c 1 (Z-Z 0 ) 2 c 2 +a 1 (X-X 0 )a 2 =0。
(8) If cy=2, cz=1, cx=0 and d=0, the conversion process of the equation is as follows:
1) Separation of b from S 1 (Y-Y 0 ) 2 b 2
2) Let s=s-b 1 (Y-Y 0 ) 2 b 2
3) Separation of c from S 1 (Z-Z 0 )c 2
4) Let s=s-c 1 (Z-Z 0 )c 2
5) Obtaining a standard equation b 1 (Y-Y 0 ) 2 b 2 +c 1 (Z-Z 0 )c 2 =0。
(9) If cy=1, cz=2, cx=0 and d=0, the conversion process of the equation is as follows:
1) Separation of c from S 1 (Z-Z 0 ) 2 c 2
2) Let s=s-c 1 (Z-Z 0 ) 2 c 2
3) Separation of b from S 1 (Y-Y 0 )b 2
4) Let s=s-b 1 (Y-Y 0 )b 2
5) Obtaining a standard equation c 1 (Z-Z 0 ) 2 c 2 +b 1 (Y-Y 0 )b 2 =0。
Further, the step S40 specifically includes:
step S401: searching a current coordinate calculation formula of the standard equation in a preset mapping relation table according to the current equation type;
step S402: and drawing the cylindrical image corresponding to the standard equation according to the current coordinate calculation formula.
It will be appreciated that after identifying the current equation type of the standard equation, cylindrical image rendering will be performed according to the current equation type and the standard equation. The preset mapping relation table comprises a corresponding relation between equation types and coordinate calculation formulas, in the drawing process, a current coordinate calculation formula of the standard equation is searched in the preset mapping relation table according to the current equation types, the coordinates of the standard equation are calculated according to the current coordinate calculation formula, and a cylindrical image of the standard equation is drawn in a preset coordinate system according to the calculated coordinates.
In a specific implementation, let a=a 1 a 2 ,b=b 1 b 2 ,c=c 1 c 2 The expression of the 9 standard equations is:
(1)a(X-X 0 ) 2 +b(Y-Y 0 ) 2 +d=0;
(2)a(X-X 0 ) 2 +c(Z-Z 0 ) 2 +d=0;
(3)b(Y-Y 0 ) 2 +c(Z-Z 0 ) 2 +d=0;
(4)a(X-X 0 ) 2 +b(Y-Y 0 )=0;
(5)b(Y-Y 0 ) 2 +a(X-X 0 )=0;
(6)a(X-X 0 ) 2 +c(Z-Z 0 )=0;
(7)c(Z-Z 0 ) 2 +a(X-X 0 )=0;
(8)b(Y-Y 0 ) 2 +c(Z-Z 0 )=0;
(9)c(Z-Z 0 ) 2 +b(Y-Y 0 )=0。
the process of searching the current coordinate calculation formula of the standard equation according to the current equation type is as follows:
(1) If cx=cy=2, cz=0, the equation type is further identified from the coefficients of the standard equation:
1) If ad <0, bd <0, it means that the equation to be drawn is an elliptic cylindrical equation, and the current coordinate calculation formula is:
Figure BDA0002057595380000151
wherein u is 0,2 pi],V∈(-∞,+∞);
2) If ad <0 and bd > 0, it means that the equation to be drawn is a hyperbolic cylindrical equation, and the current coordinate calculation formula is:
Figure BDA0002057595380000152
wherein u is 0,2 pi],V∈(-∞,+∞);/>
3) If ad > 0 and bd <0, it means that the equation to be drawn is a hyperbolic cylindrical equation, and the current coordinate calculation formula is:
Figure BDA0002057595380000153
wherein u is 0,2 pi],V∈(-∞,+∞);
(2) If cx=cz=2 and cy=0, the current coordinate calculation formula is similar to the above case (1), and this embodiment will not be repeated.
(3) If cy=cz=2 and cx=0, the current coordinate calculation formula is similar to the case of (1) above, and this embodiment will not be repeated.
(4) If cx=2, cy=1, cz=0, d=0, then the equation type is further identified from the coefficients of the standard equation:
1) If ab <0, it means that the equation to be drawn is a parabolic cylinder equation, and the current coordinate calculation formula is:
Figure BDA0002057595380000161
wherein u is E (-. Infinity, +. Infinity), V is E (-. Infinity, +. Infinity);
2) If ab > 0, it means that the equation to be plotted is not a parabolic cylinder equation.
(5) If cx=1, cy=2, cz=0, and d=0, the current coordinate calculation formula is similar to the above (4) case, and the description of this embodiment is omitted.
(6) If cx=2, cz=1, cy=0, and d=0, the current coordinate calculation formula is similar to the above (4) case, and this embodiment will not be repeated.
(7) If cx=1, cz=2, cy=0, and d=0, the current coordinate calculation formula is similar to the case (4) above, and this embodiment will not be repeated.
(8) If cz=1, cy=2, cx=0, and d=0, the current coordinate calculation formula is similar to the above (4) case, and this embodiment will not be repeated.
(9) If cy=1, cz=2, cx=0, and d=0, the current coordinate calculation formula is similar to the case (4) above, and this embodiment will not be repeated.
Further, the step S402 specifically includes:
calculating a plurality of target point coordinates of the standard equation according to the current coordinate calculation formula;
and drawing a cylindrical image corresponding to the standard equation according to the target point coordinates.
In this embodiment, the constant term and the target polynomial corresponding to each equation variable can be accurately obtained through multiple truncations, so that the conversion efficiency of the equation is improved. According to the method, a current coordinate calculation formula corresponding to the current equation type is searched according to a preset mapping relation table, so that the searching efficiency of the coordinate calculation formula is improved, a plurality of target coordinates are calculated according to the current coordinate calculation formula, and therefore drawing points are carried out according to the target coordinates, and cylindrical image drawing of an equation to be drawn is achieved rapidly and accurately.
Further, an embodiment of the image rendering method of the cylindrical equation of the present invention is presented.
In the embodiment, the equation to be drawn is 5 (y+1)/6=3 (z+2) 2 For illustration,/5, the specific drawing procedure is as follows:
(1) From 5 (y+1)/6=3 (z+2) 2 Cut-3 (z+2) in/5 2 /5;
(2) Intercept 5 (y+1)/6 from 5 (y+1)/6=;
(3) Obtaining standard equation-3 (z+2) 2 /5+5(y+1)/6-0;
(4)b=5/6,c=-3/5;
(5) bc < 0, the current coordinate calculation formula is:
Figure BDA0002057595380000171
wherein u is E (-. Infinity, +. Infinity), V is E (-. Infinity, +. Infinity);
(6) Drawing according to the current coordinate calculation formula in the step (5), and obtaining the parabolic cylinder image shown in fig. 5.
Further, to be drawn, the equation is 4=3 (z-2) 2 /5-2(x-1) 2 For illustration,/7, the specific drawing procedure is as follows:
(1) Slave 4=3 (z-2) 2 /5-2(x-1) 2 Cut 2 (x-1) in/7 2 /7;
(2) Slave 4=3 (z-2) 2 Cut-3 in/5 (z-2) 2 /5;
(3) Intercept d=4 from 4=4;
(4) Obtaining standard equation 2 (x-1) 2 /7-3(z-2) 2 /5+4=0;
(5)a=2/7,c=-3/5;
(6) ad > 0, cd < 0, the current coordinate calculation formula is:
Figure BDA0002057595380000172
wherein u is E (0, 2 pi), V is E (- ≡infinity), ++ infinity a) is provided;
(7) Drawing according to the current coordinate calculation formula in the step (6), and obtaining the hyperbolic cylindrical surface image shown in fig. 6.
In the embodiment, the equation to be drawn is converted into the standard equation, the type of the standard equation is identified according to the index and the coefficient of the variable of the standard equation, and the corresponding coordinate calculation formula is obtained, so that the cylindrical image drawing of the equation to be drawn is rapidly and accurately realized, and the drawing difficulty of a user is reduced.
In addition, an embodiment of the present invention also proposes a storage medium having stored thereon an image drawing program of a cylindrical equation, which when executed by a processor, implements the operations of:
acquiring an equation to be drawn, and intercepting a constant term and a target polynomial corresponding to each equation variable from the equation to be drawn;
converting the equation to be drawn into a standard equation conforming to a preset format according to the constant term and the target polynomial;
acquiring the index and the coefficient of each equation variable in the standard equation, and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable;
and searching a current coordinate calculation formula of the standard equation according to the current equation type, and drawing a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula.
Further, the current equation type is any one of a parabolic cylinder equation, an elliptic cylinder equation and a hyperbolic cylinder equation; the image rendering program of the cylinder equation, when executed by the processor, further performs the following operations:
acquiring the index and coefficient of each equation variable in the standard equation;
Identifying whether the standard equation belongs to the parabolic cylinder equation according to the index of each equation variable;
if the standard equation does not belong to the parabolic cylinder equation, identifying whether the standard equation belongs to the elliptic cylinder equation according to the coefficient of each equation variable;
and if the standard equation does not belong to the elliptic cylindrical equation, the standard equation is considered to belong to the hyperbolic cylindrical equation.
Further, the image rendering program of the cylindrical equation, when executed by the processor, further performs the following operations:
if the indexes of the equation variables are respectively one and two, the standard equation is considered to belong to the parabolic cylinder equation;
and if the index of each equation variable is two, the standard equation is determined not to belong to the parabolic cylinder equation.
Further, the image rendering program of the cylindrical equation, when executed by the processor, further performs the following operations:
if the standard equation does not belong to the parabolic cylinder equation, judging whether the positive and negative of the coefficients of the equation variables are the same or not;
if the positive and negative of the coefficients of the equation variables are the same, the standard equation is considered to belong to the elliptic cylindrical equation;
and if the positive and negative of the coefficients of the equation variables are opposite, the standard equation is determined not to belong to the elliptic cylindrical equation.
Further, the equation variables include a first variable and a second variable, and the target polynomial includes a first polynomial and a second polynomial;
the image rendering program of the cylinder equation, when executed by the processor, further performs the following operations:
acquiring an equation to be drawn, and intercepting a first polynomial corresponding to the first variable from the equation to be drawn;
taking the intercepted equation to be drawn as a first equation, and intercepting a second polynomial corresponding to the second variable from the first equation;
taking the intercepted first equation as a second equation, and intercepting constant terms from the second equation.
Further, the image rendering program of the cylindrical equation, when executed by the processor, further performs the following operations:
searching a current coordinate calculation formula of the standard equation according to the current equation type in a preset mapping relation table, wherein the preset mapping relation table comprises a corresponding relation between the equation type and the coordinate calculation formula;
and drawing the cylindrical image corresponding to the standard equation according to the current coordinate calculation formula.
Further, the image rendering program of the cylindrical equation, when executed by the processor, further performs the following operations:
Calculating a plurality of target point coordinates of the standard equation according to the current coordinate calculation formula;
and drawing a cylindrical image corresponding to the standard equation according to the target point coordinates.
In the embodiment, an equation to be drawn is obtained, and a constant term and a target polynomial corresponding to each equation variable are intercepted from the equation to be drawn; converting the equation to be drawn into a standard equation conforming to a preset format according to the constant term and the target polynomial; acquiring the index and the coefficient of each equation variable in the standard equation, and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable; and searching a current coordinate calculation formula of the standard equation according to the current equation type, and drawing a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula. According to the method and the device, the equation to be drawn is converted into the standard equation conforming to the preset format, and the type of the current equation is identified according to the standard equation, so that the drawing difficulty of the cylindrical equation is reduced, any cylindrical equation is drawn into a cylindrical image, and the operation difficulty of a user is reduced.
Referring to fig. 7, fig. 7 is a functional block diagram of a first embodiment of an image rendering device of a cylindrical equation according to the present invention, and the first embodiment of the image rendering device of a cylindrical equation according to the present invention is proposed based on the image rendering method of a cylindrical equation.
In this embodiment, the image drawing apparatus of a cylindrical equation includes:
the equation acquisition module 10 is used for acquiring an equation to be drawn, and intercepting a constant term and a target polynomial corresponding to each equation variable from the equation to be drawn;
the equation generating module 20 is configured to convert the equation to be drawn into a standard equation conforming to a preset format according to the constant term and the target polynomial;
a type identifying module 30, configured to obtain an index and a coefficient of each equation variable in the standard equation, and identify a current equation type of the standard equation according to the index and the coefficient of each equation variable;
the image drawing module 40 is configured to obtain a current coordinate calculation formula of the standard equation according to the current equation type, and draw a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula.
In the embodiment, an equation to be drawn is obtained, and a constant term and a target polynomial corresponding to each equation variable are intercepted from the equation to be drawn; converting the equation to be drawn into a standard equation conforming to a preset format according to the constant term and the target polynomial; acquiring the index and the coefficient of each equation variable in the standard equation, and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable; and searching a current coordinate calculation formula of the standard equation according to the current equation type, and drawing a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula. According to the method and the device, the equation to be drawn is converted into the standard equation conforming to the preset format, and the type of the current equation is identified according to the standard equation, so that the drawing difficulty of the cylindrical equation is reduced, any cylindrical equation is drawn into a cylindrical image, and the operation difficulty of a user is reduced.
In an embodiment, the current equation type is any one of parabolic cylinder equation, elliptic cylinder equation and hyperbolic cylinder equation;
the type identification module 30 is further configured to obtain an index and a coefficient of each equation variable in the standard equation; identifying whether the standard equation belongs to the parabolic cylinder equation according to the index of each equation variable; if the standard equation does not belong to the parabolic cylinder equation, identifying whether the standard equation belongs to the elliptic cylinder equation according to the coefficient of each equation variable; and if the standard equation does not belong to the elliptic cylindrical equation, the standard equation is considered to belong to the hyperbolic cylindrical equation.
In one embodiment, the type identifying module 30 is further configured to identify the standard equation as belonging to the parabolic cylinder equation if the index of each equation variable is one and two, respectively; and if the index of each equation variable is two, the standard equation is determined not to belong to the parabolic cylinder equation.
In an embodiment, the type identifying module 30 is further configured to determine whether the coefficients of the equation variables are the same if the standard equation does not belong to the parabolic cylinder equation; if the positive and negative of the coefficients of the equation variables are the same, the standard equation is considered to belong to the elliptic cylindrical equation; and if the positive and negative of the coefficients of the equation variables are opposite, the standard equation is determined not to belong to the elliptic cylindrical equation.
In an embodiment, the equation variables include a first variable and a second variable, and the target polynomial includes a first polynomial and a second polynomial;
the equation obtaining module 10 is further configured to obtain an equation to be drawn, and intercept a first polynomial corresponding to the first variable from the equation to be drawn; taking the intercepted equation to be drawn as a first equation, and intercepting a second polynomial corresponding to the second variable from the first equation; taking the intercepted first equation as a second equation, and intercepting constant terms from the second equation.
In an embodiment, the image drawing module 40 is further configured to find a current coordinate calculation formula of the standard equation according to the current equation type in a preset mapping relationship table, where the preset mapping relationship table includes a correspondence between an equation type and a coordinate calculation formula; and drawing the cylindrical image corresponding to the standard equation according to the current coordinate calculation formula.
In an embodiment, the image rendering module 40 is further configured to calculate a plurality of coordinates of the target points of the standard equation according to the current coordinate calculation formula; and drawing a cylindrical image corresponding to the standard equation according to the target point coordinates.
Other embodiments or specific implementations of the image rendering device for cylindrical equations according to the present invention may refer to the above method embodiments, and are not described herein.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
The foregoing embodiment numbers of the present invention are merely for the purpose of description, and do not represent the advantages or disadvantages of the embodiments.
The use of the words first, second, third, etc. do not denote any order, and the words may be interpreted as names.
From the above description of the embodiments, it will be clear to those skilled in the art that the above-described embodiment method may be implemented by means of software plus a necessary general hardware platform, but of course may also be implemented by means of hardware, but in many cases the former is a preferred embodiment. Based on such understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art in the form of a software product stored in a storage medium (e.g. ROM/RAM, magnetic disk, optical disk) comprising instructions for causing a terminal device (which may be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to perform the method according to the embodiments of the present invention.
The foregoing description is only of the preferred embodiments of the present invention, and is not intended to limit the scope of the invention, but rather is intended to cover any equivalents of the structures or equivalent processes disclosed herein or in the alternative, which may be employed directly or indirectly in other related arts.

Claims (9)

1. An image rendering method of a cylindrical equation, characterized in that the image rendering method of a cylindrical equation comprises the steps of:
acquiring an equation to be drawn, and intercepting a constant term and a target polynomial corresponding to each equation variable from the equation to be drawn, wherein the equation to be drawn is any one of a parabolic cylinder equation, an elliptic cylinder equation and a hyperbolic cylinder equation;
converting the equation to be drawn into a standard equation conforming to a preset format according to the constant term and the target polynomial;
acquiring the index and the coefficient of each equation variable in the standard equation, and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable;
searching a current coordinate calculation formula of the standard equation according to the current equation type, and drawing a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula;
The obtaining the index and the coefficient of each equation variable in the standard equation, and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable comprises the following steps:
acquiring a corresponding relation among the equation index, the equation coefficient and the equation type;
establishing a type mapping relation table according to the corresponding relation;
searching the current equation type corresponding to the index and the coefficient of each equation variable in the standard equation in the type mapping relation table;
the method specifically includes the steps of searching a current coordinate calculation formula of the standard equation according to the current equation type, and drawing a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula:
searching a current coordinate calculation formula of the standard equation according to the current equation type in a preset mapping relation table, wherein the preset mapping relation table comprises a corresponding relation between the equation type and the coordinate calculation formula;
and drawing the cylindrical image corresponding to the standard equation according to the current coordinate calculation formula.
2. The image rendering method of a cylinder equation according to claim 1,
the method comprises the steps of obtaining the index and the coefficient of each equation variable in the standard equation, and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable, wherein the method specifically comprises the following steps:
Acquiring the index and coefficient of each equation variable in the standard equation;
identifying whether the standard equation belongs to the parabolic cylinder equation according to the index of each equation variable;
if the standard equation does not belong to the parabolic cylinder equation, identifying whether the standard equation belongs to the elliptic cylinder equation according to the coefficient of each equation variable;
and if the standard equation does not belong to the elliptic cylindrical equation, the standard equation is considered to belong to the hyperbolic cylindrical equation.
3. The image rendering method of a cylindrical equation according to claim 2, wherein said identifying whether the standard equation belongs to the parabolic cylindrical equation based on the index of each equation variable, specifically comprises:
if the indexes of the equation variables are respectively one and two, the standard equation is considered to belong to the parabolic cylinder equation;
and if the index of each equation variable is two, the standard equation is determined not to belong to the parabolic cylinder equation.
4. The image rendering method of a cylindrical equation according to claim 3, wherein if the standard equation does not belong to the parabolic cylindrical equation, identifying whether the standard equation belongs to the elliptic cylindrical equation based on coefficients of equation variables, specifically comprises:
If the standard equation does not belong to the parabolic cylinder equation, judging whether the positive and negative of the coefficients of the equation variables are the same or not;
if the positive and negative of the coefficients of the equation variables are the same, the standard equation is considered to belong to the elliptic cylindrical equation;
and if the positive and negative of the coefficients of the equation variables are opposite, the standard equation is determined not to belong to the elliptic cylindrical equation.
5. The image drawing method of a cylindrical equation according to any one of claims 1 to 4, wherein the equation variables include a first variable and a second variable, and the target polynomial includes a first polynomial and a second polynomial;
correspondingly, the obtaining the equation to be drawn, and intercepting the constant term and the target polynomial corresponding to each equation variable from the equation to be drawn specifically comprises the following steps:
acquiring an equation to be drawn, and intercepting a first polynomial corresponding to the first variable from the equation to be drawn;
taking the intercepted equation to be drawn as a first equation, and intercepting a second polynomial corresponding to the second variable from the first equation;
taking the intercepted first equation as a second equation, and intercepting constant terms from the second equation.
6. The image rendering method of a cylindrical equation according to claim 1, wherein the rendering of the cylindrical image corresponding to the standard equation according to the current coordinate calculation formula specifically includes:
calculating a plurality of target point coordinates of the standard equation according to the current coordinate calculation formula;
and drawing a cylindrical image corresponding to the standard equation according to the target point coordinates.
7. An image drawing apparatus, characterized in that the image drawing apparatus comprises: a memory, a processor, and a cylindrical equation image rendering program stored on the memory and executable on the processor, which when executed by the processor, implements the steps of the cylindrical equation image rendering method of any one of claims 1 to 6.
8. A storage medium having stored thereon an image drawing program of a cylindrical equation, which when executed by a processor, implements the steps of the image drawing method of a cylindrical equation according to any one of claims 1 to 7.
9. An image rendering apparatus of a cylindrical equation, characterized in that the image rendering apparatus of a cylindrical equation comprises:
The equation acquisition module is used for acquiring an equation to be drawn, intercepting a constant term and a target polynomial corresponding to each equation variable from the equation to be drawn, wherein the equation to be drawn is any one of a parabolic cylindrical equation, an elliptic cylindrical equation and a hyperbolic cylindrical equation;
the equation generation module is used for converting the equation to be drawn into a standard equation conforming to a preset format according to the constant term and the target polynomial;
the type identification module is used for acquiring the index and the coefficient of each equation variable in the standard equation and identifying the current equation type of the standard equation according to the index and the coefficient of each equation variable;
the image drawing module is used for obtaining a current coordinate calculation formula of the standard equation according to the current equation type and drawing a cylindrical image corresponding to the standard equation according to the current coordinate calculation formula;
the type identification module is also used for acquiring the corresponding relation among the equation index, the equation coefficient and the equation type; establishing a type mapping relation table according to the corresponding relation; searching the current equation type corresponding to the index and the coefficient of each equation variable in the standard equation in the type mapping relation table;
The image drawing module is further used for searching a current coordinate calculation formula of the standard equation according to the current equation type in a preset mapping relation table, wherein the preset mapping relation table comprises a corresponding relation between the equation type and the coordinate calculation formula; and drawing the cylindrical image corresponding to the standard equation according to the current coordinate calculation formula.
CN201910395854.7A 2019-05-13 2019-05-13 Image drawing method, device, storage medium and apparatus for cylindrical equation Active CN110111396B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910395854.7A CN110111396B (en) 2019-05-13 2019-05-13 Image drawing method, device, storage medium and apparatus for cylindrical equation

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910395854.7A CN110111396B (en) 2019-05-13 2019-05-13 Image drawing method, device, storage medium and apparatus for cylindrical equation

Publications (2)

Publication Number Publication Date
CN110111396A CN110111396A (en) 2019-08-09
CN110111396B true CN110111396B (en) 2023-05-26

Family

ID=67489740

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910395854.7A Active CN110111396B (en) 2019-05-13 2019-05-13 Image drawing method, device, storage medium and apparatus for cylindrical equation

Country Status (1)

Country Link
CN (1) CN110111396B (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017028436A1 (en) * 2015-08-18 2017-02-23 百度在线网络技术(北京)有限公司 Drawing tool implementation method, apparatus, device, and computer storage medium
CN108170101A (en) * 2017-12-27 2018-06-15 深圳市汇川技术股份有限公司 Towards the interpolating method and system of polynomial spline curve
CN108711109A (en) * 2018-05-28 2018-10-26 中国平安人寿保险股份有限公司 Reserve Fund computing system update method, equipment, storage medium and device

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5007758B2 (en) * 2010-06-29 2012-08-22 株式会社ニコン Image classification device
CN102013182A (en) * 2010-12-10 2011-04-13 哈尔滨工业大学深圳研究生院 Mathematical communication method and system convenient for communication of freehand curve and handwritten expression
EP2600315B1 (en) * 2011-11-29 2019-04-10 Dassault Systèmes Creating a surface from a plurality of 3D curves
CN104503957B (en) * 2015-01-12 2018-08-24 深圳市心讯网络科技有限公司 A kind of formula graphic automatic generation method and device
JP7006081B2 (en) * 2017-09-25 2022-01-24 カシオ計算機株式会社 Graph drawing system, calculation server, graph drawing system control method, and program for calculation server

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017028436A1 (en) * 2015-08-18 2017-02-23 百度在线网络技术(北京)有限公司 Drawing tool implementation method, apparatus, device, and computer storage medium
CN108170101A (en) * 2017-12-27 2018-06-15 深圳市汇川技术股份有限公司 Towards the interpolating method and system of polynomial spline curve
CN108711109A (en) * 2018-05-28 2018-10-26 中国平安人寿保险股份有限公司 Reserve Fund computing system update method, equipment, storage medium and device

Also Published As

Publication number Publication date
CN110111396A (en) 2019-08-09

Similar Documents

Publication Publication Date Title
US11055561B2 (en) Similar picture identification method, device, and storage medium
CN107688950B (en) After-sale consultation method for household appliances, electronic equipment and computer readable storage medium
CN110096540B (en) Mapping data conversion method, device, storage medium and device
US10491693B2 (en) Method and apparatus for deploying edge servers
US9817845B2 (en) Three-dimensional image file searching method and three-dimensional image file searching system
CN110866555A (en) Incremental data clustering method, device and equipment and readable storage medium
CN107038199B (en) Drawing method and device
CN111290684A (en) Image display method, image display device and terminal equipment
CN110111396B (en) Image drawing method, device, storage medium and apparatus for cylindrical equation
CN105302827B (en) A kind of searching method and equipment of event
CN115810057A (en) Image color data processing method and device and server
CN111353484A (en) Image character recognition method, device, equipment and readable storage medium
CN116362166A (en) Pattern merging system and method for chip packaging
CN115830343A (en) Color identification method based on HSV color space
CN110940951A (en) Positioning method and device
CN110134909B (en) Curved surface drawing method, equipment, storage medium and device
CN109993152B (en) Mode conversion method, equipment, storage medium and device for coordinate curve integration
CN109948114B (en) Arc length curve integral automatic calculation method, equipment, storage medium and device
CN109947398B (en) Triple integral solving method and device, terminal equipment and readable storage medium
US20050073721A1 (en) Form recognizing apparatus, form recognizing method, program and storage medium
CN111143270B (en) Distance projection calculation method, device, calculation equipment and storage medium
CN110046321B (en) Curve integral calculation method, device, equipment and storage medium
CN110047137B (en) Paraboloid drawing method, device, equipment and storage medium
CN111061994A (en) Calculation method and device for function derivation, calculation equipment and storage medium
CN110009747B (en) Single-sheet hyperboloid equation identification method, equipment, storage medium and device

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