1 Introduction

In analysis of nonlinear problems, perturbation methods [1], such as the multiple scales method and the averaging method, are often used to derive analytical solutions. However, the perturbation methods are feasible and reliable for low-degree-of-freedom systems with weak nonlinearities. In the work of Bajkowski and Szemplinska-Stupnicka [2], internal resonance in a two-degree-of-freedom system was investigated using both the averaging method and a numerical method, and results showed that amplitude–frequency response curves from the two methods become very different when there are strong nonlinearities in the system. To deal with multi-degree-of-freedom systems with strong nonlinearities, the incremental harmonic balance (IHB) method is one of the most amenable approaches: It can provide arbitrarily high accuracy for periodic solutions and is suitable for computer implementation [3]. The IHB method is a combination of Newton’s method and Galerkin procedure [4], which was first introduced by Lau and Cheung [5]; Galerkin procedure is essentially a harmonic balance procedure. The IHB method was successfully applied to many periodic vibration problems as well as some aperiodic vibration problems [6]. To automatically and reliably obtain amplitude–frequency response curves, an incremental arc-length method with a cubic extrapolation technique was developed in Ref. [7], and an improved arc-length method with a path-following technique was presented in Ref. [8]. With the arc-length method, an amplitude–frequency response curve can successfully trace a sharp peak, and a small number of iterations are required to obtain a convergent solution. Stability of periodic solutions of nonlinear systems was investigated using Liapunov–Floquet transformation based on Floquet theory [911]. Instability occurs when the transformation matrix has an eigenvalue whose modulus exceeds unity. There is a period-doubling bifurcation when the eigenvalue is less than \(-\)1. A periodic solution is stable when all eigenvalues are inside the unit circle. An efficient numerical method for approximating the transformation matrix in one period was developed by Hsu and Cheng [16]. Friedmann et al. [17] gave a concise formulation of Hsu’s method. The technique based on Floquet theory was used to study stability of steady-state solutions from the IHB method [7, 8], and bifurcations of periodic solutions can be detected and traced [1214]. The IHB method can also be used to determine parametric instability boundaries of a parametrically excited system [3, 15].

While the IHB method provides an efficient and reliable way to solve strongly nonlinear problems, to apply Newton’s method, much effort is devoted to calculating the Jacobian of nonlinear algebraic equations, which result from Galerkin procedure that is used to balance truncated terms of Fourier series of periodic solutions of nonlinear differential equations. Calculation of the Jacobian can be extremely difficult for a system with a high degree of freedom and complex nonlinearities. If numbers of truncated terms of the Fourier series are large enough, the Fourier coefficients can be approximated by coefficients of a discrete Fourier transform (DFT) that are calculated without using integrals. In practice, the fast Fourier transform (FFT) is used to efficiently calculate coefficients of a DFT [1820], which can improve calculation efficiency of the IHB method. However, complexity of constructing the Jacobian is still significant due to two reasons: First, calculation for obtaining FFT coefficients can be huge when there are large numbers of terms of Fourier series and second, Galerkin procedure and the following procedure to combine similar trigonometric terms are not simplified; they need cumbersome computation and are mistake-prone. To overcome the difficulties in constructing the Jacobian, a quasi-Newton method called Broyden’s method [21] can be used, in which the true Jacobian is replaced by an approximated Jacobian that is iteratively updated. The method was proved to have \(Q\)-quadratic convergence for nonlinear problems [22]. By using Broyden’s method, one does not need to construct the complex Jacobian of nonlinear algebraic equations. Instead, the Jacobian of the associated linear algebraic equations is used as the initial guess of an iteration procedure. Construction of the Jacobian of linear algebraic equations is much easier than that of nonlinear algebraic equations, which can be automatically generated with customized mass, damping, and stiffness matrices of the linear algebraic equations. When the arc-length method with the path-following technique is used to obtain an amplitude–frequency response curve, a complete set of equations is constructed by combining nonlinear algebraic equations with an augmenting equation [8]. Consequently, the Jacobian of the complete set of equations is a combination of the Jacobian of nonlinear algebraic equations and that of the augmenting equation. By using Broyden’s method to obtain the approximated Jacobian of the complete set of equations, the approximated Jacobian of the augmenting equation is also updated. However, the Jacobian of the augmenting equation that is updated by Broyden’s method should be invariant since its initial guess has exact values.

In this paper, a modified IHB method based on the FFT and Broyden’s method is presented. The Jacobian is not exactly calculated, but approximated using Broyden’s method, and Fourier coefficients of a residual are obtained using the FFT. To start Broyden’s method, the Jacobian of the associated linear algebraic equations is used as an initial guess of that of the nonlinear algebraic equations, which is directly generated with the mass, damping, and stiffness matrices, as shown in what follows. To obtain an amplitude–frequency response curve using the modified IHB method, the approximated Jacobian of the complete set of equations is constructed, and the property that the updated Jacobian of the augmenting equation is invariant when the augmenting equation is selected as a linear equation is proved. Duffing’s equation is used as an example to demonstrate the procedure of the modified IHB method. Solutions from the modified IHB method and Runge–Kutta method are compared, and stability of solutions is analyzed. The modified IHB method is also successfully used to calculate bifurcations of Mathieu–Duffing equation [24]. While single-degree-of-freedom systems are used to illustrate the modified IHB method in this paper, the methodology can be readily extended to multi-degree-of-freedom systems.

2 Modified IHB method

2.1 Introduction to the IHB method in solving Duffing’s equation

A second-order nonlinear differential equation for a single-degree-of-freedom system can be usually represented by

$$\begin{aligned} f(\ddot{u},\dot{u},u,t,\lambda , F)=0, \end{aligned}$$
(1)

where \(f\) is a nonlinear function, \(t\) and \(u\) are independent and dependent variables of the equation, respectively, \(\dot{u}\) and \(\ddot{u}\) are the first and second derivatives of \(u\) with respect to \(t\), respectively, \(\lambda \) is a parameter of the equation, and \(F\) is the amplitude of a harmonic excitation. If the nonlinear equation is Duffing’s equation, Eq. (1) can be written as

$$\begin{aligned} \ddot{u}+2\xi \dot{u}+\alpha u+\varepsilon u^{3}-F\cos \omega _f t=0, \end{aligned}$$
(2)

where \(\xi \) is the damping ratio, \(\alpha \) is a linear stiffness coefficient, \(\varepsilon \) is a nonlinear stiffness coefficient, and \(\omega _f\) is the frequency of the harmonic excitation. The procedure of the IHB method to solve Eq. (2) is shown below:

  1. 1.

    Assigning a dimensionless variable \(\tau =\omega t\), where \(\omega \) is the frequency variable. Replacing \(t\) by \(\tau \) in the first and second derivatives of \(u\) with respect to \(t\) yields

    $$\begin{aligned}&\dot{u} = \frac{du}{dt}=\omega \frac{du}{d\tau }=\omega {u}',\nonumber \\&\ddot{u}=\frac{d^{2}u}{dt^{2}}=\omega ^{2}\frac{d^{2}u}{d\tau ^{2}} = \omega ^{2}{u}'', \end{aligned}$$
    (3)

    respectively. Substituting Eq. (3) into Eq. (2) and letting \(p=\omega _f /\omega \) yield

    $$\begin{aligned} \omega ^{2}{u}''+2\omega \xi {u}'+\alpha u+\varepsilon u^{3}-F\cos p\tau =0. \end{aligned}$$
    (4)

    When \(p\) is an integer, one can calculate period-\(p\) solutions of subharmonic responses.

  2. 2.

    Linearizing Eq. (4) around a trial solution \((u_o, u_o^{\prime }, u_o^{\prime \prime },\omega _o )\) yields

    $$\begin{aligned}&\omega _o^{2}\Delta {u}''+2\omega _o \xi \Delta {u}'+(\alpha +3\varepsilon u_o^2 )\Delta u+f_\omega (u_o)\Delta \omega \nonumber \\&\quad =-f_o (u_o, \tau ), \end{aligned}$$
    (5)

    where \(f_o (u_o, \tau )=\omega _o^{2}u_o^{\prime \prime }+2\omega _o \xi u_o^{\prime }+\alpha u_o +\varepsilon u_o^3\) \( -F\cos p\tau \) is the residual of the linearized equation, \(f_\omega (u_o)=2\omega _o u_o^{\prime \prime }+2\xi u_o^{\prime }\) is the partial derivative of \(f\) with respect to \(\omega \), and \((\Delta u,\Delta {u}',\Delta {u}'',\Delta \omega )\) are increments of \((u_o ,u_o^{\prime },u_o^{\prime \prime },\omega _o )\) defined by \(\omega =\omega _o +\Delta \omega \) and \(u=u_o +\Delta u\).

  3. 3.

    Using truncated Fourier series to represent \(u\) and \(\Delta u\) yields

    $$\begin{aligned} u= & {} \left[ {1/2\;\;\cos \tau \;\;\cdots \;\;\cos n\tau \;\;\sin \tau \;\;\cdots \;\;\sin n\tau } \right] \nonumber \\&\left[ {a_0 \;\;a_1 \;\;\cdots \;\;a_n \;\;b_1 \;\;\cdots \;\;b_n } \right] ^{T}=\mathbf{C}_s^T \mathbf{A}, \end{aligned}$$
    (6)
    $$\begin{aligned} \Delta u= & {} \left[ {1/2\;\;\cos \tau \;\;\cdots \;\;\cos n\tau \;\;\sin \tau \;\;\cdots \;\;\sin n\tau } \right] \nonumber \\&\left[ {\Delta a_0 \;\;\Delta a_1 \;\;\cdots \;\;\Delta a_n \;\;\Delta b_1 \;\;\cdots \;\;\Delta b_n} \right] ^{T} \nonumber \\= & {} \mathbf{C}_s^T \Delta \mathbf{A}, \end{aligned}$$
    (7)

    where \(n\) is the number of truncated cosine and sine terms, \(\mathbf{C}_s^T =\left[ {1/2\;\;\cos \tau \;\;\cdots \;\;\cos n\tau \;\;\sin \tau } {\cdots \;\;\sin n\tau } \right] \) is the basis of the truncated Fourier series, \(\mathbf{A}=\left[ {a_0 \;\;a_1 \;\;\cdots \;\;a_n \;\;b_1 \;\;\cdots \;\;b_n } \right] ^{T}\) is the vector of the truncated Fourier coefficients for \(u\), and \(\Delta \mathbf{A}=\left[ {\Delta a_0 \;\;\Delta a_1 \;\;\cdots \;\;\Delta a_n \;\;\Delta b_1 \;\;\cdots } {\Delta b_n } \right] ^{T}\) is the vector of the truncated Fourier coefficients for \(\Delta u\), which is also the increment of \(\mathbf{A}\). The first and second derivatives of \(u\) are \({u}'=\mathbf{C}_s^{{T}^{\prime }}\mathbf{A}\) and \({u}''=\mathbf{C}_s^{{T}^{\prime \prime }}\mathbf{A}\), respectively; the first and second derivatives of \(\Delta u\) are \(\Delta {u}'=\mathbf{C}_s^{{T}^{\prime }}\Delta \mathbf{A}\) and \(\Delta {u}''=\mathbf{C}_s^{{T}^{\prime \prime }}\Delta \mathbf{A}\), respectively. Substituting Eqs. (6) and (7) into Eq. (5) yields

    $$\begin{aligned}&(\omega _o^{2}\mathbf{C}_s^{{T}^{\prime \prime }}+2\omega _o \xi \mathbf{C}_s^{{T}^{\prime }}+(\alpha +3\varepsilon \mathbf{C}_s^T \mathbf{A}_o \mathbf{C}_s^T\mathbf{A}_o)\mathbf{C}_s^T)\Delta \mathbf{A} \nonumber \\&\quad +\,f_\omega (\mathbf{C}_s^T \mathbf{A}_o )\Delta \omega =-f_o (\mathbf{C}_s^T \mathbf{A}_o, \tau ), \end{aligned}$$
    (8)

    where \(u_o =\mathbf{C}_s^T \mathbf{A}_o\) is the trial solution of Eq. (4). Note that Eq. (8) is the incremental equation of Eq. (4).

  4. 4.

    Making harmonic balance for Eqs. (4) and (8) via Galerkin procedure. Premultiplying Eq. (4) with \(u=\mathbf{C}_s^T \mathbf{A}\) by \(\mathbf{C}_s \) and integrating the resulting equation from \(\tau =0\) to \(2\pi \) yield

    $$\begin{aligned}&\frac{1}{\pi }\int _0^{2\pi } \mathbf{C}_s \left( \omega ^{2}\mathbf{C}_s^{{T}^{\prime \prime }}\mathbf{A}+2\omega \xi \mathbf{C}_s^{{T}^{\prime }}\mathbf{A}+(\alpha +\varepsilon \mathbf{C}_s^T \mathbf{AC}_s^T \mathbf{A}) \right. \nonumber \\&\quad \times \left. \mathbf{C}_s^T \mathbf{A}-F\cos p\iota \right) d\iota =\mathbf{0}_{(2n+1)\times 1}, \end{aligned}$$
    (9)

    where \(\mathbf{0}_{(2n+1)\times 1}\) is the \((2n+1)\)-dimensional zero vector. A similar procedure for Eq. (8) yields the incremental equation of Eq. (9):

    $$\begin{aligned} {\varvec{\Phi } }_A \Delta \mathbf{A}+{\varvec{\Phi } }_\omega \Delta \omega =-\mathbf{r}_{A_o }, \end{aligned}$$
    (10)

    where \(\varvec{\Phi }_A =\frac{1}{\pi }\int _0^{2\pi } {\mathbf{C}_s (\omega _o^{2}\mathbf{C}_s^{{T}^{\prime \prime }}+2\omega _o \xi \mathbf{C}_s^{{T}^{\prime }}+(\alpha } {+3\varepsilon \mathbf{C}_s^T \mathbf{A}_o \mathbf{C}_s^T\mathbf{A}_o)\mathbf{C}_s^T )d \iota }\) is the Jacobian of Eq. (9) with respect to \(\mathbf{A}\), \({\varvec{\Phi } }_\omega =\frac{1}{\pi }\int _0^{2\pi } {\mathbf{C}_s (2\omega _o \mathbf{C}_s^{{T}^{\prime \prime }}+2\xi } {\mathbf{C}_s^{{T}^{\prime }})\mathbf{A}_o d\iota }\) is the Jacobian of Eq. (9) with respect to \(\omega \), and \(\mathbf{r}_{A_o } =\frac{1}{\pi }\int _0^{2\pi } {\mathbf{C}_s f_o (\mathbf{C}_s^T \mathbf{A}_o, \iota )d\iota } \) is the residual of Eq. (9) associated with \(u_o =\mathbf{C}_s^T \mathbf{A}_o \).

  5. 5.

    Applying Newton’s method. Newton’s method is an iterative method to obtain a solution \(\mathbf{q}\) of \(\mathbf{A}\) in Eq. (9). With a fixed \(\omega \) in Eq. (9), the incremental equation in Eq. (10) becomes

    $$\begin{aligned} \varvec{\Phi }_q \Delta \mathbf{q}=-\mathbf{r}_q, \end{aligned}$$
    (11)

    where \(\varvec{\Phi }_q \) is the Jacobian of Eq. (9) with respect to \(\mathbf{q},\, \mathbf{r}_q\) is the residual of Eq. (9) with \(\mathbf{A}_o \) replaced by \(\mathbf{q}\), and \(\Delta \mathbf{q}=-\varvec{\Phi }_q^{-1} \mathbf{r}_q \) is the increment of \(\mathbf{q}\). One can update \(\mathbf{q}\) by \(\mathbf{q}_o +\Delta \mathbf{q}\), where \(\mathbf{q}_o \) is an initial guess of \(\mathbf{A}\). When the norm of \(\mathbf{r}_q \) is less than a preset tolerance, the solution of Eq. (4) is \(u=\mathbf{C}_s^T \mathbf{q}_o\).

2.2 Modified IHB method

A modified IHB method is introduced here, where \(\mathbf{r}_q \) is obtained by the FFT and Newton’s method is replaced by a quasi-Newton method called Broyden’s method. The associated linear differential equation of Eq. (4) is

$$\begin{aligned} \omega ^{2}{u}''+2\omega \xi {u}'+\alpha u-F\cos p\tau =0. \end{aligned}$$
(12)

Substituting \(u=\mathbf{C}_s^T \mathbf{A}\) into Eq. (12) and using Galerkin procedure for the resulting equation yield

$$\begin{aligned}&\frac{1}{\pi }\int _0^{2\pi } {\mathbf{C}_s (\omega ^{2}\mathbf{C}_s^{{T}^{\prime \prime }}+2\omega \xi \mathbf{C}_s^{{T}^{\prime }}+\alpha \mathbf{C}_s^T )} d\iota \mathbf{A}-\mathbf{r}_F \nonumber \\&\quad =\mathbf{0}_{(2n+1)\times 1}, \end{aligned}$$
(13)

where \(\mathbf{r}_F \) is the \((2n+1)\)-dimensional vector whose \((p+1)^{\mathrm{th}}\) entry is \(F\). The Jacobian of Eq. (13) is used as an initial guess of \(\varvec{\Phi }_q\). It can be calculated as follows:

$$\begin{aligned} \mathbf{B}_{q,0}= & {} \frac{1}{\pi }\int _0^{2\pi } {\mathbf{C}_s (\omega ^{2}\mathbf{C}_s^{{T}^{\prime \prime }}+2\omega \xi \mathbf{C}_s^{{T}^{\prime }}+\alpha \mathbf{C}_s^T )} d\iota \nonumber \\= & {} \omega ^{2}\left( {{\begin{array}{l@{\quad }l@{\quad }l} 0&{} {\mathbf{0}_{1\times n} }&{} {\mathbf{0}_{1\times n} } \\ {\mathbf{0}_{n\times 1}}&{} {\mathbf{C}^{1}_{n\times n} }&{} {\mathbf{0}_{n\times n} } \\ {\mathbf{0}_{n\times 1}}&{} {\mathbf{0}_{n\times n} }&{} {\mathbf{S}^{1}_{n\times n} } \\ \end{array} }} \right) \nonumber \\&+\,2\omega \xi \left( {{\begin{array}{l@{\quad }l@{\quad }l} 0&{} {\mathbf{0}_{1\times n} }&{} {\mathbf{0}_{1\times n} } \\ {\mathbf{0}_{n\times 1}}&{} {\mathbf{0}_{n\times n} }&{} {\mathbf{C}^{2}_{n\times n} } \\ {\mathbf{0}_{n\times 1}}&{} {\mathbf{S}^{2}_{n\times n} }&{} {\mathbf{0}_{n\times n} } \\ \end{array}}} \right) \nonumber \\&+ \, \alpha \left( {{\begin{array}{l@{\quad }l@{\quad }l} {1/2}&{} {\mathbf{0}_{1\times n} }&{} {\mathbf{0}_{1\times n} } \\ {\mathbf{0}_{n\times 1} }&{} {\mathbf{E}_{n\times n} }&{} {\mathbf{0}_{n\times n} } \\ {\mathbf{0}_{n\times 1} }&{} {\mathbf{0}_{n\times n} }&{} {\mathbf{E}_{n\times n} } \\ \end{array} }} \right) , \end{aligned}$$
(14)

where

$$\begin{aligned} \mathbf{C}^{1}_{n\times n}= & {} \mathbf{S}^{1}_{n\times n} =\left( {{\begin{array}{l@{\quad }l@{\quad }l} {1^{2}}&{} &{} 0 \\ &{} \ddots &{} \\ 0&{} &{} {n^{2}} \\ \end{array} }} \right) , \nonumber \\ \mathbf{C}^{2}_{n\times n}= & {} -\mathbf{S}^{2}_{n\times n} =\left( {{\begin{array}{l@{\quad }l@{\quad }l} 1&{} &{} 0 \\ &{} \ddots &{} \\ 0&{} &{} n \\ \end{array} }} \right) , \end{aligned}$$
(15)

and \(\mathbf{E}_{n\times n} \) is the \(n\)-dimensional identity matrix. With the last expression in Eq. (14), the Jacobian of the associated linear equation of Eq. (4) can be automatically generated. The solution of Eq. (13) \(\mathbf{q}_0 =\mathbf{B}_{q,0}^{-1} \mathbf{r}_F \) is used as an initial guess of \(\mathbf{q}\). The solution of Eq. (12) is \(\mathbf{C}_s^T \mathbf{q}_0 \).

If the nonlinearity in Eq. (4) is weak, i.e., \(\varepsilon \) is small, the solution of Eq. (4) can be iteratively obtained from that of Eq. (12). If the nonlinearity in Eq. (4) is strong, i.e., \(\varepsilon \) is large, the solution of Eq. (4) can be obtained from that of Eq. (12) by gradually incrementing the nonlinear stiffness coefficient from \(\varepsilon _0 =0\) to \(\varepsilon \) with a step size \(\Delta \varepsilon \). The final iterated solution \(\mathbf{q}^{(h)}\), where \(h\) is the step number to recover the nonlinear stiffness coefficient, and the final approximated Jacobian \(\mathbf{B}_q^{(h)}\) of Eq. (4) with an intermediate parameter \(\varepsilon ^{(h)}=h\cdot \Delta \varepsilon \) are used as initial guesses of the solution and the approximated Jacobian of Eq. (4) with the parameter \(\varepsilon ^{(h+1)}\), respectively. The procedure of the modified IHB method to solve Eq. (4) with some \(\varepsilon ^{(h)}\) is shown below.

  1. 1.

    Calculating the residual of Eq. (9) by the FFT. In the \(k^{\mathrm{th}}\) iteration, the approximated Jacobian and the solution are \(\mathbf{B}_{q,k} \) and \(\mathbf{q}_k \), respectively. The residual of Eq. (9) is

    $$\begin{aligned} \mathbf{r}_{q_k } =\frac{1}{\pi }\int _0^{2\pi } {\mathbf{C}_s f_o (\mathbf{C}_s^T \mathbf{q}_k, \iota )d\iota }. \end{aligned}$$
    (16)

    A fast and easy alternative to obtain the residual in Eq. (16) is via the FFT. The period of \(f_o (\mathbf{C}_s^T \mathbf{q}_k, \tau )\) is \(T=2\pi \), and \(2N\) points, where \(N>n\), that are equally distributed in \([0,2\pi )\) are selected as discretized points: \(\tau _i =i\frac{2\pi }{2N}\), where \(i=0,\ldots , 2N-1\). Values of \(f_o (\mathbf{C}_s^T \mathbf{q}_k, \tau )\) at \(\tau _i \) are \(f_o (\mathbf{C}_s^T \mathbf{q}_k, \tau _i )\). The DFT of \(f_o (\mathbf{C}_s^T \mathbf{q}_k, \tau _i )\) is

    $$\begin{aligned} F_o (\mathbf{q}_k, K)= & {} \frac{1}{2N}\sum _{i=0}^{2N-1} {f_o (\mathbf{C}_s^T \mathbf{q}_k, \tau _i )}\nonumber \\&\cdot \, e^{-j2\pi Ki/(2N)}, \end{aligned}$$
    (17)

    where \(K=0,\ldots , 2N-1\); \(F_o (\mathbf{q}_k, K)\) is a complex number and can be written as \(F_o (\mathbf{q}_k, K)=F_{\mathrm{Re}}^{(\mathbf{q}_k ,K)} +jF_{\mathrm{Im}}^{(\mathbf{q}_k, K)}\), where \(F_{\mathrm{Re}}^{(\mathbf{q}_k, K)} \) and \(F_{\mathrm{Im}}^{(\mathbf{q}_k, K)}\) are real numbers. Coefficients of \(\cos K\tau \) and \(\sin K\tau \) are

    $$\begin{aligned} Cos^{(\mathbf{q}_k, K)}= & {} \sqrt{\left( F_{\mathrm{Re}}^{(\mathbf{q}_k, K)} \right) ^{2}+\left( F_{\mathrm{Im}}^{(\mathbf{q}_k, K)} \right) ^{2}} \nonumber \\&\times \cos \left( \tan ^{-1}\left( \frac{F_{\mathrm{Im}}^{(\mathbf{q}_k, K)} }{F_{\mathrm{Re}}^{(\mathbf{q}_k, K)}}\right) \right) , \end{aligned}$$
    (18)
    $$\begin{aligned} Sin^{(\mathbf{q}_k, K)}= & {} \sqrt{\left( F_{\mathrm{Re}}^{(\mathbf{q}_k ,K)}\right) ^{2}+\left( F_{\mathrm{Im}}^{(\mathbf{q}_k, K)} \right) ^{2}} \nonumber \\&\times \sin \left( \tan ^{-1}\left( \frac{F_{\mathrm{Im}}^{(\mathbf{q}_k, K)} }{F_{\mathrm{Re}}^{(\mathbf{q}_k, K)}}\right) \right) , \end{aligned}$$
    (19)

    respectively. Consequently, \(\mathbf{r}_{q_k } \) can be approximated by

    $$\begin{aligned} \mathbf{r}_{q_k }= & {} \Big [Cos^{(\mathbf{q}_k, 0)}\;Cos^{(\mathbf{q}_k ,1)}\;\cdots \;Cos^{(\mathbf{q}_k, n)}\;Sin^{(\mathbf{q}_k ,1)} \nonumber \\&\cdots \;\;Sin^{(\mathbf{q}_k, n)}\Big ]^{T}. \end{aligned}$$
    (20)
  2. 2.

    Updating the approximated Jacobian and the solution using Broyden’s method. The incremental equation in Eq. (11) using Broyden’s method is

    $$\begin{aligned} \mathbf{q}_{k+1} -\mathbf{q}_k =-\mathbf{B}_{q,k}^{-1} \mathbf{r}_{q_k }. \end{aligned}$$
    (21)

    The residual in the \((k+1)^{\mathrm{th}}\) iteration \(\mathbf{r}_{q_{k+1} } \) can be obtained by using Eqs. (17)–(20) again with \(\mathbf{q}_k \) replaced by \(\mathbf{q}_{k+1} \), which is obtained from Eq. (21). The approximated Jacobian in the \((k+1)^{\mathrm{th}}\) iteration is updated by

    $$\begin{aligned} \mathbf{B}_{q,k+1} =\mathbf{B}_{q,k} +\frac{\left( {\mathbf{y}_k -\mathbf{B}_{q,k} \mathbf{s}_k } \right) \mathbf{s}_k^T }{\mathbf{s}_k^T \mathbf{s}_k }, \end{aligned}$$
    (22)

    where \(\mathbf{s}_k =\mathbf{q}_{k+1} -\mathbf{q}_k \) and \(\mathbf{y}_k =\mathbf{r}_{q_{k+1} } -\mathbf{r}_{q_k } \). When the norm of \(\mathbf{r}_{q_{k+1} } \) is less than a preset tolerance, the solution of Eq. (4) is \(\mathbf{C}_s^T \mathbf{q}_{k+1}\). Accuracy of the solution from the modified IHB method given by the tolerance, which is selected to be \(10^{-6}\) here, is the same as that from the original IHB method. Solutions of Duffing’s equation from the modified IHB method and Runge–Kutta method are shown in Fig. 1, and they are in excellent agreement. The calculation time using the original IHB method is 0.25 s, and that using the modified IHB method is 0.003 s, which is almost one hundredth of the former.

Fig. 1
figure 1

Solutions of Duffing’s equation with \(n=20,\, N=64,\, \xi =0.02,\, \alpha =1,\, \varepsilon =1,\, \omega _f =0.4\), and \(F=0.1\) from the modified IHB method and Runge–Kutta method

2.3 Arc-length method for the modified IHB method

To obtain an amplitude–frequency response curve of Eq. (4), a path of the steady-state solution versus the varying excitation frequency \(\omega _f =p\omega \) needs to be calculated. To avoid non-convergence at a sharp peak of an amplitude–frequency response curve, either the selective coefficient method [23] or the arc-length method with the path-following technique [8] can be used. In the modified IHB method, since the Jacobian of nonlinear algebraic equations with a current excitation frequency is approximated via iterations from its initial guess, which is the Jacobian of the nonlinear equations with a previous excitation frequency, constitution of the solution of the current equations is the same as that of the previous equations. Hence, the arc-length method with the path-following technique is a suitable method, and \(\mathbf{x}=[\mathbf{q}^{T}\omega ]^{T}\) is chosen as the new variable. The augmenting equation of the arc-length method is defined by

$$\begin{aligned} g(\mathbf{x})-\eta =0, \end{aligned}$$
(23)

where \(g\) is a path function and \(\eta \) is a path parameter. A combination of Eqs. (9) and (23) forms a complete set of equations:

$$\begin{aligned} \left\{ {{\begin{array}{l} \frac{1}{\pi }\int _0^{2\pi } {\mathbf{C}_s (\omega ^{2}\mathbf{C}_s^{{T}^{\prime \prime }}\mathbf{q}+2\omega \xi \mathbf{C}_s^{{T}^{\prime }}\mathbf{q}}\\ \qquad {+\,\,(\alpha +\varepsilon \mathbf{C}_s^T \mathbf{qC}_s^T \mathbf{q})\mathbf{C}_s^T \mathbf{q}+F\cos p\iota )d\iota }\\ \quad =\mathbf{0}_{(2n+1)\times 1} \\ {g([\mathbf{q}^{T}\;\;\omega ]^{T})-\eta =0} \\ \end{array} }} \right. . \end{aligned}$$
(24)

A path of the steady-state solution can be traced by actively incrementing \(\eta \). The incremental equation of Eq. (24) with some \(\eta \) is

$$\begin{aligned} {\varvec{\Phi }}_x \Delta \mathbf{x}= \left\{ {{\begin{array}{l} {{\begin{array}{l@{\quad }l} {{\varvec{\Phi }}_q} &{} {{\varvec{\Phi }}_\omega } \\ \end{array} }} \\ {dg/d\mathbf{x}^{T}} \\ \end{array}}} \right\} \Delta \mathbf{x}=-\left\{ {{\begin{array}{l} \quad {\mathbf{r}_x } \\ {g(\mathbf{x})-\eta } \\ \end{array} }} \right\} , \end{aligned}$$
(25)

where \(\Delta \mathbf{x}=[\Delta \mathbf{q}^{T}\;\;\Delta \omega ]^{T}\) and \({\varvec{\Phi }}_x \) is the Jacobian of Eq. (24); \({\varvec{\Phi }}_\omega \) can be obtained via the FFT from Eqs. (17)–(20) with \(f_o(\mathbf{C}_s^T \mathbf{q}_k, \tau )\) and \(\mathbf{r}_{q_k } \) replaced by \(2\omega _o \mathbf{C}_s^{{T}^{\prime \prime }}\mathbf{q}+2\xi \mathbf{C}_s^{{T}^{\prime }}\mathbf{q}\) and \({\varvec{\Phi } }_\omega \), respectively. When the solution of Eq. (24) with that path parameter \(\eta \) and the approximated Jacobian with respect to \(\mathbf{q}\), i.e., \(\mathbf{B}_q \), are obtained, \(\eta \) is updated by \(\eta +\Delta \eta \), and

$$\begin{aligned} \mathbf{x}_0 =\mathbf{x}_p +\mathbf{x}_d \Delta \eta , \end{aligned}$$
(26)

where \(\mathbf{x}_p\) is the solution of Eq. (24) with the previous \(\eta \) and \(\mathbf{x}_d =(\mathbf{x}_p -\mathbf{x}_b )/\left\| {\mathbf{x}_p -\mathbf{x}_b } \right\| \), in which \(\mathbf{x}_b \) is the solution of Eq. (24) with \(\eta \) being that before the previous one, is the unit vector for predicting the direction of change of the solution of Eq. (24) with the updated \(\eta \) and is used as an initial guess of the new variable \(\mathbf{x}\) of Eq. (24) with the updated \(\eta \). If the path function is \(g(\mathbf{x})=\mathbf{x}_d^T (\mathbf{x}-\mathbf{x}_p )\), the derivative of \(g\) with respect to \(\mathbf{x}\) is \(dg/d\mathbf{x}^{T}=\mathbf{x}_d^T \). An initial guess of the Jacobian of Eq. (24) with the updated \(\eta \) is chosen to be

$$\begin{aligned} \mathbf{B}_{x,0} =\left\{ {{\begin{array}{l} {{\begin{array}{l@{\quad }l} {\mathbf{B}_{q,0} }&{} {\mathbf{B}_{\omega , 0} } \\ \end{array} }} \\ \qquad {\mathbf{x}_d^T } \\ \end{array} }} \right\} , \end{aligned}$$
(27)

where \(\mathbf{B}_{q,0} =\mathbf{B}_q \) is an initial guess of \({\varvec{\Phi }}_q \) and \(\mathbf{B}_{\omega , 0} ={\varvec{\Phi }}_\omega \). In updating \(\mathbf{B}_{x,k} \) using Broyden’s method in the \(k^{\mathrm{th}}\) iteration, all the entries of \(\mathbf{B}_{x,k} \) can be changed. However, the last row of \(\mathbf{B}_{x,k} \) is a constant vector \(\mathbf{x}_d^T \), and invariant, which is proved below.

Replacing \({\varvec{\Phi } }_x\) in Eq. (25) by \(\mathbf{B}_{x,k}\) and \(\mathbf{x}\) by \(\mathbf{x}_k \) in the resulting equations yields

$$\begin{aligned} \mathbf{B}_{x,k} \Delta \mathbf{x}=\left( {{\begin{array}{l} {{\begin{array}{l@{\quad }l} {\mathbf{B}_{q,k} \Delta \mathbf{q}} &{} \,\, {\mathbf{B}_{\omega , k} \Delta \mathbf{x}} \\ \end{array} }} \\ \qquad {\mathbf{x}_d^T \Delta \mathbf{x}} \\ \end{array} }} \right) =-\mathbf{r}_k, \end{aligned}$$
(28)

where \(\mathbf{r}_k =[\mathbf{r}_{x_k }^T \;\;g(\mathbf{x}_k )-\eta ]^{T}\) is the residual of Eq. (25) at \(\mathbf{x}_k \). The last row in Eq. (28) is

$$\begin{aligned} \mathbf{x}_d^T \Delta \mathbf{x}=-g(\mathbf{x}_k )+\eta . \end{aligned}$$
(29)

The residual of Eq. (25) in the \((k+1)^{\mathrm{th}}\) iteration at \(\mathbf{x}_{k+1} =\mathbf{x}_k +\Delta \mathbf{x}\) is \(\mathbf{r}_{k+1} =[\mathbf{r}_{x_{k+1} }^T \;\;g(\mathbf{x}_{k+1} )-\eta ]^{T}\). The last entry of \(\mathbf{r}_{k+1} \) is

$$\begin{aligned} g(\mathbf{x}_{k+1})-\eta =g(\mathbf{x}_k +\Delta \mathbf{x})-\eta . \end{aligned}$$
(30)

Using \(g(x)=x_d^T (x-x_p )\) in Eq. (30) yields

$$\begin{aligned} g(\mathbf{x}_k +\Delta \mathbf{x})-\eta =\mathbf{x}_d^T (\mathbf{x}_k -\mathbf{x}_p )-\eta +\mathbf{x}_d^T \Delta \mathbf{x}. \end{aligned}$$
(31)

Substituting Eq. (29) into Eq. (31) yields

$$\begin{aligned} \mathbf{x}_d^T (\mathbf{x}_k -\mathbf{x}_p )-\eta +\mathbf{x}_d^T \Delta \mathbf{x}=g(\mathbf{x}_k )-\eta -g(\mathbf{x}_k )+\eta =0,\nonumber \\ \end{aligned}$$
(32)

which means that \(\mathbf{r}_{k+1} =[\mathbf{r}_{x_{k+1} }^T 0]^{T}\). Using \(\mathbf{y}_k =\mathbf{r}_{k+1} -\mathbf{r}_k \) and \(\mathbf{s}_k =\Delta \mathbf{x}\) in Eq. (22) to update \(\mathbf{B}_{x,k} \) yields

$$\begin{aligned} \mathbf{B}_{x,k+1}= & {} \mathbf{B}_{x,k} +\frac{\left( {\mathbf{r}_{k+1} -\mathbf{r}_k -\mathbf{B}_{x,k} \Delta \mathbf{x}} \right) \Delta \mathbf{x}^{T}}{\Delta \mathbf{x}^{T}\Delta \mathbf{x}} \nonumber \\= & {} \mathbf{B}_{x,k} +\frac{\mathbf{r}_{k+1} \Delta \mathbf{x}^{T}}{\Delta \mathbf{x}^{T}\Delta \mathbf{x}}, \nonumber \\= & {} \mathbf{B}_{x,k} +\frac{[\mathbf{r}_{x_{k+1} }^T, \mathbf{0}]^{T}\Delta \mathbf{x}^{T}}{\Delta \mathbf{x}^{T}\Delta \mathbf{x}} \nonumber \\= & {} \mathbf{B}_{x,k} +\frac{[\Delta \mathbf{x}\cdot \mathbf{r}_{x_{k+1} }^T, \mathbf{0}]^{T}}{\Delta \mathbf{x}^{T}\Delta \mathbf{x}}, \end{aligned}$$
(33)

which means that the last row of \(\mathbf{B}_{x,k+1} \) is equal to that of \(\mathbf{B}_{x,k} \). Hence, the last row of \(\mathbf{B}_{x,k} \) for any \(k\) is equal to that of \(\mathbf{B}_{x,0} \), which is \(\mathbf{x}_d^T \), and the invariance property of the last row of \(\mathbf{B}_{x,k} \) is proved.

2.4 Stability of periodic solutions

Stability of a steady-state solution from the modified IHB method can be evaluated by Floquet theory. Assume \(u_{ss} \) is the steady-state solution that satisfies Eq. (4) and \(\delta u\) is a small perturbation around \(u_{ss} \). Using \(u=u_{ss} +\delta u\) in Eq. (4) yields

$$\begin{aligned}&\omega ^{2}\delta {u}''+2\omega \xi \delta {u}'+\left( \alpha +3\varepsilon u_{ss}^2 \right) \delta u\nonumber \\&\quad =-f_o (u_{ss}, \tau )=0. \end{aligned}$$
(34)

Transforming Eq. (34) to a state-space form with a state-space variable \(\mathbf{V}=[\delta u,\delta {u}']^{T}\) yields

$$\begin{aligned} \mathbf{{V}'}= & {} \left( {{\begin{array}{l} {\delta {u}'} \\ {\delta {u}''} \\ \end{array} }} \right) =\left( {{\begin{array}{l@{\quad }l} 0 &{} 1 \\ {-\frac{(\alpha +3\varepsilon u_{ss}^2 )}{\omega ^{2}}}&{} {-\frac{2\xi }{\omega }} \\ \end{array} }} \right) \left( {{\begin{array}{l} {\delta u} \\ {\delta {u}'} \\ \end{array} }} \right) \nonumber \\= & {} \varvec{\Theta }(\tau ) \mathbf{V}, \end{aligned}$$
(35)

where \(\varvec{\Theta }(\tau )\) is a periodic matrix with respect to \(\tau \), whose period is \(2\pi \). Stability of Eq. (34) can be evaluated by calculating eigenvalues of the transformation matrix \(\mathbf{Q}\) that transforms \(\mathbf{V}\) at \(\tau =2n\pi \) to that at \(\tau =2(n+1)\pi \). The transformation matrix \(\mathbf{Q}\) can be calculated using Hsu’s method [16] in the form

$$\begin{aligned} \mathbf{Q}=\prod _{i_{\mathrm{Q}} =1}^{N_\mathrm{Q}} {\exp (\Delta \tau \cdot \varvec{\Theta }(i_\mathrm{Q} \cdot \Delta \tau )} ), \end{aligned}$$
(36)

where \(N_{\mathrm{Q}}\) is the number of equal divisions of the period and \(\Delta \tau =2\pi /N_{\mathrm{Q}} \) is the length of one division. If all of the eigenvalues of \(\mathbf{Q}\) is inside a unit circle, the steady-state solution is stable; otherwise, the solution is unstable. Furthermore, if the unstable solution yields an eigenvalue that is less than \(-1\), a period-doubling bifurcation occurs and there are stable subharmonic responses [8]. When there are two complex conjugate eigenvalues that escape from the unit circle, a Hopf bifurcation occurs. An amplitude–frequency response curve of Duffing’s equation calculated using the arc-length method with the path-following technique is shown in Fig. 2, and stability of the solution is indicated.

Fig. 2
figure 2

Amplitude–frequency response curve of Duffing’s equation with \(n=20,\, N=64,\, \xi =0.02,\, \alpha =1,\, \varepsilon =1\), and \(F=0.1\), where stability of the solution is indicated

3 Bifurcations of Mathieu–Duffing equation studied by the modified IHB method

Mathieu–Duffing equation represents a parametrically excited nonlinear system:

$$\begin{aligned} \ddot{u}+2\hat{{\xi }}\dot{u}-(\hat{{\alpha }}+\beta \sin \Omega t)u+\gamma u^{3}=0, \end{aligned}$$
(37)

where \(\hat{{\xi }}=0.125\) is the damping ratio, \(\hat{{\alpha }}=1\) is a linear stiffness coefficient, \(\beta \) is the amplitude of the parametric excitation, \(\Omega =2\) is the frequency of the excitation, and \(\gamma =1\) is a nonlinear stiffness coefficient. Bifurcations occur when \(\beta \) varies, and the modified IHB method can be used to study it. The dimensionless time variable is \(\tau =\omega t\); substituting the expression into Eq. (37) yields

$$\begin{aligned} \omega ^{2}{u}''+2\omega \hat{{\xi }}{u}'-(\hat{{\alpha }}+\beta \sin p\tau )u+\gamma u^{3}=0, \end{aligned}$$
(38)

where \(p=\Omega /\omega \) indicates the number of period-doubling bifurcations. If \(p= 1, 2, 4, {\ldots }\) are selected in Eq. (38), period-1, 2, 4, ... solutions can be calculated. The period-\(p\) solution can be solved by the modified IHB method with a controlled amplitude that is a Fourier coefficient of the solution of Eq. (38). Making harmonic balance for Eq. (38) with \(u=\mathbf{C}_s^T \mathbf{A}\) yields

$$\begin{aligned}&\frac{1}{\pi }\int _0^{2\pi } \mathbf{C}_s \Big (\omega ^{2}\mathbf{C}_s^{{T}^{\prime \prime }}+2\omega \hat{{\xi }}\mathbf{C}_s^{{T}^{\prime }}-\left( \hat{{\alpha }}+\beta \sin p\iota \right. \nonumber \\&\quad \left. -\,\gamma \mathbf{C}_s^T \mathbf{AC}_s^T \mathbf{A}\right) \mathbf{C}_s^T \Big )\mathbf{A}d\iota =\mathbf{0}_{(2n+1)\times 1}. \end{aligned}$$
(39)

The incremental equation of Eq. (39) is

$$\begin{aligned} {\varvec{\Phi }}_A \Delta \mathbf{A}+{\varvec{\Phi } }_\beta \Delta \beta =-\mathbf{r}_{X_o }, \end{aligned}$$
(40)

where \({\varvec{\Phi } }_A \) is the Jacobian of Eq. (39) with respect to \(\mathbf{A},\, {\varvec{\Phi } }_\beta =-\frac{1}{\pi }\int _0^{2\pi } {\mathbf{C}_s (\sin p\iota \mathbf{A})\mathbf{C}_s^T d\iota } \) is the Jacobian of Eq. (39) with respect to \(\beta \), and \(\mathbf{r}_{X_o}\) is the residual of Eq. (39) with \([\mathbf{A}^{T}\;\;\beta ]^{T}\) replaced by a trial solution \(\mathbf{X}_o =[\mathbf{A}_o^T \;\;\beta _o ]^{T}\). Let the amplitude of the \(n_c^{\mathrm{th}} \) cosine term of Fourier series of \(u\), which is the \((n_c +1)^{\mathrm{th}}\) entry of \(\mathbf{A}\), be the controlled amplitude. The solution of \(\mathbf{A}\) in Eq. (39) is \(\mathbf{q}=\left[ {a_0 \;\;\cdots \;\;a_{n_c -1} \;\;\beta \;\;a_{n_c +1} \;\;\cdots \;\;a_n \;\;b_1 \;\;\cdots \;\;b_n } \right] ^{T}\), and Eq. (40) becomes

$$\begin{aligned} {\varvec{\Phi }}_q \Delta \mathbf{q}=-\mathbf{r}_q, \end{aligned}$$
(41)

where \({\varvec{\Phi } }_q \) is the Jacobian of Eq. (39) with respect to \(\mathbf{q}\), which is \({\varvec{\Phi } }_A \) with its \(n_c^{\mathrm{th}} \) column replaced by \({\varvec{\Phi } }_\beta \), \(\Delta \mathbf{q}\) is the increment of \(\mathbf{q}\), and \(\mathbf{r}_q \) is the residual of Eq. (39) at \(\mathbf{q}\). With some trials, the solution of Fourier coefficients with \(\beta _0 =3.6\) is

$$\begin{aligned} \mathbf{A}_0= & {} \left[ 0.7881\;\;{-}1.3956\;\;0.2686\;0.1121\right. \\&{-}0.0260\;\;0.0026\;\;{-}0.0008\;\;{-}0.0001 \\&0.0001\;\;0,1.9884\;\;{-}0.1693\;\;0.0472 \\&\left. {-}0.0175\;\;{-}0.0042\;\;0.0021\;\;{-}0.0003\;\;0\;\;0\right] \end{aligned}$$

when \(n=9\). In the procedure to find \(\mathbf{A}_0 \), the initial guess of \(\varvec{\Phi }_{q}\) can be obtained from the Jacobian of linear algebraic equations given in Sect. 2.2. The modified IHB method can be used to obtain the bifurcation diagram of Mathieu–Duffing equation.

When \(\beta \) increases from \(\beta _0 =3.6\), solutions of Mathieu–Duffing equation are stable period-1 solutions, as shown in Fig. 3. The second entry of \(\mathbf{A}_1 =\left[ {a_0^{(1)} \;\;a_1^{(1)} \;\;\cdots \;\;a_n^{(1)} \;\;b_1^{(1)} \;\;\cdots \;\;b_n^{(1)} } \right] ^{T}\), which is the vector of Fourier coefficients of a period-1 solution, is used as the controlled amplitude, i.e., \(n_c =1\). The controlled amplitude is increased with a step size of 0.0005, until the period-1 solution is unstable at the critical point \(\beta _1 =4.825\). Let the solution of Eq. (39) at \(\beta _1 \) be \(\mathbf{A}_1 =\left[ {a_0^{(1)*} \;\;a_1^{(1)*} \;\;\cdots \;\;a_n^{(1)*} \;\;b_1^{(1)*} \;\;\cdots \;\;b_n^{(1)*} } \right] ^{T}\). The vector of Fourier coefficients of a period-2 solution is \(\mathbf{A}_2 =\left[ {a_0^{(2)} \;\;a_1^{(2)} \;\;\cdots \;\;a_{2n}^{(2)} \;\;b_1^{(2)} \;\;\cdots \;\;b_{2n}^{(2)} } \right] ^{T}\). The initial guess of \(\mathbf{A}_2 \) is given by \(a_0^{(2)} =a_0^{(1)*}, a_{2j}^{(2)} =a_j^{(1)*} ,\, b_{2j}^{(2)} =b_j^{(1)*} \), where \(j=1,\ldots , n\), and \(a_{2j-1}^{(2)} =0,\, b_{2j-1}^{(2)} =0\), where \(j=1,\ldots , n\). The controlled amplitude for bifurcation solutions is \(a_1^{(2)} \), and it is increased with a step size of 0.0001, until the period-2 solution is unstable at the critical point \(\beta _2 =5.194\). With the same procedure, the critical point corresponding to the unstable period-4 solution is \(\beta _4 =5.253\). Period-2 and period-4 solutions are shown in Figs. 4 and 5, respectively. The bifurcation diagram of \(u(\tau =0)\) versus \(\beta \) is shown in Fig. 6.

Fig. 3
figure 3

Period-1 solution of Mathieu–Duffing equation with \(\beta =4.1906\)

Fig. 4
figure 4

Period-2 solution of Mathieu–Duffing equation with \(\beta =4.8390\)

Fig. 5
figure 5

Period-4 solution of Mathieu–Duffing equation with \(\beta =5.2508\)

Fig. 6
figure 6

Bifurcation diagram of Mathieu–Duffing equation

4 Conclusion

The modified IHB method includes approximation of Fourier coefficients of the residual of nonlinear differential equations by the FFT, which is carried out in Eqs. (17)–(20), and use of Broyden’s method with the Jacobian of the associated linear algebraic equations as an initial guess of that of the nonlinear algebraic equations. It is first illustrated by solving Duffing’s equation; solutions from the modified IHB method and Runge–Kutta method are in excellent agreement. The calculation time for the modified IHB method is almost two orders of magnitude smaller than that for the original IHB method. By showing that the Jacobian of the path function in Broyden’s method is invariant, an amplitude–frequency response curve of Duffing’s equation is calculated using the arc-length method with the path-following technique. The modified IHB method can also be used to solve for subharmonic responses, which is illustrated by studying bifurcations of Mathieu–Duffing equation. The most cumbersome part of the original IHB method is to make harmonic balance of nonlinear differential equations and obtain the Jacobian of the corresponding nonlinear algebraic equations. The modified IHB method provides an easy procedure to make harmonic balance and approximate the Jacobian, which gives the same accuracy as that of the original IHB method, and one does not need to devote much effort to deriving an algorithm of a specific problem.