1 Introduction

Bézier curves are the powerful mechanism for modeling in computer-aided geometric design (CAGD) and computer graphics (CG). Bézier curves have a lot of applications in the areas of science, engineering, and technology such as: railway route or highway modeling, networks, animation, computer-aided design system, robotics, environment design, communications, and many other fields due to their computational simplicity and stability. However, the classical Bézier curves have still some noiseless limitations due to their fixed shape and position relative to their control polygon [13]. In geometric modeling and engineering, practical applications of Bézier curves are restricted due to their shortcomings, and to overcome these shortcomings, a lot of work has been carried out [410]. The control over the shape and position of curves is enhanced by introducing the shape control parameters into Bézier approach. Another limitation in the classical Bézier curves is their representation in a polynomial form. Thus many scholars try to search for the solution of this issue in a non-polynomial function space.

Over the past few years, a significant work has been carried out, with the help of trigonometric functions, polynomials, or their combination, for the description of curves and surfaces. These trigonometric polynomials play a significant role in many fields like medicine, electronics [11], and computer-aided geometric design [12]. In recent years, geometric modeling by using trigonometric polynomials has achieved much consideration. Yan and Liang [13] constructed Bézier-like curve and rectangular Bézier-like surface based on a new type of polynomial basis functions with single shape parameter which they achieved by the recursive technique. Hu et al. [14] constructed geometric continuity conditions for the construction of free-form generalized Bézier curves with n shape parameters. These free-form complex shape-adjustable generalized Bézier curves can be modeled by using shape-adjustable generalized Bernstein basis functions. These newly proposed approaches not only take over the benefits of classical Bézier curve and surface schemes, but also resolve the issue of shape adjustability of Bézier curves and surfaces with the help of multiple shape parameters. In 2019, BiBi et al. [15] proposed a new approach using the generalized hybrid trigonometric Bézier curve (shortly, GHT-Bézier) with shape parameters to solve the problem in construction of some symmetric curves and surfaces. These curves are easily modified by changing the values of shape parameters. Using GHT-Bézier curves, they constructed some free-form complex curves with restriction of parametric continuity. To show the efficiency of modeling, the authors also constructed different types of symmetric curves and surfaces with their continuity conditions and symmetric formulas. Maqsood et al. [16] constructed the generalized trigonometric Bézier (GT-Bézier) curves via GT-basis functions with shape parameters. They modeled some complex curves and surfaces using \(C^{3}\) and \(G^{2}\) continuity conditions. The proposed basis functions provide an alternative approach to generate the complex curves using \(C^{3}\) and \(G^{2}\) continuity conditions with simple and straightforward calculation for proposed algorithm because they are blended with linear polynomials rather than trigonometric functions.

In 2004, the cubic trigonometric polynomial curves were constructed by Han [17] with a shape parameter and \(C^{2}\) and \(G^{3}\) continuity conditions having nonuniform knot vector. It has been observed that the trigonometric polynomial curves can better approximate to the classical cubic B-spline curves or to the given control polygon than the classical cubic B-spline curves. The cubic trigonometric Bézier basis functions with two shape parameters were developed by Han et al. [18]. They also constructed cubic trigonometric Bézier curve with two shape parameters similar to the classical Bézier curve that was based on these basis functions. They observed that due to the presence of shape parameters the shape of trigonometric Bézier curve better approximates to the given control polygon than the classical cubic Bézier curves. Han and Zhu [19] constructed five trigonometric blending functions using two exponential shape parameters that have geometric properties similar to the classical Bézier curves. The quadratic trigonometric basis functions were constructed by Bashir et al. [20] using two shape parameters. Moreover, they modeled a rational quadratic trigonometric Bézier curve using these trigonometric basis functions as well as two curve segments connected by using \(C^{2}\) and \(G^{2}\) continuity conditions. Yan expressed an algebraic-trigonometric mixed piecewise curve with two shape parameters and cubic trigonometric nonuniform B-spline curves with local shape parameters in [21] and [22], respectively. Hu et al. [23] constructed geometric continuity constraints for H-Bézier curve of degree n. Recently, many researchers have developed the positivity-preserving rational quartic spline interpolation [24], cubic triangular patches scattered data interpolation [25], rational bi-cubic Ball image interpolation [26], quasi-quintic trigonometric Bézier curve with shape parameters [27], curve modeling by new cubic trigonometric Bézier with shape parameters [28], continuity conditions for \(G^{1}\) joint of S-λ curves and surfaces [29], generalized Bernstein basis functions for approximation of multi-degree reduction of Bézier curve [30], surface modeling in medical imaging by Ball basis functions [31], and geometric conditions for the generalized H-Bézier model [32] which have many applications in medicine, science, and engineering. Khalid and Lobiyal [33] presented the extension of Lupaş Bézier curves/surfaces and rational Lupaş Bernstein functions with shape parameters having all positive \((p, q)\)-integers values. They presented two techniques named de-Casteljau’s algorithm and Korovkin’s type approximation based on \((p, q)\)-integers by using two parameter family of Lupaş \((p, q)\)-Bernstein functions. Lupaş [34] studied the q-analogue of the Bernstein operator. Mursaleen et al. [35] presented the analogue of \((p, q)\)-Bernstein operators, which is a generalization of q-Bernstein operators, and studied its approximation properties based on Korovkin’s type approximation theorem of \((p, q)\)-Bernstein operators.

In this research work, GBT-Bézier curves with two shape parameters are constructed based on GBT-Bernstein basis functions of degree m. Furthermore, the adjacent GBT-Bézier curve segments are connected using parametric and geometric continuity conditions which can be utilized to model free-form complex shapes. As a continuation of traditional Bézier curves, these GBT-Bézier curves will also offer a new application range in the field of manufacturing industry, computer vision, computer graphics, computer animation, and multimedia technology.

In this work, we make the following technical contributions:

  • \(C^{3}\) continuity of the 2D GBT-Bézier curves;

  • \(G^{k}\) (\(k \leq 3\)) geometric continuity of the 2D GBT-Bézier curves.

The outline of this paper is structured in the following manner. Some basic definitions and characteristics of GBT-Bézier curves are given in Sect. 2. Continuity constraints for joining the two GBT-Bézier curve segments are discussed in Sect. 3. Some modeling examples are given in Sect. 4. Concluding remarks on this research are given in Sect. 5.

2 Definition and characteristics of GBT-Bézier curves

The definitions and properties of GBT-Bernstein basis functions and GBT-Bézier curves with shape parameters are given in this section.

2.1 GBT-Bernstein basis functions

Definition 1

For \(\mu ,\nu \in [-1,1]\) and any \(z\in [0,1]\),

$$ \textstyle\begin{cases} f_{0,2}(z)=(1-\sin (\frac{\pi }{2}z))(1-\mu \sin (\frac{\pi }{2}z)), \\ f_{1,2}(z)=(1-f_{0,2}(z)-f_{2,2}(z)), \\ f_{2,2}(z)=(1-\cos (\frac{\pi }{2}z))(1-\nu \cos (\frac{\pi }{2}z)), \end{cases} $$
(1)

are called second degree GBT-Bernstein basis functions associated with shape parameters μ, ν. For any integer m (\(m\geq 3\)), the functions, \(f_{k,m}(z)\) (\(k=0,1,2,\ldots,m\)) defined iteratively

$$ f_{k,m}(z)=(1-z)f_{k,m-1}(z)+ zf_{k-1,m-1}(z), $$
(2)

are mth degree GBT-Bernstein basis functions. In position, when \(k=-1\) or \(k>n\), the function \(f_{k,m}(z)=0\). Figure 1 exhibits the graphs of GBT-Bernstein basis functions of multiple degrees with different values of shape parameters as \(\mu , \nu =1\) (orange), 0.3 (green), −0.3 (red), −1 (blue).

Figure 1
figure 1

GBT-basis functions of different degrees with multiple shape parameters

Remark 1

It is noted that the expressions given in equation (2) differ from the ones we introduced in our earlier work [16] in that we explicitly added polynomial instead of trigonometric functions. We found in our experiments that the trigonometric functions were not intuitive enough for the users to control, while resulting in unnecessarily complex computations. As we prove in this work, we are able to derive sufficiently high order derivative constraints (up to \(C^{3}\) and \(G^{3}\)) while keeping linear polynomial which provided smoother output as compared to Maqsood [16]. We advocate therefore Definition 1 from now on.

Theorem 1

GBT-Bernstein basis functions have the following characteristics:

  1. 1.

    Degeneracy: When \(\mu , \nu = 1\) and \(\sin (\frac{\pi }{2}z), 1-\cos (\frac{\pi }{2}z)=z\), then \(f_{k,m}(z)=B_{k,m}(z)(k=0,1,\ldots,m; m\geq 2)\). That is, with \(\mu , \nu = 1\) and \(\sin (\frac{\pi }{2}z), (1-\cos (\frac{\pi }{2}z))=z\), the GBT-Bernstein basis functions of degree m become the same as classical Bernstein basis functions of degree m.

  2. 2.

    Nonnegativity: For any \(\mu ,\nu \in [-1,1]\), \(f_{k,m}(z)\geq 0\) \((k=0,1,2,\ldots,m)\).

  3. 3.

    Partition of unity: \(\sum^{m}_{k=0} f_{k,m}(z)=1\).

  4. 4.

    Symmetry: When \(\mu =\nu \), \(f_{k,m}(z)\)\((k=0,1,2,\ldots,m)\) are symmetric, i.e.,

    $$ f_{m-k,m}(z, \mu , \nu )= f_{k,m}(1-z, \mu , \nu ). $$
  5. 5.

    Derivative at the end points:

    $$\begin{aligned}& f'_{k,m}(0)= \textstyle\begin{cases} -(m-2+\frac{\pi }{2}(1+\mu )), & k=0, \\ (m-2+\frac{\pi }{2}(1+\mu )),&k=1, \\ 0, & \textit{other}, \end{cases}\displaystyle \end{aligned}$$
    (3)
    $$\begin{aligned}& f'_{k,m}(1)= \textstyle\begin{cases} -(m-2+\frac{\pi }{2}(1+\nu )), & k=m-1, \\ (m-2+\frac{\pi }{2}(1+\nu )), & k=m, \\ 0, &\textit{other}, \end{cases}\displaystyle \end{aligned}$$
    (4)
    $$\begin{aligned}& f''_{k,m}(0)= \textstyle\begin{cases} (m-2)(m-3)+\frac{\pi }{2}(2(m-2)(1+\mu )+\pi \mu ), \quad k=0, \\ \frac{-1}{4}(8(m-2)(m-3)+\pi (8(m-2)(1+\mu )+\pi (1+2\mu -\nu )), \\ \quad k=1, \\ \frac{1}{4}(4(m-2)(m-3)+\pi (4(m-2)(1+\mu )+\pi (1-\nu )),\\ \quad k=2, \\ 0, \quad \textit{other}, \end{cases}\displaystyle \end{aligned}$$
    (5)
    $$\begin{aligned}& f''_{k,m}(1)= \textstyle\begin{cases} (m-2)(m-3)+\frac{\pi }{2}(2(m-2)(1+\nu )+\pi \nu ),\quad k=m, \\ \frac{-1}{4}(8(m-2)(m-3)+\pi (8(m-2)(1+\nu )+\pi (1+2\nu -\mu )),\\ \quad k=m-1, \\ \frac{1}{4}(4(m-2)(m-3)+\pi (4(m-2)(1+\nu )+\pi (1-\mu )),\\ \quad k=m-2, \\ 0, \quad \textit{other}, \end{cases}\displaystyle \end{aligned}$$
    (6)
    $$\begin{aligned}& f'''_{k,m}(0)= \textstyle\begin{cases} \frac{-1}{8}[8m_{1}+\pi ((12 m_{2}-\pi ^{2})(1+\mu )+12 m_{3}\pi \mu )],& k=0, \\ \frac{1}{8}[24m_{1}+\pi ((36 m_{2}-\pi ^{2})(1+\mu )+6 m_{3}\pi (1+4 \mu -\nu ))],& k=1, \\ \frac{-1}{8}[24m_{1}+\pi ((36 m_{2}+ 12m_{3}\pi )(1+\mu )- 12 m_{3} \pi \nu ))],& k=2, \\ \frac{1}{8}[8m_{1}+\pi (12 m_{2}(1+\mu )+6 m_{3}\pi (1-\nu ))],& k=3, \\ 0,& \textit{other}. \end{cases}\displaystyle \end{aligned}$$
    (7)
    $$\begin{aligned}& f'''_{k,m}(1)= \textstyle\begin{cases} \frac{1}{8}[8 m_{1}+\pi ((12 m_{2}-\pi ^{2})(1+\nu )+12 m_{3}\pi \nu )], \quad k=m, \\ \frac{-1}{8}[24 m_{1}+\pi ((36 m_{2}-\pi ^{2})(1+\nu )+6 m_{3}\pi (1+4 \nu -\mu ))],\\ \quad k=m-1, \\ \frac{1}{8}[24 m_{1}+\pi ((36 m_{2}+12 m_{3}\pi )(1+\nu )-12 m_{3} \pi \mu )], \\ \quad k=m-2, \\ \frac{-1}{8}[8m_{1}+\pi (12 m_{2}(1+\nu )+6 m_{3}\pi (1-\mu ))], \quad k=m-3, \\ 0, \quad \textit{other}. \end{cases}\displaystyle \end{aligned}$$
    (8)

    where \(m_{1}=(m-4)(m-3)(m-2)\), \(m_{2}=(m-3)(m-2)\), and \(m_{3}=(m-2)\).

Proof

We shall prove (2), (3), (4), and (5). The remaining properties can be proved with direct calculation.

  1. 2.

    For \(z \in [0,1]\), \(\mu ,\nu \in [-1,1]\), \(f_{0,2}(z)\), \(f_{1,2}(z)\), \(f_{2,2}(z) \geq 0\), and \((1-z) \geq 0\), GBT-Bernstein basis functions will always be positive.

  2. 3.

    We can prove it by using inductive hypothesis as when \(n=2\), we obtain

    $$ \sum^{2}_{k=0} f_{k,2}(z)=1. $$

    Now suppose that the equality holds for \(m=s\).

    $$ \sum^{s}_{k=0} f_{k,s}(z)=1. $$

    Thus, for \(m=s+1 \), according to formula (2), we have

    $$\begin{aligned} \sum^{s+1}_{k=0} f_{k,s+1}(z) =& \sum^{s+1}_{k=0}\bigl[(1-z)f_{k,s}(z)+z f_{k-1,s}(z)\bigr], \\ \sum^{s+1}_{k=0} f_{k,s+1}(z) =&(1-z) \sum^{s}_{k=0}f_{k,s}(z)+z \sum^{s}_{k=0}f_{k,s}(z)+(1-z)f_{s+1,s}(z)++zf_{-1,s}(z) \\ =&(1-z)+z+0+0 \\ =&1. \end{aligned}$$
  3. 4.

    For \(m=2\) and \(\mu =\nu \),

    $$ \sum^{2}_{k=0} f_{k,2}(z)= \sum^{2}_{k=0} f_{2-k,2}(1-z). $$

    Now imagine that the GBT-Bernstein basis functions of degree s are consistent. Then from this inductive hypothesis and iterative formula (2), we have

    $$\begin{aligned}& f_{k,s+1}(1-z)= z f_{k,s}(1-z)+(1-z)f_{k-1,s}(1-z), \\& \begin{aligned} f_{k,s+1}(z)&= z f_{s-k,s}(z)+(1-z)f_{s-k+1,s}(z) \\ &=(1-z)f_{s+1-k,s}(z)+z f_{s-k,s}(z) \\ &=f_{s+1-k,s+1}(z). \end{aligned} \end{aligned}$$
  4. 5.

    For any \(h_{k}\in R\) (\(k = 0,1,\ldots,m; m = 2\)), we consider a linear combination as follows:

    $$ \sum^{m}_{k=0}h_{k} f_{k,m}(z)=0, \quad z\in [0,1]. $$
    (9)

    By taking s-order derivatives of the above formula corresponding to z on each side, we get

    $$ \sum^{m}_{k=0}h_{k}f_{k,m}^{s}(z)=0\quad (s=0,1,2,\ldots,m). $$
    (10)

    By using (3) and (5), s-order derivatives of GBT-Bernstein basis functions at \(z=0\) can be represented as follows:

    $$ \textstyle\begin{cases} f_{k,m}^{s}(0)\neq 0 \quad (k=0,1,2,\ldots,s);(s=1,2,\ldots,m), \\ f_{k,m}^{s}(0)= 0 \quad (k=s+1,\ldots,m);(s=1,2,\ldots,m). \end{cases} $$
    (11)

    From (10) and (11), we can obtain the following system of linear equations for \(s=0\) with respect to \(h_{k} (k=0,1,\ldots,m)\):

    $$ \textstyle\begin{cases} h_{0}f_{0,m}^{0}(0)=0, \\ h_{0}f_{0,m}^{1}(0)+h_{1}f_{1,m}^{0}(1)=0, \\ \ldots \\ h_{0}f_{0,m}^{m-1}(0)+h_{1}f_{1,m}^{m-1}(0)+\cdots+h_{m-1}f_{m-1,m}^{m-1}(0)=0, \\ h_{0}f_{0,m}^{m}(0)+h_{1}f_{1,m}^{m}(0)+\cdots+h_{m-1}f_{m-1,m}^{m}(0)+h_{m}f_{m,m}^{m}(0)=0. \end{cases} $$
    (12)

    Thus, it is obvious that \(f_{k,m}(z)\) (\(k=0,1,\ldots,m\)) are linearly independent as \(h_{k}=0\) (\(k=0,1,\ldots,m\)).

 □

2.2 Composition of GBT-Bézier curves

Definition 2

For given control points \(Q_{k}\in R^{m}\) (\(m=2,3; k=0,1,\ldots,m\)), the curves

$$ \{\Pi _{z}\}: F(z;\mu ,\nu )=\sum^{m}_{k=0} f_{k,m}(z)Q_{k},\quad 0\leq z \leq 1 $$
(13)

are called GBT-Bézier curves, where \(f_{k,m}(z)\) are GBT-Bernstein basis functions.

From the geometric characteristics of GBT-Bernstein basis functions, GBT-Bézier curves have the following geometric properties.

  1. 1.

    End-point properties: For any \(\mu ,\nu \in [-1,1]\), we have

    $$\begin{aligned}& F(0) = Q_{0}, \\& F(1) = Q_{m}, \\& F'(0) = \frac{1}{2}\bigl(2(m-2)+\pi (1+\mu )\bigr) (Q_{1}-Q_{0}), \\& F'(1) = \frac{1}{2}\bigl(2(m-2)+\pi (1+\mu )\bigr) (Q_{m}-Q_{m-1}), \\& F''(0) = \frac{1}{4}\bigl[4(m-2) \bigl(m-3+\pi (1+\mu )\bigr) (Q_{0}-2Q_{1}+Q_{2})+2 \pi ^{2}\mu (Q_{0}-Q_{1}) \\& \hphantom{F''(0) = }{} + \pi ^{2}(1-\mu ) (Q_{2}-Q_{1})\bigr], \\& F''(1) = \frac{1}{4}\bigl[4(m-2) \bigl(m-3+\pi (1+\mu )\bigr) (Q_{m-2}-2Q_{m-1}+Q_{m}) \\& \hphantom{F''(1) =}{} + \pi ^{2}(1-\mu ) (Q_{m-2}-Q_{m-1})+2\pi ^{2}\mu (Q_{m}-Q_{m-1})\bigr], \\& F'''(0) = \frac{1}{8}{\pi }^{3}\bigl(\bigl(-\bigl((m-2)^{3}-2(m-2)-1\bigr)- \bigl(3(m-2) (m-1)-1\bigr) \mu \bigr)Q_{0} \\& \hphantom{F'''(0) =}{} + \bigl(\bigl(3(m-2)^{3}-(m-1)\bigr)+\bigl(3(m-2) (3m-5)-1\bigr)\mu -3(m-2)\nu \bigr)Q_{1} \\& \hphantom{F'''(0) =}{} - 3(m-2) \bigl(\bigl((m-2)^{2}+1\bigr)+\bigl(3(m-3)+2\bigr)\mu -2 \nu \bigr)Q_{2}\bigr) \\& \hphantom{F'''(0) =}{} + (m-2) \bigl(\bigl(m^{2}-4m+6\bigr)+3(m-3)\mu -3\nu \bigr)Q_{3}), \\& F'''(1) = \frac{1}{8} { \pi }^{3}(1+\nu ) \bigl(\bigl(6(m-2)+1\bigr)Q_{m-1}-3(m-2)Q_{m-2}- \bigl(3(m-2)+1\bigr)Q_{m}\bigr). \end{aligned}$$
  2. 2.

    Symmetry: \(Q_{0},Q_{1},Q_{2},\ldots,Q_{m}\) and \(Q_{m},Q_{m-1},Q_{m-2},\ldots,Q_{0}\) describe the symmetric GBT-Bézier curves, which can be written as follows:

    $$ F(z,\mu ,\nu ,Q_{0},Q_{1},Q_{2}, \ldots,Q_{m})= F(1-z,\nu ,\mu ,Q_{m},Q_{k-1},Q_{m-2}, \ldots,Q_{0}). $$
  3. 3.

    Convex hull property: The whole GBT-Bézier curve must be contained inside the control polygon spanned by \(Q_{0},Q_{1},Q_{2},\ldots,Q_{m}\).

  4. 4.

    Geometric invariance: The shape of the GBT-Bézier curve is independent of the selection of a coordinate system for the reason that \(F(z,\mu ,\nu )\) is an affine combination of the control points, which means it satisfies the next two equations:

    $$\begin{aligned}& F(z,\mu ,\nu ,Q_{0}+\overline{Q},Q_{1}+ \overline{Q},Q_{2}+ \overline{Q},\ldots,Q_{m}+ \overline{Q}) \\& \quad = F(z,\mu ,\nu ,Q_{0},Q_{1},Q_{2}, \ldots,Q_{m})+\overline{Q}, \\& F(z,\mu ,\nu ,MQ_{0},MQ_{1},MQ_{2}, \ldots,MQ_{m}) \\& \quad = MF(z,\mu ,\nu ,Q_{0},Q_{1},Q_{2}, \ldots,Q_{m}), \end{aligned}$$

    where is a random vector in \(R^{2}\) or \(R^{3}\) and M is a random \(n\times n(n=2,3,\ldots,m)\) matrix.

  5. 5.

    Variation diminishing property: As GBT-Bernstein basis functions fabricate a class of formalized completely positive basis functions, the GBT-Bézier curves in (13) carry the variation reducing property, which means that a GBT-Bézier curve will have no more intersections with any plane more often than it intersects the correlated control polygon.

  6. 6.

    Shape control property: For a described control polygon, the shape of the traditional Bézier curve can be totally defined by its control points, while the shape of the GBT-Bézier curve can be modified by changing its shape parameters μ, ν although its control polygon remains fixed.

From the above expressions, we can conclude that, GBT-Bézier curves interpolate to the terminal points of the control polygon, that is, to the first and the last edge. The above-mentioned expressions also show that the value of the first and second derivative at both terminal points on GBT-Bézier curves can be modified by adjusting shape parameters μ, ν, which play a significant role in unwrinkled joining.

Figure 2 depicts the influence role of shape parameters μ, ν on quartic and quintic GBT-Bézier curves, that is, if we increase the value of a shape parameter, either μ or ν or both, the GBT-Bézier curve gradually approximates to the control polygon, whereas the points marked on the quartic GBT-Bézier curves correlate to \(F(0.2)\) in red, \(F(0.4)\) in blue, \(F(0.6)\) in black, and \(F(0.8)\) in green, and the points correspond to quintic GBT-Bézier curves for \(F(0.2)\) in orange, \(F(0.4)\) in blue, \(F(0.6)\) in red, and \(F(0.8)\) in black. Figure 2 also represents that the points on theses curves change linearly for increasing or decreasing value of z with different values of shape parameters.

Figure 2
figure 2

Quartic and quintic GBT-Bézier curves with different values of shape parameters

Figure 3 displays that the outlook of GBT-Bézier curves can be handled by changing the values of shape parameters μ, ν and also exhibits the graphs of 2nd, 3rd, 4th, 5th, and 10th degree GBT-Bézier curves. Figure 3(a) shows the graphs of 4th degree GBT-Bézier curves with \(\mu , \nu =1\) (purple), 0.5 (blue), 0 (red), −0.5 (black). The first flower presented in Fig. 3(b) is designed by 5th degree GBT-Bézier curves when \(\mu , \nu =1\) (purple), 0.3 (red), −0.3 (green), −1 (orange). Figure 3(c) shows the second flower created by 10th degree GBT-Bézier curves with shape parameters \(\mu , \nu =1\) (purple), 0.3 (red), −0.3 (green). Figure 3(d) represents a butterfly for multiple values of shape parameters \(\mu , \nu =1\) (blue), 0.25 (red), −0.5 (green), which is generated by 2nd and 3rd degree GBT-Bézier curves.

Figure 3
figure 3

Geometric modeling of GBT-Bézier curves of multiple degrees with different values of shape parameters

3 Continuity of GBT-Bézier curves

Practically, the outlook of many products is relatively complicated and cannot be presented by using a single curve. Therefore, contiguous curves are used to design such products. The technique of smooth continuity among curves is used to design complex curves and also a meaningful study in computer-aided design/computer-aided manufacturing (CAD/CAM). Two categories for estimating the continuity of piecewise curves are:

  • Parametric continuity (\(C^{m}\)),

  • Geometric continuity (\(G^{m}\)).

The requirements for parametric and geometric continuity among two GBT-Bézier curves are given as follows:

Lemma 3.1

([9])

The necessary and sufficient parametric continuity conditions among two GBT-Bézier curves \(F(z)= \Sigma ^{m}_{k=0} Q_{k}f_{k,m}(z)\) and \(F_{1}(z)= \Sigma ^{n}_{k=0} Q1_{k}f_{k,n}(z)\) with control points \(Q_{0}\), \(Q_{1}\), \(Q_{2}\),..., \(Q_{m}\), \(m\geq 3\) and \(Q1_{0}, Q1_{1}, Q1_{2},\ldots, Q1_{n}\), \(n\geq 3\), respectively, are defined as follows:

  1. 1.

    \(Q_{m}=Q1_{0}\) for \(C^{0}\) continuity;

  2. 2.

    \(Q_{m}=Q1_{0}\), \(F'(1)=F_{1}'(0)\) for \(C^{1}\) continuity;

  3. 3.

    \(Q_{m}=Q1_{0}\), \(F'(1)=F_{1}'(0)\), \(F''(1)=F_{1}''(0)\) for \(C^{2}\) continuity;

  4. 4.

    \(Q_{m}=Q1_{0}\), \(F'(1)=F_{1}'(0)\), \(F''(1)=F_{1}''(0)\), \(F'''(1)=F_{1}'''(0)\) for \(C^{3}\) continuity.

Lemma 3.2

([9])

The necessary and sufficient constraints for geometric continuity among two GBT-Bézier curves \(F(z)= \Sigma ^{m}_{k=0} Q_{k}f_{k,m}(z)\) and \(F_{1}(z)= \Sigma ^{n}_{k=0} Q1_{k}f_{k,n}(z)\) are as follows:

  1. 1.

    For \(G^{0}\) continuity: \(Q_{m}=Q1_{0}\);

  2. 2.

    For \(G^{1}\) continuity: \(Q_{m}=Q1_{0}\), \(F'(1)=\gamma F_{1}'(0)\), \(\gamma >0\);

  3. 3.

    For \(G^{2}\) continuity: \(Q_{m}=Q1_{0}\), \(F'(1)=\gamma F_{1}'(0)\), \(\gamma >0\), and the curvature

    $$ \kappa (1)=\frac{ \vert F'(1)\times F''(1) \vert }{ \vert F'(1) \vert ^{3}}= \frac{ \vert F_{1}'(0)\times F_{1}''(0) \vert }{ \vert F_{1}'(0) \vert ^{3}}=\kappa _{1}(0), $$

where \(Q_{0}, Q_{1}, Q_{2},\ldots.., Q_{m}\) and \(Q1_{0}, Q1_{1}, Q1_{2},\ldots.., Q1_{n}\) (\(m\geq 3\), \(n\geq 3\)) are the control points of GBT-Bézier curves.

The continuity conditions of GBT-Bézier curves in the context of terminal properties of GBT-Bézier curves are given in the following theorem.

Theorem 2

The necessary and sufficient constraints for \(C^{3}\) continuity between two GBT-Bézier curve segments \(F(z)= \Sigma ^{m}_{k=0} Q_{k}f_{k,m}(z)\) and \(F_{1}(z)= \Sigma ^{n}_{k=0} Q1_{k}f_{k,n}(z)\) with control points \(Q_{0}, Q_{1}, Q_{2},\ldots,Q_{m}, m\geq 3\) and Q10, Q11, Q12,…,\(Q1_{n}\), \(n\geq 3\), respectively, are expressed as follows:

  1. 1.

    \(Q_{m} =Q1_{0}\) for \(C^{0}\) continuity;

  2. 2.

    For \(C^{1}\) continuity,

    $$ \textstyle\begin{cases} {Q1_{0}=Q_{m}}, \\ {Q1_{1}= Q_{m}+ \frac{(2(m-2)+\pi (1+\nu ))}{2(n-2)+\pi (1+\mu 1)}(Q_{m}-Q_{m-1})}; \end{cases} $$
    (14)
  3. 3.

    For \(C^{2}\) continuity,

    $$ \textstyle\begin{cases} {Q1_{0}=Q_{m}}, \\ {Q1_{1}= Q_{m}+ \frac{(2(m-2)+\pi (1+\nu ))}{2(n-2)+\pi (1+\mu 1)}(Q_{m}-Q_{m-1})}, \\ Q1_{2}=Q_{m}+\frac{1}{a_{1}}[a_{2}(Q_{m}-2Q_{m-1}+Q_{m-2})\\ \hphantom{Q1_{2}=}{} - \pi ^{2}(1-\mu )(Q_{m-1}-Q_{m-2})+a_{3}(Q_{m}-Q_{m-1})]; \end{cases} $$
    (15)
  4. 4.

    For \(C^{3}\) continuity,

    $$ \textstyle\begin{cases} {Q1_{0}=Q_{m}}, \\ {Q1_{1}= Q_{m}+a(Q_{m}-Q_{m-1})}, \\ Q1_{2}=Q_{m}+\frac{1}{a_{1}}[a_{2}(Q_{m}-2Q_{m-1}+Q_{m-2})\\ \hphantom{Q1_{2}=}{}- \pi ^{2}(1-\mu )(Q_{m-1}-Q_{m-2})+a_{3}(Q_{m}-Q_{m-1})], \\ Q1_{3}=Q_{m}+\frac{1}{b_{1}}[b_{2}(Q_{m}-3Q_{m-1}+3Q_{m-2}-Q_{m-3})\\ \hphantom{Q1_{3}=} {}+ \frac{a_{2}}{a_{1}}b_{3}(Q_{m}-2Q_{m-1}+Q_{m-2}) \\ \hphantom{Q1_{3}=} {}-\frac{\pi ^{2}(1-\mu 1)b_{3}}{a_{1}}(Q_{m-1}-Q_{m-2})-b_{4}(Q_{m}-Q_{m-1})], \end{cases} $$
    (16)

    where

    $$\begin{aligned}& a=\frac{2(m-2)+\pi (1+\nu )}{2(n-2)+\pi (1+\mu 1)}, \\& a_{1}=4(n-2) \bigl(n-3+\pi (1+\mu 1)\bigr)+\pi ^{2}(1- \nu 1), \\& a_{2}=4(m-2) \bigl(m-3+\pi (1+\nu )\bigr), \\& a_{3}=\bigl(2 a_{1}+\pi ^{2}(1+2\mu 1-\nu 1)+2\pi ^{2}\nu \bigr), \\& b_{1}=4(n-2) (n-3) \bigl(2(n-4)+3\pi (1+\mu 1)\bigr)+6(n-2)\pi ^{2}(1-\nu 1), \\& b_{2}=4(m-2) (m-3) \bigl(2(m-4)+3\pi (1+\nu )\bigr), \\& b_{3}= \bigl(3c_{1}+12(n-2)\pi ^{2}(1-\mu 1- \nu 1)\bigr), \\& b_{4}=\frac{a_{3}b_{3}}{a_{1}}-a\bigl(c_{1}+12(n-2)\pi ^{2}(1-\mu 1-4\nu 1)+\pi ^{3}(1+\mu 1)\bigr)+\pi ^{3}(1+\nu ), \\& c_{1}=4(n-2) (n-3) \bigl(2(n-4)+3\pi (1+\mu 1)\bigr). \end{aligned}$$

Proof

  1. 1.

    \(C^{0}\) continuity is simply achieved from \(F(1)=F_{1}(0)\).

  2. 2.

    From the \(C^{0}\) continuity condition, \(Q_{m}=Q1_{0}\) and \(F'(1)=F_{1}'(0)\). It is simple and straightforward to achieve the \(C^{1}\) continuity conditions (14) by using the end point conditions \(F'(1)=(2(m-2)+\pi (1+\nu ))(Q_{m}-Q_{m-1})\) and \(F'_{1}(0)=(2(n-2)+\pi (1+\mu _{1}))(Q1_{1}-Q1_{0})\).

  3. 3.

    \(C^{2}\) continuity conditions are \(C^{1}\) continuity conditions with addition to \(F''(1)=F_{1}''(0)\). Thus, the \(C^{2}\) continuity conditions (15) can be achieved simply by using above-mentioned terminal properties (3)–(6).

  4. 4.

    \(C^{3}\) continuity conditions are \(C^{2}\) continuity conditions additionally with \(F'''(1)=F_{1}'''(0)\). Thus, by using terminal properties (7)–(8), we can acquire \(C^{3}\) continuity requirements (16) comfortably.

 □

Theorem 3

For two GBT-Bézier curves \(F(z)= \Sigma ^{m}_{k=0} Q_{k}f_{k,m}(z)\) and \(F_{1}(z)= \Sigma ^{n}_{k=0} Q1_{k}f_{k,n}(z)\) segments having control points \(Q_{0}\), \(Q_{1}\), \(Q_{2}\),…,\(Q_{m}\), \(m\geq 3\) and Q10, Q11, Q12,…,\(Q1_{n}\), \(n\geq 3\), respectively, the essential and adequate requirements for \(G^{2}\) continuity are described as follows:

  1. 1.

    \(Q1_{0}=Q_{m}\) for \(G^{0}\) continuity;

  2. 2.

    For \(G^{1}\) continuity,

    $$ \textstyle\begin{cases} {Q1_{0}=Q_{m}} \\ {Q1_{1}=Q_{m}+ \frac{(2(m-2)+\pi (1+\nu ))(Q_{m}-Q_{m-1})}{(2(n-2)+\pi (1+\mu 1))\gamma }}; \end{cases} $$
    (17)
  3. 3.

    For \(G^{2}\) continuity,

    $$ \textstyle\begin{cases} {Q1_{0}=Q_{m}} \\ {Q1_{1}=Q_{m}+ \frac{(2(m-2)+\pi (1+\nu ))(Q_{m}-Q_{m-1})}{(2(n-2)+\pi (1+\mu 1))\gamma }} \\ Q1_{2}=Q_{m}+\frac{1}{\gamma ^{2}c_{n}}[2(m-2)(m-3+\pi (1+ \nu ))(Q_{m-2}-2Q_{m-1}+Q_{m})\\ \hphantom{Q1_{2}=}{}+\frac{\pi ^{2}}{2}(1-\mu )(Q_{m-2}-Q_{m-1}), \end{cases} $$
    (18)

    where

    $$\begin{aligned}& c_{n}=2(n-2) \bigl(n-3+\pi (1+\mu 1)\bigr)+\frac{\pi ^{2}}{2}(1- \nu 1), \\& d_{n}=4(n-2) \bigl(n-3+\pi (1+\mu 1)\bigr)+\frac{\pi ^{2}}{2}(1+2 \mu 1-\nu 1). \end{aligned}$$

Proof

  1. 1.

    Using straightforward computations, \(G^{0}\) continuity is simple.

  2. 2.

    From \(G^{1}\) continuity requirements \(Q_{m}=Q1_{0}\) and \(F'(1)=\gamma F_{1}'(0)\), \(\gamma >0\). Since \(F'(1)=(2(m-2)+\pi (1+\nu ))(Q_{m}-Q_{m-1})\) and \(F'_{1}(0)=(2(n-2)+\pi (1+\mu _{1}))(Q1_{1}-Q1_{0})\). Thus, the required \(G^{1}\) continuity conditions (17) can be obtained easily using these terminal conditions.

  3. 3.

    \(G^{2}\) continuity requirements are \(G^{1}\) continuity requirements with \(\kappa (1)=\kappa _{1}(0)\). We know that \(F(1)=Q_{m}=Q1_{0}=F_{1}(0)\), \(F'(1)=\gamma F_{1}'(0)\), \(\gamma >0 \), and the reverse normal vector \(D= F'(1)\times F''(1)\) of \(F(z)\) and the vice normal vector \(D_{1}= F'_{1}(0)\times F''_{1}(0)\) of \(F_{1}(z)\) in \(z=1\) have the same direction, so the four vectors \(F'(1)\), \(F'(0)\), \(F''(1)\), \(F''(0)\) are coplanar such that \(F''(1)=\delta F_{1}''(0)+\lambda F'_{1}(0)\), here \(\delta >0\), λ is set arbitrarily. As

    $$ \kappa _{1}(0)=\frac{ \vert F'_{1}(0)\times F''_{1}(0) \vert }{ \vert F'_{1}(0) \vert ^{3}}= \frac{\delta \lambda \vert F_{1}'(0)\times F_{1}''(0) \vert }{\gamma ^{3} \vert F_{1}'(0) \vert ^{3}}= \frac{ \vert F'(1)\times F''(1) \vert }{ \vert F'(1) \vert ^{3}}=\kappa (1)), $$

thus \(\delta =\gamma ^{2}\), \(F''(1)=\gamma ^{2}F_{1}''(0)+\lambda F'_{1}(0)\). From \(Q_{m}=Q1_{0}\) and \(F'(1)=\gamma F_{1}'(0)\), \(\gamma >0\) and \(F'(1)=(2(m-2)+\pi (1+\nu ))(Q_{m}-Q_{m-1})\), \(\gamma >0\), and putting \(F''(0)\), \(F''(1)\) into \(F''(1)=\gamma ^{2}F_{1}''(0)+\lambda F'_{1}(0)\), the \(G^{2}\) continuity conditions are obtained. □

4 Examples and discussions

Example 1

\(C^{1}\) continuity between cubic and quartic GBT-Bézier curves and control over the shape of composite GBT-Bézier curves with control points \(Q_{0}=(0.2, 0.4)\), \(Q_{1}=(0.15, 0.8)\), \(Q_{2}=(0.25, 0.9)\), \(Q_{3}=(0.4, 0.9)\), \(Q_{4}=(0.5, 0.6)=Q1_{0}\), \(Q1_{2}=(0.9, 0.3)\), \(Q1_{3}=(0.9, 0.7)\) are shown in Fig. 4. The curve exhibits \(C^{1}\) continuity for different values of shape parameters. Using \(C^{1}\) continuity conditions (14) of GBT-Bézier curves, the point Q11 can be calculated easily for each curve by using Theorem 2.

Figure 4
figure 4

\(C^{1}\) continuity among two GBT-Bézier curves with different shape parameters

Example 2

Figure 5 depicts the shape control of combined GBT-Bézier curves which satisfy the \(C^{3}\) continuity conditions at shared boundary. The control points of the both curves are \(Q_{0}=(2, 3)\), \(Q_{1}=(1, 3)\), \(Q_{2}=(0, 2)\), \(Q_{3}=(0.5, 1)\), \(Q_{4}=(1.5, 0.5)=Q1_{0}\). \(C^{3}\) continuity for GBT-Bézier curves is achieved by modifying the values of shape parameters. The points Q11, Q12, Q13 for each curve can be calculated by using \(C^{3}\) continuity conditions for GBT-Bézier curves given in Theorem 2.

Figure 5
figure 5

GBT-Bézier curves together with \(C^{3}\) continuity and different shape parameters

Example 3

Figure 6 represents the control over the shape of composite GBT-Bézier curves which meet by the \(G^{2}\) continuity constraints at a joint point. The control points of two curves are \(Q_{0}=(0.2,0.2)\), \(Q_{1}=(0.1, 0.5)\), \(Q_{2}=(0.4, 0.8)\), \(Q_{3}=(0.7, 0.5)\), \(Q_{4}=(0.67, 0.3)=Q1_{0}\), \(Q1_{3}=(0.5, -0.5)\). By varying the values of shape parameters, the curves that achieved \(G^{2}\) continuity, and the control points Q11, Q12 can be calculated by using continuity conditions (18) given in Theorem 3 for each curve. The values of shape parameters \(\mu , \nu =1,0.8,0.6,0.4,0.2\) are used to achieve the smooth curve.

Figure 6
figure 6

Shape adjustment of connected GBT-Bézier curves with \(G^{2}\) continuity conditions

5 Conclusions

In this study, we proposed the GBT-Bézier curves of degree m associated with two shape parameters and studied their characteristics. These proposed GBT-Bézier curves have almost all characteristics of the classical Bézier curves but the shape-adjustable quality is an additional quality if compared to the classical Bézier curves. Moreover, \(G^{2}\) and \(C^{3}\) continuity requirements for the construction of composite curves are derived. These special continuity preserving curves have parameters that can control the shape and can be used easily in CAD/CAM.

Modeling examples illustrate that the GBT-Bézier curves design can approach the control net closer than the traditional Bézier curves design, and also these designing examples exhibit that the GBT-Bézier curves proposed in this research are simple to apply. In addition this approach gives the degree of freedom of shape and consequently can be utilized to generate a variety of complicated special curves. Moreover, as the newly constructed curves have only two shape parameters, hence the method of shape amendment becomes convenient, and we can anticipate the result after modifying the shape parameter. We believe our work is meaningful and considerable because our proposal supports simplifying the development and computer realization of complicated curves. In the future, we shall generalize these GBT-Bernstein basis functions in quantum and post quantum calculus frame, and they may attract attention of researchers working in approximation theory and CAGD.