当前位置:网站首页>[combinatorics] recursive equation (special solution form | special solution solving method | special solution example)
[combinatorics] recursive equation (special solution form | special solution solving method | special solution example)
2022-07-03 17:16:00 【Programmer community】
List of articles
- One 、 Special solution form and solution
- Two 、 Special solution form and solution Example
One 、 Special solution form and solution
H
(
n
)
−
a
1
H
(
n
−
1
)
−
⋯
−
a
k
H
(
n
−
k
)
=
f
(
n
)
H(n) - a_1H(n-1) - \cdots - a_kH(n-k) = f(n)
H(n)−a1H(n−1)−⋯−akH(n−k)=f(n) ,
n
≥
k
,
a
k
≠
0
,
f
(
n
)
≠
0
n\geq k , a_k\not= 0, f(n) \not= 0
n≥k,ak=0,f(n)=0
The left side of the above equation And “ Linear homogeneous recurrence equation with constant coefficients ” It's the same , But not on the right
0
0
0 , It's based on
n
n
n Of function
f
(
n
)
f(n)
f(n) , This type of recursive equation is called “ Linear Nonhomogeneous recurrence equation with constant coefficients ” ;
H
(
n
)
‾
\overline{H(n)}
H(n) Is corresponding to the above recursive equation “ Linear homogeneous recurrence equation with constant coefficients ”
H
(
n
)
−
a
1
H
(
n
−
1
)
−
⋯
−
a
k
H
(
n
−
k
)
=
0
H(n) - a_1H(n-1) - \cdots - a_kH(n-k) = 0
H(n)−a1H(n−1)−⋯−akH(n−k)=0 A general understanding of ,
H
∗
(
n
)
H^*(n)
H∗(n) Is a special solution ,
“ Linear Nonhomogeneous recurrence equation with constant coefficients ” The general solution is
H
(
n
)
=
H
(
n
)
‾
+
H
∗
(
n
)
H(n) = \overline{H(n)} + H^*(n)
H(n)=H(n)+H∗(n)
stay 【 Combinatorial mathematics 】 Recurrence equation ( Example of solving recurrence equation without multiple roots | Complete process of solving recursive equations without multiple roots ) The blog introduces “ Linear homogeneous recurrence equation with constant coefficients ” The general solution of ;
This blog begins with Special solution
H
∗
(
n
)
H^*(n)
H∗(n) The way of seeking ;
Special solutions and “ Linear Nonhomogeneous recurrence equation with constant coefficients ” The right part of
f
(
n
)
f(n)
f(n) of ,
f
(
n
)
f(n)
f(n) by
n
n
n Of
t
t
t Sub polynomial ,
Special solution
H
∗
(
n
)
H^*(n)
H∗(n) It's also
n
n
n Of
t
t
t Sub polynomial ;
1 . Special solution form :
( 1 ) Special solution form : Special solution
H
∗
(
n
)
H^*(n)
H∗(n) yes
n
n
n Of
t
t
t Sub polynomial ,
n
n
n The power of is taken from
0
0
0 To
t
t
t , Therefore, its Number of items
t
+
1
t+1
t+1 term ;
( 2 ) Understand each component :
- ① Number of items :
t
+
1
t+1
t+1 term
- ② form : The special solution term consists of constant multiply
n
n
n Power of power form , Constants are unknown ;
- ③ constant :
t
+
1
t+1
t+1 It's a constant , Use subscripts to identify ;
- ④
n
n
0
0
0 To
t
t
t ;
n The power of : The power value is from
( 3 ) give an example : Special solution
H
∗
(
n
)
H^*(n)
H∗(n) yes
n
n
n Of
2
2
2 Sub polynomial ;
Number of special solutions : be Number of special solutions yes
2
+
1
=
3
2 + 1 = 3
2+1=3 term ;
Understand each component : Each term is explained by constant multiply
n
n
n Power of power form ,
3
3
3 It's a constant Set to
P
1
,
P
2
,
P
3
P_1, P_2, P_3
P1,P2,P3 ,
3
3
3 individual
n
n
n Power of power , Power value from
0
0
0 To
2
2
2 ,
Therefore, the form of the special solution is
H
∗
(
n
)
=
P
1
n
2
+
P
2
n
1
+
P
3
n
0
H^*(n) = P_1n^2 + P_2n^1 + P_3n^0
H∗(n)=P1n2+P2n1+P3n0 ,
It is reduced to :
H
∗
(
n
)
=
P
1
n
2
+
P
2
n
+
P
3
H^*(n) = P_1n^2 + P_2n + P_3
H∗(n)=P1n2+P2n+P3
2 . Special solution method :
( 1 ) First write the form of the special solution : Special solution
H
∗
(
n
)
H^*(n)
H∗(n) It's also
n
n
n Of
t
t
t Sub polynomial ; Such as :
f
(
n
)
f(n)
f(n) by
n
n
n Of
2
2
2 Sub polynomial , The special solution is
H
∗
(
n
)
=
P
1
n
2
+
P
2
n
+
P
3
H^*(n) = P_1n^2 + P_2n + P_3
H∗(n)=P1n2+P2n+P3
( 2 ) The special solution is substituted into the recursive equation : Then the special solution is substituted into the recursive equation , Determine the coefficients in the special solution ;
Two 、 Special solution form and solution Example
Recurrence equation :
a
n
+
5
a
n
−
1
+
6
a
n
−
2
=
3
n
2
a_n + 5a_{n-1} + 6a_{n-2}=3n^2
an+5an−1+6an−2=3n2 ;
1 . Special solution form :
On the left side of the above recursive equation is “ Linear homogeneous recurrence equation with constant coefficients ” form , Never mind ,
On the right side of the
3
n
2
3n^2
3n2 Related to special solutions ,
3
n
2
3n^2
3n2 by
n
n
n Of
2
2
2 Sub polynomial ,
Therefore, the special solution
H
∗
(
n
)
H^*(n)
H∗(n) It's also
n
n
n Of
2
2
2 Sub polynomial ;
2 . Write the special solution form :
Number of special solutions : be Number of special solutions yes
2
+
1
=
3
2 + 1 = 3
2+1=3 term ;
Understand each component : Each term is explained by constant multiply
n
n
n Power of power form ,
3
3
3 It's a constant Set to
P
1
,
P
2
,
P
3
P_1, P_2, P_3
P1,P2,P3 ,
3
3
3 individual
n
n
n Power of power , Power value from
0
0
0 To
2
2
2 ,
Therefore, the form of the special solution is
H
∗
(
n
)
=
P
1
n
2
+
P
2
n
1
+
P
3
n
0
H^*(n) = P_1n^2 + P_2n^1 + P_3n^0
H∗(n)=P1n2+P2n1+P3n0 ,
It is reduced to :
H
∗
(
n
)
=
P
1
n
2
+
P
2
n
+
P
3
H^*(n) = P_1n^2 + P_2n + P_3
H∗(n)=P1n2+P2n+P3
3 . Put the special solution into the recursive equation :
Will explain
H
∗
(
n
)
=
P
1
n
2
+
P
2
n
+
P
3
H^*(n) = P_1n^2 + P_2n + P_3
H∗(n)=P1n2+P2n+P3 ,
Into the recursive equation
a
n
+
5
a
n
−
1
+
6
a
n
−
2
=
3
n
2
a_n + 5a_{n-1} + 6a_{n-2}=3n^2
an+5an−1+6an−2=3n2 in ,
obtain :
(
P
1
n
2
+
P
2
n
+
P
3
)
+
5
(
P
1
(
n
−
1
)
2
+
P
2
(
n
−
1
)
+
P
3
)
+
6
(
P
1
(
n
−
2
)
2
+
P
2
(
n
−
2
)
+
P
3
)
=
3
n
2
(P_1n^2 + P_2n + P_3) + 5(P_1(n-1)^2 + P_2(n-1) + P_3) + 6(P_1(n-2)^2 + P_2(n-2) + P_3)=3n^2
(P1n2+P2n+P3)+5(P1(n−1)2+P2(n−1)+P3)+6(P1(n−2)2+P2(n−2)+P3)=3n2
4 . analysis
n
n
n Write the system of equations by the power of :
The left and right sides are equal , here according to
n
n
n The coefficient before the power of , Write the equations ;
analysis
n
n
n Coefficient to the power of :
n
2
n^2
3
n
2
3n^2
3n2 , therefore
n
2
n^2
n2 The coefficient before is
3
3
3 ; Expand the left side ,
n
2
n^2
n2 Add the coefficients before , In the end, it's equal to
3
3
3 ;
12
P
1
n
2
=
3
n
2
12P_1n^2 = 3n^2
12P1n2=3n2
n2 Coefficient analysis : The right side is
n
1
n^1
n
1
n^1
n1 , That is, no
n
n
n term , So on the left
n
n
n The coefficient before the term is
0
0
0 ; Expand the left side ,
n
n
n Add the coefficients before , In the end, it's equal to
0
0
0 ;
−
34
P
1
n
+
12
P
2
n
=
0
n
-34P_1n + 12P_2n = 0n
−34P1n+12P2n=0n
n1 Coefficient analysis : There's no on the right
n
0
n^0
n
0
n^0
n0 , That is, no
1
1
1 term ( Pure numeric items ) , Therefore, the number item on the left is
0
0
0 ; Expand the left side , The numerical term finally equals
0
0
0 ;
29
P
1
−
17
P
2
+
12
P
3
=
0
29P_1 - 17P_2 + 12 P_3 = 0
29P1−17P2+12P3=0
n0 Coefficient analysis : There's no on the right
Finally, we get the equations :
{
12
P
1
=
3
−
34
P
1
+
12
P
2
=
0
29
P
1
−
17
P
2
+
12
P
3
=
0
\begin{cases} 12P_1 = 3 \\\\ -34P_1 + 12P_2 = 0 \\\\ 29P_1 - 17P_2 + 12 P_3 = 0 \end{cases}
⎩⎪⎪⎪⎪⎪⎪⎨⎪⎪⎪⎪⎪⎪⎧12P1=3−34P1+12P2=029P1−17P2+12P3=0
Solve the above equations , Get the results :
{
P
1
=
1
4
P
2
=
7
24
P
3
=
115
288
\begin{cases} P_1 = \cfrac{1}{4} \\\\ P_2 = \cfrac{7}{24} \\\\ P_3 = \cfrac{115}{288} \end{cases}
⎩⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎨⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎧P1=41P2=247P3=288115
The special solution is :
H
∗
(
n
)
=
1
4
n
2
+
7
24
n
+
115
288
H^*(n) = \cfrac{1}{4} n^2 + \cfrac{7}{24}n + \cfrac{115}{288}
H∗(n)=41n2+247n+288115
The final general solution is :
H
(
n
)
=
c
1
(
−
2
)
n
+
c
2
(
−
3
)
n
+
1
4
n
2
+
7
24
n
+
115
288
H(n) = c_1(-2)^n + c_2(-3)^n + \cfrac{1}{4} n^2 + \cfrac{7}{24}n + \cfrac{115}{288}
H(n)=c1(−2)n+c2(−3)n+41n2+247n+288115
边栏推荐
- Squid service startup script
- How do large consumer enterprises make digital transformation?
- Electronic Science and technology 20th autumn "Microcomputer Principle and application" online assignment 2 [standard answer]
- 网络硬盘NFS的安装与配置
- 匯編實例解析--實模式下屏幕顯示
- Cross border e-commerce: advantages of foreign trade enterprises in overseas social media marketing
- 比亚迪、长城混动市场再“聚首”
- Leetcode13. Roman numeral to integer (three solutions)
- [RT thread] NXP rt10xx device driver framework -- RTC construction and use
- Life is still confused? Maybe these subscription numbers have the answers you need!
猜你喜欢
kubernetes资源对象介绍及常用命令(四)
Talk about several methods of interface optimization
Great changes! National housing prices fell below the 10000 yuan mark
Prepare for the golden three silver four, 100+ software test interview questions (function / interface / Automation) interview questions. win victory the moment one raises one 's standard
One brush 147-force deduction hot question-4 find the median of two positive arrays (H)
设计电商秒杀
[try to hack] active detection and concealment technology
UE4 official charging resources, with a total price of several thousand
One brush 145 force deduction hot question-2 sum of two numbers (m)
聊聊接口优化的几个方法
随机推荐
ANOVA example
[combinatorics] recursive equation (characteristic equation and characteristic root | example of characteristic equation | root formula of monadic quadratic equation)
A day's work list of an ordinary programmer
Thread pool: the most common and error prone component of business code
Apache service suspended asynchronous acceptex failed
企业级自定义表单引擎解决方案(十一)--表单规则引擎1
An example of HP array card troubleshooting
Squid service startup script
【JokerのZYNQ7020】DDS_ Compiler。
UE4 official charging resources, with a total price of several thousand
Kotlin学习快速入门(7)——扩展的妙用
Dagong 21 autumn "power plant electrical part" online operation 1 [standard answer] power plant electrical part
[combinatorics] recursive equation (example of solving recursive equation without multiple roots | complete process of solving recursive equation without multiple roots)
Prepare for the golden three silver four, 100+ software test interview questions (function / interface / Automation) interview questions. win victory the moment one raises one 's standard
[combinatorics] recursive equation (the relationship theorem between the solution of the recursive equation and the characteristic root | the linear property theorem of the solution of the recursive e
Swm32 series Tutorial 4 port mapping and serial port application
跨境电商:外贸企业做海外社媒营销的优势
[combinatorics] recursive equation (solution of linear non-homogeneous recursive equation with constant coefficients | standard form and general solution of recursive equation | proof of general solut
Squid 服务启动脚本
Unity notes unityxr simple to use