Next Article in Journal
Multi-Sensor Approach Combined with Pedological Investigations to Understand Site-Specific Variability of Soil Properties and Potentially Toxic Elements (PTEs) Content of an Industrial Contaminated Area
Previous Article in Journal
Study on Circular Economy Implementation Propensity of Construction Companies in Context of Prevailing Management Styles
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

A Rational Quadratic Trigonometric Spline (RQTS) as a Superior Surrogate to Rational Cubic Spline (RCS) with the Purpose of Designing

1
Department of Mathematics, University of Engineering and Technology, Lahore P.O. Box 54890, Pakistan
2
Department of Information Science, College of Computing Sciences & Engineering, Kuwait University, P.O. Box 5969, Safat, Kuwait City 13060, Kuwait
3
Department of Mathematics, University of the Punjab, Lahore P.O. Box 54590, Pakistan
4
Department of Sciences and Technology, Ranyah University College, Taif University, P.O. Box 11099, Taif 21944, Saudi Arabia
5
Research Centre, Future University in Egypt, New Cairo 11835, Egypt
*
Author to whom correspondence should be addressed.
Appl. Sci. 2022, 12(8), 3992; https://doi.org/10.3390/app12083992
Submission received: 25 February 2022 / Revised: 31 March 2022 / Accepted: 9 April 2022 / Published: 14 April 2022

Abstract

:
A key technique for modeling 2D objects is built using a Bézier-like rational quadratic trigonometric function with two form parameters. Since they are generated employing weights, the suggested rational quadratic trigonometric spline curve schemes are helpful for shape modeling. The established method yields a curve with the best geometric properties, such as convex hull, partition of unity, affine invariance, and diminishing variation. The parameters in the suggested method’s construction are helpful for several critical shape features such as local, global, and biased tension qualities, which give good control over the curve and allow for shape modification as desired. In addition, the recommended approach is C 2 . Furthermore, the comparative study of both splines is discussed which revealed the proposed method as a superior alternative to rational cubic spline.

1. Introduction

Geometric modeling is the process of developing a mathematical description of an object’s geometry using a CAD system. A geometric model is a mathematical description that is stored in computer memory. These processes include the creation of new geometric models from the system’s basic building pieces. Geometric modeling is a subfield of applied mathematics and computational geometry that investigates methods and algorithms for mathematically describing shapes. In modern era for modeling, designing and analyzing various objects the role of classical Bézier curves cannot be overlooked when discussing the importance of free form curves in CAD/CAM, as the Bézier curve is a fundamental modeling tool in CAD/CAM. Because rational Bézier curves are produced using weights, they are superior to basic Bézier curves for form modeling. Additionally, rational Bézier curves may be used to represent conics, which have a range of technical uses. Regarding the importance of curves in various fields such as shape modeling specially in aerospace and automobiles, fingers print and face recognition, artificial intelligence, and even in media, a scheme is constructed using a Bézier-like rational quadratic trigonometric function with two form parameters. The suggested rational quadratic trigonometric spline curve schemes are useful for shape modeling because they are generated with weights. The established method produces a curve with the best geometric properties. The parameters in the suggested method’s construction are beneficial for several critical shape features, providing good control over the curve and allowing for shape modification as desired. Additionally, simple Bézier curves are addressed. Numerous efforts have been undertaken in this direction [1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23].
Some of the restrictions of Bézier curves are addressed by using trigonometric spline functions. In the literature, Sarfraz [1] devised a weighted Nu spline with a local support base for form modeling. Sarfraz [2] developed a spline with strong shape-design properties in 2008, and it uses the Ball cubic spline as an example. Hussain et al. [3] creates a rational quartic interpolation spline to display the data. Sarfraz [4] suggested a unique spline system, which includes Ball cubic spline, as a replacement to NURBS in 2010. X. Han [5] used a piecewise rational spline with a biquadratic numerator and a parabolic denominator to retain the item’s shape. Lamnii and Oumellal [6] suggested a tension spline-based approach for local interpolation. Sarfraz et al. [7] build 2D objects by using a quadratic trigonometric spline with weighted continuity. Sarfraz et al. [8] used an imperative technique with shape parameters to generate a quadratic trigonometric Nu-spline. In 2017, Sarfraz et al. [9] introduced a curve technique where commonly used basic Bezier curves are also included in rational Bezier curves since they have parameters that modify the format of material without distorting control points. Sarfraz et al. [10] created a rational quadratic trigonometric spline for modeling using the interval shape feature. Sarfraz et al. [11] developed CTS with two families of parameters and investigate the order 3 error analysis of cubic trigonometric spline CTS. Sarfraz et al. [12] proposed a fast weighted spline construction method. Samreen et al. [13] proposed a quadratic B-spline with control over point form. Furthermore, Samreen et al. [14] developed an effective spline technique for quadratic trigonometric functions by incorporating weighted Nu continuity. Later, Samreen et al. [15] compared the cubic polynomial spline to a quadratic trigonometric interpolant approach for shape modeling. Ngowi et al. [16] created H 2 S   donors, which were used to treat common renal diseases. Usman et al. [17] designed a new curve scheme for the designing of complex curves. In [18] Bibi et al. described the curvature using parametric and geometric continuity constraints of generalized hybrid trigonometric Bézier (GHT-Bézier) curves, constructed various shapes and font designs of curves, and described the curvature using parametric and geometric continuity constraints of generalized hybrid trigonometric Bézier (GHT-Bézier) curves. Khattak et al. [19] investigated the therapeutic potential of H 2 S for respiratory diseases. Musleh et al. [20] devised a method for calculating the effect of ratio picture pixel values on shadow detection. Ngowi et al. [21] developed drugs that were both efficient and effective for the major targets. One of three identified gas transmitters, hydrogen sulfide, affects autophagy, apoptosis, migration, and proliferation, among other cellular processes. Farin et al. [22] in 2002 made available a wide-ranging exposure of the areas computer-aided design, geometric modeling, and scientific visualization, or computer-aided geometric design.
The created approach in this research has the following significant characteristics:
  • The method has good trigonometric splines properties.
  • It possesses the best geometric properties of all splines.
  • The scheme fulfills the criteria for geometric smoothness.
  • The proposed technique incorporates key aspects of form design.
  • Some conics can be represented using the proposed curve approach.
  • It contains two shape parameters that control shape effects such as interval tension and global tension.
  • To establish that the suggested scheme is the better alternative, a quick comparative study of the proposed scheme and a rational cubic spline (RCS) is considered.
In Section 2, a Bézier-like rational quadratic trigonometric function is demonstrated in its interpolatory form, which is shaped using C 2 constraint equations at curve segment joints. The error analysis of a rational quadratic trigonometric spline (RQTS) is calculated in Section 3. Section 4 presents proofs of convex hull and affine invariance features for the RQTS curve, which are derived from Bernstein Bézier form. The form features of the suggested spline are addressed in Section 5. In Section 6, there is a demonstration of the proposed spline technique for various shape effects, including interval tension, biased tension, and global tension. Section 7 comprises a comparison analysis of constructed RQTS with a rational cubic spline (RCS) regarding visual difference, time elapsed and error analysis. Section 8 is where the paper comes to a close.

2. Proposed Spline Method

Consider the data points { ( t i , F i ) ,   i = 0 , 1 , 2 , , n } , where domain t i ,   i = 0 , 1 , 2 , n , represents knots with t 0 < t 1 < < t n and F i ,   i = 0 , 1 , 2 , n , be values at these knots. A rational quadratic trigonometric function R ( t ) , with two shape parameters ρ i ,   σ i > 0 ,   i = 0 , 1 , , n 1 , is defined over the interval I i = [ t i , t i + 1 ] ,   i = 0 , 1 , 2 , , n 1 ,   as:
                R ( t ) = i = 0 3 S i ( t ) P i   ,     t [ t i , t i + 1 )
S i ( t ) ,   i = 0 , 1 , 2 , 3 are rational quadratic trigonometric basis functions defined as:
S 0 ( t ) = A 0 ( t ) S ( t ) ,   S 1 ( t ) = ρ i A 1 ( t ) S ( t ) ,   S 2 ( t ) = σ i A 2 ( t ) S ( t ) ,   S 3 ( t ) = A 3 ( t ) S ( t ) ,
where
  A 0 ( t ) = ( 1 s i n θ ) 2 ,   A 1 ( t ) = s i n θ ( 1 s i n θ ) , A 2 ( t ) = c o s θ ( 1 c o s θ ) ,   A 3 ( t ) = ( 1 c o s θ ) 2
and
S ( t ) = A 0 ( t ) + ρ i A 1 ( t ) + σ i A 2 ( t ) + A 3 ( t ) .
Additionally,
θ ( t ) = π ( t t i ) 2 h i ,   0 θ π 2   and     h i = t i + 1 t i ,   i = 0 , 1 , , n 1 .
Furthermore, i = 0 3 S i ( t ) = 1 as demonstrated in Figure 1. By applying the following C 1 -continuity conditions
R ( t i ) = F i ,   R ( t i + 1 ) = F i + 1 , R ( 1 ) ( t i ) = M i ,   R ( 1 ) ( t i + 1 ) = M i + 1 ,
at the end points of the interval I i = [ t i , t i + 1 ] , Bézier-like rational quadratic trigonometric Function (1) is transformed into a spline:
R ( t ) = R i ( t ; ρ i , σ i ) = A 0 ( t ) P 0 + ρ i A 1 ( t ) P 1 + σ i A 2 ( t ) P 2 + A 3 ( t ) P 3 S ( t )
with
  P 0 = F i ,   P 1 = V i = F i + 2 h i M i ρ i π ,   P 2 = W i = F i + 1 2 h i M i + 1 σ i π ,   P 3 = F i + 1 .
M i ’s are the computed values of 1st derivatives at the knots t i .   ρ i ,   σ i > 0 provides positive denominator. For ρ i = σ i = 2 , (2) turns into quadratic trigonometric interpolant R ( t ) C 1 [ t 1 , t n ] . Now by putting the following C 2 continuity conditions
R i 1 ( 2 ) ( t i ) | θ i = π 2 = R i ( 2 ) ( t i + ) | θ i = 0 ,   i = 1 , 2 , n 1 .
The following tri-diagonal system of linear equations in n 1 unknowns M i ,   i = 1 ,   2 , , n 1 , is achieved as follows:
h i M i 1 + 2 { ( σ i 1 1 ) h i + ( ρ i 1 ) h i 1 } M i + h i 1 M i + 1 = π 2 ( ρ i 1 h i Δ i + σ i h i 1 Δ i ) ,
where
  Δ i = F i + 1 F i h i ,   i = 1 ,   2 , , n 1 .
With suitable end conditions, the above system is diagonally dominant and a unique solution for M i ’s can be computed with the following limits on the shape parameters,
ρ i , σ i = α 2 ,   i = 1 ,   2 , n .
The preceding discussion can be summarized as follows:
Theorem 1.
RQTS has a solution that is unique due to the restriction on the shape parameters (5).

3. Error Analysis of RQTS

The error of RQTS Function (1) is calculated in this segment by the following theorem.
Theorem 2.
For G ( t ) C 3 [ t 0 , t n ] , let R ( t ) be the rational quadratic trigonometric spline (1) interpolates G ( t ) in [ t 0 , t 1 ] , then for ζ i > 0 ,   ξ i > 0 , the following holds:
| G ( t ) R ( t ) | G 3 ( δ ) h i 3 b i ,
where
b i = max 0 σ 1 χ ( ζ i , ξ i , ϑ ) ,
with
χ ( ζ i , ξ i , ϑ ) = { max   χ 1 ( ζ i , ξ i , ϑ ) ,   0 ξ i 1 ,   0 σ 1 max   χ 2 ( ζ i , ξ i , ϑ ) , ξ i > 1 + 2 π ,   0 σ σ * max   χ 3 ( ζ i , ξ i , ϑ ) ,     ξ i > 1 + 2 π ,   σ * σ 1 .   χ 1 = h i 3 S ( t ) { 2 A 2 ϑ 2 π ( 1 ϑ ) ( ξ i A 2 + A 3 ) ϑ 2 π + 4 A 2 ( 1 ϑ ) ϑ π (   ξ i A 2 + A 3 ) ( 1 ϑ ) 2 ϑ π + ( 1 ϑ ) 2 6 A 2 π (   ξ i A 2 + A 3 ) ( 1 ϑ ) 3 3 π + ϑ 3 ( A 0 + A 1 ζ i ) 3 } ,
χ 2 = h i 3 S ( t ) { (   ξ i A 2 + A 3 ) ( 1 ϑ ) 3 3 2 ( A 0 + A 1 ζ i ) 3 ( E F H ) 3 + 4 A 2 2 π ( 1 ϑ ) (   ξ i A 2 + A 3 ) π ( E F H ) 2 8 A 2 ( 1 ϑ ) 2 π (   ξ i A 2 + A 3 ) ( 1 ϑ ) 2 π ( E F H ) ϑ 3 ( A 0 + A 1 ζ i ) 3 ϑ 2 4 A 2 2 ( 1 ϑ ) ( ξ i A 2 + A 3 ) π ϑ ( 1 ϑ ) 4 A 2 ( 1 ϑ ) ( ξ i A 2 + A 3 ) π }   χ 3 = h i 3 S ( t ) { 2 ( A 0 + A 1 ζ i ) 3 ( E F H ) 3 4 A 2 2 π ( 1 ϑ ) (   ξ i A 2 + A 3 ) π ( E F H ) 2 + 8 A 2 ( 1 ϑ ) 2 π (   ξ i A 2 + A 3 ) ( 1 ϑ ) 2 π ( E F H ) 2 ( A 0 + A 1 ζ i ) 3 ( E + F H ) 3 + 4 A 2 2 π ( 1 ϑ ) (   ξ i A 2 + A 3 ) π ( E + F H ) 2 + 8 A 2 ( 1 ϑ ) 2 π (   ξ i A 2 + A 3 ) ( 1 ϑ ) 2 π ( E + F H ) + ϑ 3 2 ( A 0 + A 1 ζ i ) 3 + ϑ 2 2 A 2 π ( 1 ϑ ) ( ξ i A 2 + A 3 ) π + ϑ ( 1 ϑ ) 4 A 2 π ( 1 ϑ ) ( ξ i A 2 + A 3 ) π + ( 1 ( 1 ϑ ) 2 6 A 2 π ( 1 ϑ ) ( ξ i A 2 + A 3 ) 3 π } ,
where
E = 4 A 2 2 ( 1 ϑ ) ( ξ i A 2 + A 3 ) π F = ( 4 A 2 2 ( 1 ϑ ) ( ξ i A 2 + A 3 ) π ) 2 4 ( 1 ϑ ) ( A 0 + A 1 ζ i ) ( 4 A 2 ( 1 ϑ ) ( ξ i A 2 + A 3 ) ) , H = 2 ( A 0 + A 1 ζ i ) , σ * = 1 2 π ( ξ i 1 ) .
Proof. 
The error is determined without compromising generality since the quadratic trigonometric function is interpolated locally in the subinterval [ t i , t i + 1 ] . Let R   ( t )   be the quadratic trigonometric function of G ( t )   [ t 0   , t n ] ,   interpolated in [ t i , t i + 1 ]   as defined in (1) then by applying the Peano-kernel theorem,
E [ f   ] = G   ( t ) R   ( t ) = 1 2 t i t i + 1 G 3 ( τ ) E t [ ( t τ ) + 2 ] d τ
where E t [ ( t τ ) + 2 ] is the kernel of integral defined for the quadratic trigonometric function as follows:
E t [ ( t τ ) + 2 ] = { a 1 ( τ , t ) ,                       t i < τ < t ,   b 1 ( τ , t ) ,               t < τ < t i + 1 ,
with
a 1 ( τ , t ) = ( t τ ) 2 { (   ξ i A 2 + A 3 ) ( t i + 1 τ ) 2 4 h i π A 2 ( t i + 1 τ ) R ( t ) }
and
b 1 ( τ , t ) = { (   ξ i A 2 + A 3 ) ( t i + 1 τ ) 2 4 h i π A 2 ( t i + 1 τ ) R ( t ) } Two main steps are used in the evidence of the error evaluation; discussing the properties of function a 1 ( τ , t ) and b 1 ( τ , t ) and in the next step, compute the absolute values t i t | a 1 ( τ , t ) | d τ and t t i + 1 | b 1 ( τ , t ) | d τ .
Step 1: a 1 ( τ , t ) and b 1 ( τ , t )   , τ [ t i ,   t ] are the rational quadratic trigonometric functions of τ . Moreover for all ϑ [ 0 , π 2 ] , a 1 ( t i , t ) = 0 and b 1 ( t i + 1 , t ) = 0 .
To compute the roots of a 1 ( τ , t ) and b 1 ( τ , t ) , put τ = t in Equation (6) as
a 1 ( t , t ) = ( t t ) 2 { (   ξ i A 2 + A 3 ) ( t i + 1 t ) 2 4 h i π A 2 ( t i + 1 t ) R ( t ) }
and
b 1 ( t , t ) = { (   ξ i A 2 + A 3 ) ( t i + 1 t ) 2 4 h i π A 2 ( t i + 1 t ) R ( t ) } ,
where
t i + 1 t = t i + 1 t i + t i t = h i ( 1 2 ϑ π   ) = h i ( 1 σ ) , with σ = 2 ϑ π implies that
a 1 ( t , t ) = { (   ξ i A 2 + A 3 ) h i 2 ( 1 σ ) 2 4 h i π A 2 h i ( 1 σ ) R ( t ) } = b 1 ( t , t ) .
Let
( 1 σ ) 4 A 2 π (   ξ i A 2 + A 3 ) = 0 ,
be an equation defined in ϑ , its root in ( 0 , π 2   ) is
σ * = 1 2 π (   ξ i 1 ) ,  
It implies
ϑ * = π 2 1   ξ i 1 .
It can easily be observed that
for σ σ * ,   a 1 ( t , t ) 0 and for σ σ * ,   b 1 ( t , t ) 0 .
Consider
( t i + 1 τ ) = ( t i + 1 t + t τ ) = h i ( 1 σ ) + ( t τ ) .
Now rewrite a 1 ( τ , t ) to observed sign of a 1 ( τ , t ) in [ t i , t ], as
a 1 ( τ , t ) = 1 R ( t ) { ( A 0 + A 1 ζ i ) ( t τ ) 2 + ( t τ ) h i ( 4 π A 2 2 (   ξ i A 2 + A 3 ) ( 1 ϑ ) ) + h i 2 ( 1 ϑ ) ( 4 π A 2 (   ξ i A 2 + A 3 ) ( 1 ϑ ) ) }
a 1 ( τ , t ) = ( t τ ) 2 ( 1 A 2 A 3 ) + ( t τ ) 2 h i {   A 2 π ( 1 σ ) ( A 2 + A 3 ) } + ( 1 σ ) h i 2 { 2 A 2 π ( 1 σ ) ( A 2 + A 3 ) } .
Then the two roots of a 1 ( τ , t )   are
τ 1 = t + h i ( E F ) H   and   τ 2 = t + h i ( E + F ) H ,
where
E = 4 A 2 2 ( 1 ϑ ) ( ξ i A 2 + A 3 ) π F = ( 4 A 2 2 ( 1 ϑ ) ( ξ i A 2 + A 3 ) π ) 2 4 ( 1 ϑ ) ( A 0 + A 1 ζ i ) ( 4 A 2 ( 1 ϑ ) ( ξ i A 2 + A 3 ) ) , H = 2 ( A 0 + A 1 ζ i ) , ϑ * = π 2 1 ( ξ i 1 ) ,
in terms of real value. Similarly, it can be noted that for σ σ * ,   b 1 ( t , t ) 0 and for σ σ * ,   b 1 ( t , t ) 0 .
The two roots of b 1 ( τ , t ) are
τ 1 * = t i + 1   and   τ 2 * = t i + 1 4 h i A 2 π (   ξ i A 2 + A 3 ) ,
( t i + 1 τ ) = ( t i + 1 t + t τ ) = h i ( 1 σ ) + ( t τ ) .
So, the following result holds for σ [ 0 , π 2 ]   σ * [ 0 , π 2 ] , ξ i > 1 ,
| G   ( t ) R   ( t ) | G ( 3 ) 2 t i t i + 1 | E t [ ( t τ ) + 2 ] | d τ = G ( 3 ) h i 3 χ 1 ( ζ i , ξ i , ϑ ) ,
where χ 1 ( ζ i , ξ i , ϑ ) is defined by
χ 1 ( ζ i , ξ i , ϑ ) = t i t | a 1 ( τ , t ) | d τ + t t i + 1 | b 1 ( τ , t ) | d τ = t i t a 1 ( τ , t ) d τ + t t i + 1 b 1 ( τ , t ) d τ = h i 3 S ( t ) { 2 A 2 ϑ 2 π ( 1 ϑ ) ( ξ i A 2 + A 3 ) ϑ 2 π + 4 A 2 ( 1 ϑ ) ϑ π (   ξ i A 2 + A 3 ) ( 1 ϑ ) 2 ϑ π + ( 1 ϑ ) 2 6 A 2 π (   ξ i A 2 + A 3 ) ( 1 ϑ ) 3 3 π + ϑ 3 ( A 0 + A 1 ζ i ) 3 } ,
for σ σ * , σ * [ 0 , 1 ]   , ξ i > 1 + 2 π ,
| G   ( t ) R   ( t ) | G ( 3 ) 2 t i t i + 1 | E t [ ( t τ ) + 2 ] | d τ = G ( 3 ) h i 3 χ 2 ( ζ i , ξ i , ϑ ) ,
where χ 2 ( ζ i , ξ i , ϑ ) is defined by
χ 2 ( ζ i , ξ i , ϑ ) = t i t | a 1 ( τ , t ) | d τ + t t i + 1 | b 1 ( τ , t ) | d τ = t i τ 1 ( a 1 ( τ , t ) ) d τ τ 1 t a 1 ( τ , t ) d τ + t τ 2 * ( b 1 ( τ , t ) ) d τ + τ 2 * t i + 1   b 1 ( τ , t ) d τ
= h i 3 S ( t ) { (   ξ i A 2 + A 3 ) ( 1 ϑ ) 3 3 2 ( A 0 + A 1 ζ i ) 3 ( E F H ) 3 + 4 A 2 2 π ( 1 ϑ ) (   ξ i A 2 + A 3 ) π ( E F H ) 2 8 A 2 ( 1 ϑ ) 2 π (   ξ i A 2 + A 3 ) ( 1 ϑ ) 2 π ( E F H ) ϑ 3 ( A 0 + A 1 ζ i ) 3 ϑ 2 4 A 2 2 ( 1 ϑ ) ( ξ i A 2 + A 3 ) π ϑ ( 1 ϑ ) 4 A 2 ( 1 ϑ ) ( ξ i A 2 + A 3 ) π } ,
but while σ σ * ,   σ * [ 0 , 1 ] , ξ i > 1 + 2 π ,
| G   ( t ) R   ( t ) | G ( 3 ) 2 t i t i + 1 | E t [ ( t τ ) + 2 ] | d τ = G ( 3 ) h i 3 χ 3 ( ζ i , ξ i , ϑ ) ,
where χ 3 ( ζ i , ξ i , ϑ ) is defined by
χ 3 ( ζ i , ξ i , ϑ ) = t i t | a 1 ( τ , t ) | d τ + t t i + 1 | b 1 ( τ , t ) | d τ = t i τ 1 a 1 ( τ , t ) d τ + τ 1 τ 2 ( a 1 ( τ , t ) ) d τ + τ 2 t b 1 ( τ , t ) d τ + t t i + 1 b 1 ( τ , t ) d τ
h i 3 S ( t ) { 2 ( A 0 + A 1 ζ i ) 3 ( E F H ) 3 4 A 2 2 π ( 1 ϑ ) (   ξ i A 2 + A 3 ) π ( E F H ) 2 + 8 A 2 ( 1 ϑ ) 2 π (   ξ i A 2 + A 3 ) ( 1 ϑ ) 2 π ( E F H ) 2 ( A 0 + A 1 ζ i ) 3 ( E + F H ) 3 + 4 A 2 2 π ( 1 ϑ ) (   ξ i A 2 + A 3 ) π ( E + F H ) 2 + 8 A 2 ( 1 ϑ ) 2 π (   ξ i A 2 + A 3 ) ( 1 ϑ ) 2 π ( E + F H ) + ϑ 3 2 ( A 0 + A 1 ζ i ) 3 + ϑ 2 2 A 2 π ( 1 ϑ ) ( ξ i A 2 + A 3 ) π + ϑ ( 1 ϑ ) 4 A 2 π ( 1 ϑ ) ( ξ i A 2 + A 3 ) π + ( 1 ( 1 ϑ ) 2 6 A 2 π ( 1 ϑ ) ( ξ i A 2 + A 3 ) 3 π } .
Thus prove the above result. □

4. Geometric Properties

The perfect geometric properties of the RQTS curve are defined by the subsequent propositions:
Proposition 1
(Affine Invariance (AI) Property).The RQTS curve R ( t ) = i = 0 3 P i S i ( t ) for t [ t i , t i + 1 ] is affine invariant.
Proof .
Consider an affine transformation T, given by
( u 1 , v 1 ) = ( m x + n y + o , q x + r y + s ) ,
let the RQTS curve R ( t ) = i = 0 3 P i S i ( t ) for t [ t i , t i + 1 ] , and let P i ( p i , q i ) ,   i = 0 , , 3 , be the control points then
R ( t ) = ( u ( t ) , v ( t ) ) = ( i = 0 3 p i S i ( t ) ,   i = 0 3 q i S i ( t ) ) .
Now,
T ( R ( t ) ) = ( m i = 0 3 p i S i ( t ) + n   i = 0 3 q i S i ( t ) + o   ,   q i = 0 3 p i B i ( t ) , + r i = 0 3 q i S i ( t ) + s ) .
Since, i = 0 3 S i ( t ) = 1   f o r   t [ t i , t i + 1 ] . Thus
T ( R ( t ) ) = ( m i = 0 3 p i S i ( t ) + n   i = 0 3 q i S i ( t ) + o i = 0 3 S i ( t ) ,   q i = 0 3 p i S i ( t ) , + r i = 0 3 q i S i ( t ) + s i = 0 3 S i ( t ) ) = i = 0 3 ( m p i + n q i + o ) S i ( t ) , i = 0 3 ( q p j + r q j + s ) S i ( t ) = i = 0 3 ( m p i + n q i + o , q p i + r q i + s ) S i ( t ) = i = 0 3 T ( P i ) S i ( t ) .
The illustration of the Proposition 1, for affine invariance property, is shown in Figure 2.
Proposition 2
 (Convex hull (CH) Property). The RQTS curve completely lies within the CH determined by its control points.
Proof. 
Re-write Equation (1) as:
P i ( t ) = S 0 ( t ) F i + S 1 ( t ) V i + S 2 ( t ) W i + S 3 ( t ) F i + 1 ,
where S i ( θ   )   0 ,   i = 0 , , 3 ,   are Bernstein Bézier weight functions with i = 0 3 S i ( θ ) = 1 . Hence the RQTS curve satisfies CH property as displayed in Figure 3. □
Proposition 3 
(Variation Diminishing (VD) Property).The intersection of RQTS curve R ( t ) = i = 0 3 P i S i ( t ) for t [ t i , t i + 1 ] with any N 1 dimensional hyper plane will be equal to or less than the point at which that plane intersects with the control polygon P as determined by control points P i = { F i ,   V i ,   W i , F i + 1 } n .
The VD property for an open and a close curve is displayed in Figure 4a and Figure 4b respectively.
Remark 1.
The VD property disturbs, for ρ i < 2 or   σ i < 2 ,   i as shown in the Figure 5a,b.
Remark 2.
The VD property also upsets for ρ k < 2 or   σ k < 2 , for any k , as revealed in Figure 6a,b.

5. Shape Properties

The proposed spline method is advantageous for different purposes where the changes needed locally or globally. By changing ρ i and σ i , the desire changes can be made in the specific region or in the whole shape of the object.

5.1. Interval Tension Property

Consider an interval [ t k , t k + 1 ] for a fixed k = 1 , , n , if ρ k , σ k , then the curve converges to control polygon in [ t k , t k + 1 ] .

5.2. Global Tension Property

Consider the interval [ t i , t i + 1 ] ,   i , if ρ i , σ i   , i , then the curve converges to control polygon in [ t i , t i + 1 ] ,   i .

5.3. Biased Interval Tension Property

If ρ k or σ k , for any k , then curve inclines towards a control vertex in [ t k , t k + 1 ] .

5.4. Biased Global Tension Property

If ρ i or σ i ,   i , then curve inclines towards control vertices for all intervals [ t i , t i + 1 ] .

6. Demonstration

The RQTS curve method is used to interpolate data points F i 2   ,   i = 1 , , n , of various existing objects. The local and global tension for RQTS is designated with the examples. This illustration shows the shape parameter’s default value ρ i = σ i = 2 , ought to be selected, except it is specified.
In Figure 7a–e, different objects are interpolated using developed RQTS with periodic end conditions. Figure 8a, Figure 9a, Figure 10a, Figure 11a, Figure 12a, and Figure 13a are the default RQTS with periodic end conditions and Figure 8b–d demonstrate the global tension property with the increasing values of shape parameters ρ i = σ i = 3 ,   5   and 100 .
Figure 9b–d demonstrate that rising values of shape constraints ρ k = σ k = 3 ,   5 and 100 , for the base interval to stretch the curve in the base interval and consequently reveal interval tension. Figure 10b–d illustrate the biased tension with the increasing value of ρ i = 3 ,   5 and 10 . Similarly biased global tension is shown in Figure 11b–d with the increasing values of σ i = 3 ,   5 and 10 . Whereas biased interval tension is also demonstrated in Figure 12b–d and Figure 13b–d with the increasing values of ρ k = 3 ,   5 and 10 , and σ k = 3 ,   5 and 10 , respectively, for any interval k .
In Figure 14(a1,b1) default shape of objects is shown using RQTS whereas Figure 14(a2,b2) demonstrates the RQTS with local tension, using ρ i = σ i = 100 at the mandatory portion of the shapes.
Remark 3.
It is worthy of note that the suggested RQTS allows for both local and global modifications in the geometry of the objects.

7. Comparative Study of a RCS and RQTS

A concise comparative study of proposed RQTS and a rational cubic spline (RCS) is discussed here. For this purpose, visual differences and time pass by two splines are kept in mind.

7.1. Visual Difference of Two Splines

The RQTS behaves similar to a RCS. To notice the visual differences of two splines, some objects are interpolated by both splines; RCS and RQTS.
In Figure 15(a1,b1,c1,d1,e1), different objects are interpolated by RCS, whereas in Figure 15(a2,b2,c2,d2,e2), the same data of objects are interpolated using RQTS. Now it can be observed that the RQTS is presenting better results than the RCS.

7.2. Time Elapsed by Two Splines

The comparative study is also justifiable by comparing the time required to complete the tasks by both splines; RCS and RQTS.
Table 1 shows time passed by two spline; RCS and RQTS, for different objects has been considered. Moreover, it is easy to see that RCS takes longer to execute than RQTS, presenting RQTS as a preferable option for RCS.

7.3. Error Analysis for RCS and RQTS

For comparing these splines, the error calculated by RCS and RQTS is defensible. Table 2 shows it for seven different trigonometric, logarithmic, exponential, and polynomial functions: s i n ( t ) , c o s ( t ) ,   t a n ( t ) ,   s e c ( t ) ,   l o g ( t ) ,   e t , and t + 6 + ( t + 2 ) 2 revealed in column 3. Column 2 specifies the domain of the functions. Columns 4 and 5 illustrate the errors of these functions using RCS and RQTS, respectively. The difference in errors determined by RCS and RQTS is shown in Column 6 of Table 2. The difference between the errors of both splines is determined in column 6 to determine the accuracy of the splines.

8. Conclusions

In light of the importance of curve modeling in various fields, a C 2 interpolation system is built utilizing a rational quadratic trigonometric function for the purpose of object form design. Convex hull, partition of unity, affine invariance, and variation decreasing are geometric properties of the curves achieved through the developed method. The suggested method is accommodating for numerous shape effects to change the object as desired locally or globally. The parameters in the recommended method are beneficial for several critical shape features, providing good control over the curve and allowing for shape modification as desired. Furthermore, the comparative study revealed that the proposed method is a superior alternative to RCS.

Author Contributions

Conceptualization, M.S.; methodology, M.S. and S.S.; software, S.S. and N.J.; validation, M.S., S.S. and N.J.; formal analysis, M.S.; investigation, M.S.; resources, M.S.; data curation, S.S.; writing—original draft preparation, S.S. and N.J.; writing—review and editing, M.S. and S.S.; visualization, S.S. and N.J.; supervision, M.S.; project administration, M.S.; funding acquisition, S.A. and A.M. All authors have read and agreed to the published version of the manuscript.

Funding

Taif University Researchers Supporting Project number (TURSP-2020/305), Taif University, Taif, Saudi Arabia.

Acknowledgments

Taif University Researchers Supporting Project number (TURSP-2020/305), Taif University, Taif, Saudi Arabia.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Sarfraz, M. Weighted Nu splines with local support basis functions. Comput. Graph. 2004, 28, 539–549. [Google Scholar] [CrossRef]
  2. Sarfraz, M. Interactive Curve Modeling; Springer: Berlin/Heidelberg, Germany, 2008. [Google Scholar]
  3. Hussain, M.Z.; Hussain, M.; Samreen, S. Visualization of shaped data by rational quartic spline interpolation. Int. J. Appl. Math. Stat. 2008, 13, 34–46. [Google Scholar]
  4. Sarfraz, M. Designing objects with a spline. Int. J. Comput. Math. 2010, 87, 797–817. [Google Scholar] [CrossRef]
  5. Han, X. Shape-preserving piecewise rational interpolant with quartic numerator and quadratic denominator. Appl. Math. Comput. 2015, 251, 258–274. [Google Scholar] [CrossRef]
  6. Lamnii, A.; Oumellal, F. A method for local interpolation with tension trigonometric spline curves and surfaces. Appl. Math. Sci. 2015, 9, 30193035. [Google Scholar] [CrossRef] [Green Version]
  7. Sarfraz, M.; Samreen, S.; Hussain, M.Z. Modeling of 2D objects with weighted-Quadratic Trigonometric Spline. In Proceedings of the 2016 13th International Conference on Computer Graphics, Imaging and Visualization (CGiV), Beni Mellal, Morocco, 29 March–1 April 2016; pp. 29–34. [Google Scholar]
  8. Sarfraz, M.; Samreen, S.; Hussain, M.Z. A Quadratic Trigonometric Nu Spline with Shape Control. Int. J. Image Graph. 2017, 17, 1750015. [Google Scholar] [CrossRef]
  9. Samreen, S.; Sarfraz, M.; Jabeen, N.; Hussain, M.Z. Computer aided design using a rational quadratic trigonometric spline with interval shape control. In Proceedings of the 2017 International Conference on Computational Science and Computational Intelligence (CSCI), Las Vegas, NV, USA, 14–16 December 2017; pp. 246–251. [Google Scholar]
  10. Sarfraz, M.; Jabeen, N.; Samreen, S.; Hussain, M.Z. A Rational Quadratic Trigonometric Spline with Interval Shape Control. In Proceedings of the 2017 14th International Conference on Computer Graphics, Imaging and Visualization, Marrakesh, Morocco, 23–25 May 2017; pp. 8–13. [Google Scholar]
  11. Sarfraz, M.; Hussain, F.; Hussain, S.; Hussain, M.Z. GC1 Cubic Trigonometric Spline Function with its Geometric Attributes. In Proceedings of the 2017 21st International Conference Information Visualisation (IV), London, UK, 11–14 July 2017; pp. 405–409. [Google Scholar]
  12. Sarfraz, M.; Samreen, S.; Hussain, M.Z. A quadratic trigonometric weighted spline with local support basis functions. Alex. Eng. J. 2018, 57, 1041–1049. [Google Scholar] [CrossRef]
  13. Samreen, S.; Sarfraz, M.; Hussain, M.Z. Modeling Curves by a Trigonometric B-spline with point Shape control. In Proceedings of the 6th International Conference on Control and Optimization with Indutrial Applications (COIA), Baku, Azerbaijan, 24–26 August 2018; p. 35352. [Google Scholar]
  14. Samreen, S.; Sarfraz, M.; Hussain, M.Z. Designing by a Quadratic Trigonometric Spline with Point and Interval Shape Control. In Proceedings of the International Conference on Scientific Computing (CSC), Las Vegas, NV, USA, 12–15 July 2018; pp. 195–200. [Google Scholar]
  15. Samreen, S.; Sarfraz, M.; Hussain, M.Z. A quadratic trigonometric spline for curve modeling. PLoS ONE 2019, 14, e0208015. [Google Scholar] [CrossRef] [PubMed]
  16. Ngowi, E.E.; Sarfraz, M.; Afzal, A.; Khan, N.H.; Khattak, S.; Zhang, X.; Wu, D.D. Roles of hydrogen sulfide donors in common kidney diseases. Front. Pharmacol. 2020, 11, 1706. [Google Scholar] [CrossRef] [PubMed]
  17. BiBi, S.; Abbas, M.; Miura, K.T.; Misro, M.Y. Geometric modeling of novel generalized hybrid trigonometric Bézier-like curve with shape parameters and its applications. Mathematics 2020, 8, 967. [Google Scholar] [CrossRef]
  18. Usman, M.; Abbas, M.; Miura, K.T. Some engineering applications of new trigonometric cubic Bézier-like curves to free-form complex curve modeling. J. Adv. Mech. Des. Syst. Manuf. 2020, 14, JAMDSM0048. [Google Scholar] [CrossRef] [Green Version]
  19. Khattak, S.; Zhang, Q.Q.; Sarfraz, M.; Muhammad, P.; Ngowi, E.E.; Khan, N.H.; Wu, D.D. The Role of Hydrogen Sulfide in Respiratory Diseases. Biomolecules 2021, 11, 682. [Google Scholar] [CrossRef] [PubMed]
  20. Musleh, S.; Sarfraz, M.; Raafat, H. Shadow detection of the satellite images of earth using ratio image pixels. Earth Sci. Inform. 2021, 14, 377–392. [Google Scholar] [CrossRef]
  21. Ngowi, E.E.; Attia Afzal, M.S.; Khattak, S.; Zaman, S.U.; Khan, N.H.; Li, T.; Wu, D.D. Role of hydrogen sulfide donors in cancer development and progression. Int. J. Biol. Sci. 2021, 17, 73. [Google Scholar] [CrossRef] [PubMed]
  22. Farin, G.; Hoschek, J.; Kim, M.S. (Eds.) Handbook of Computer Aided Geometric Design; Elsevier: Amsterdam, The Netherlands, 2002. [Google Scholar]
  23. MATLAB. MathWorks, USA. 2018. Available online: https://www.mathworks.com/ (accessed on 8 April 2022).
Figure 1. Blending Functions.
Figure 1. Blending Functions.
Applsci 12 03992 g001
Figure 2. AI property with (a) translation, (b) rotation, and (c) scaling.
Figure 2. AI property with (a) translation, (b) rotation, and (c) scaling.
Applsci 12 03992 g002aApplsci 12 03992 g002b
Figure 3. CH property.
Figure 3. CH property.
Applsci 12 03992 g003
Figure 4. VD property for (a) an open curve and (b) a close curve.
Figure 4. VD property for (a) an open curve and (b) a close curve.
Applsci 12 03992 g004
Figure 5. VD property disrupts for (a) ρ i = σ i = 0.6   and (b)   ρ i = σ i = 0.4 for all intervals.
Figure 5. VD property disrupts for (a) ρ i = σ i = 0.6   and (b)   ρ i = σ i = 0.4 for all intervals.
Applsci 12 03992 g005
Figure 6. VD property violates at different intervals for the values of shape parameters (a) ρ k = 1 , in 3rd interval and (b) σ i = 0.5 for the 3rd interval.
Figure 6. VD property violates at different intervals for the values of shape parameters (a) ρ k = 1 , in 3rd interval and (b) σ i = 0.5 for the 3rd interval.
Applsci 12 03992 g006
Figure 7. The different objects (ae) are interpolated by default RQTS with periodic end condition.
Figure 7. The different objects (ae) are interpolated by default RQTS with periodic end condition.
Applsci 12 03992 g007
Figure 8. (ad) are RQTS curve through global tension, by ρ i = σ i = 2 ,   3 ,   5 , and 100   i .
Figure 8. (ad) are RQTS curve through global tension, by ρ i = σ i = 2 ,   3 ,   5 , and 100   i .
Applsci 12 03992 g008
Figure 9. (ad) are RQTS curve through global tension, by ρ k = σ k = 2 ,   3 ,   5 , and 100 , for any k .
Figure 9. (ad) are RQTS curve through global tension, by ρ k = σ k = 2 ,   3 ,   5 , and 100 , for any k .
Applsci 12 03992 g009
Figure 10. (ad) are RQTS curve through biased tension, by ρ i = 2 ,   3 ,   5 , and 10   i .
Figure 10. (ad) are RQTS curve through biased tension, by ρ i = 2 ,   3 ,   5 , and 10   i .
Applsci 12 03992 g010
Figure 11. (ad) are RQTS curve through biased tension, by σ i = 2 ,   3 ,   5 , and 10   i .
Figure 11. (ad) are RQTS curve through biased tension, by σ i = 2 ,   3 ,   5 , and 10   i .
Applsci 12 03992 g011
Figure 12. (ad) are RQTS curve through biased tension, by ρ k = 2 ,   3 ,   5 , and 10 for any k t h interval.
Figure 12. (ad) are RQTS curve through biased tension, by ρ k = 2 ,   3 ,   5 , and 10 for any k t h interval.
Applsci 12 03992 g012
Figure 13. (ad) are RQTS curve through biased tension, by σ k = 2 ,   3 ,   5 , and 10 for any kth interval.
Figure 13. (ad) are RQTS curve through biased tension, by σ k = 2 ,   3 ,   5 , and 10 for any kth interval.
Applsci 12 03992 g013aApplsci 12 03992 g013b
Figure 14. (a1,b1) under periodic end conditions, the default RQTS. (a2,b2) RQTS among local tension, with ρ i = σ i = 100 at the essential portion of the shape.
Figure 14. (a1,b1) under periodic end conditions, the default RQTS. (a2,b2) RQTS among local tension, with ρ i = σ i = 100 at the essential portion of the shape.
Applsci 12 03992 g014aApplsci 12 03992 g014b
Figure 15. Different objects (a1,b1,c1,d1,e1) are interpolated using RCS and (a2,b2,c2,d2,e2) using RQTS.
Figure 15. Different objects (a1,b1,c1,d1,e1) are interpolated using RCS and (a2,b2,c2,d2,e2) using RQTS.
Applsci 12 03992 g015aApplsci 12 03992 g015bApplsci 12 03992 g015c
Table 1. Table of time passed by two splines.
Table 1. Table of time passed by two splines.
Data UsedTime Passed by RCS in SecondsTime Passed by RQTS in SecondsDifference between the Times Passed in Seconds
Glass1.6741031.3494620.271486
Guitar1.8604451.5889770.291976
Butterfly0.7962800.5043040.36916
Ellipses0.8522810.4831210.245246
Egg0.4808490.2356030.513009
Fish1.5311271.0181180.271486
Table 2. Table of error study, for RCS and RQTS, for a various functions.
Table 2. Table of error study, for RCS and RQTS, for a various functions.
#Parameter t (Chosen)Utilized Function RCS Computed ErrorRQTS Computed ErrorError Difference Computed by Both Splines
1 π t π S i n ( t ) 5.7356 × 10 15 5.6966 × 10 15 3.90 × 10 17
2 π t π C o s ( t ) 1.2978 × 10 15   1.2988 × 10 15 −1.00 × 10 18
3 π t π T a n ( t ) 4.2201 × 10 15 4.1914 × 10 15 2.87 × 10 17
4 π t π S e c ( t ) 7.0537 × 10 16 5.0171 × 10 16 2.04 × 10 16
5 2 t 10 L o g ( t ) 2.2204 × 10 15 2.2204 × 10 15 0.00 × 10 0
6 2 t 10 t + 6 + ( t + 2 ) 2 4.8317 × 10 13 5.1159 × 10 13 −2.84 × 10 14
7 2 t 10 e t 3.9654 × 10 10 4.0018 × 10 10 −3.64 × 10 12
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Share and Cite

MDPI and ACS Style

Samreen, S.; Sarfraz, M.; Jabeen, N.; Althobaiti, S.; Mohamed, A. A Rational Quadratic Trigonometric Spline (RQTS) as a Superior Surrogate to Rational Cubic Spline (RCS) with the Purpose of Designing. Appl. Sci. 2022, 12, 3992. https://doi.org/10.3390/app12083992

AMA Style

Samreen S, Sarfraz M, Jabeen N, Althobaiti S, Mohamed A. A Rational Quadratic Trigonometric Spline (RQTS) as a Superior Surrogate to Rational Cubic Spline (RCS) with the Purpose of Designing. Applied Sciences. 2022; 12(8):3992. https://doi.org/10.3390/app12083992

Chicago/Turabian Style

Samreen, Shamaila, Muhammad Sarfraz, Nabila Jabeen, Saad Althobaiti, and Abdullah Mohamed. 2022. "A Rational Quadratic Trigonometric Spline (RQTS) as a Superior Surrogate to Rational Cubic Spline (RCS) with the Purpose of Designing" Applied Sciences 12, no. 8: 3992. https://doi.org/10.3390/app12083992

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop