Skip to content

Commit 9a33bdd

Browse files
committed
Added pdde_stability native
1 parent ef37e66 commit 9a33bdd

File tree

3 files changed

+32
-2
lines changed

3 files changed

+32
-2
lines changed

src/Gallery.jl

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,6 +162,11 @@ The following list describes the NEP with a certain `name` and the associated pa
162162
and\\
163163
X. Huang, Z. Bai, and Y. Su, Nonlinear rank-one modification of the symmetric eigenvalue problem. J. Comput. Math. 28, 2, 218–234, 2010
164164
165+
166+
* `nlevp_native_hadeler`\\
167+
The benchmark problem from the NLEVP-collection called "hadeler", represented in the native NEP-PACK format. The problem is of the form ``M(λ)=(e^λ-1)B+A0+A2λ^2``. \\
168+
Hadeler K. P. 1967. Mehrparametrige und nichtlineare Eigenwertaufgaben. Arch. Rational Mech. Anal. 27, 4, 306–328.\\
169+
165170
* `nlevp_native_pdde_stability`\\
166171
The benchmark problem from the NLEVP-collection called "pdde_stability", represented in the native NEP-PACK format.
167172
This problem is a quadratic eigenvalue with arbitrary given size `n`. See
@@ -211,9 +216,10 @@ julia> norm(compute_Mlincomb(nep,1.0+1.0im,ones(size(nep,1))))
211216
"periodicdde" => (params...; kwargs...) -> periodic_dde_gallery(PeriodicDDE_NEP, params...; kwargs...),
212217
"neuron0" => neuron0,
213218
"nlevp_native_gun" => nlevp_native_gun,
219+
"nlevp_native_hadeler" => nlevp_native_hadeler,
214220
"nlevp_native_cd_player" => nlevp_native_cd_player,
215221
"nlevp_native_fiber" => nlevp_native_fiber,
216-
"nlevp_pdde_stability" => nlevp_native_pdde_stability,
222+
"nlevp_native_pdde_stability" => nlevp_native_pdde_stability,
217223
"beam" => beam,
218224
"sine" => sine_nep,
219225
)

src/gallery_extra/NLEVP_native.jl

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,23 @@ function newton_eval(coeffs,S,interp_points) # This works for λ::Number and λ
137137
end
138138

139139

140-
function pdde_stability(n=15)
140+
141+
function nlevp_native_hadeler=100,n=8)
142+
i=1:n
143+
I2 = ones(n)*i' # matrix with constant columns 1,2,3,4...n
144+
# Identity matrix
145+
II = Matrix{typeof(α)}(I,n,n);
146+
# Matrices
147+
A0= α*II
148+
A2 = n*II+1 ./(I2 + I2');
149+
B = ((n+1) .- max.(I2',I2)) .* (i*i');
150+
# Functions
151+
fv= [S->-one(S) ; S->S^2 ; S->(exp(S)-one(S))]
152+
nep=SPMF_NEP([A0, A2, B], fv);
153+
return nep
154+
end
155+
156+
function nlevp_native_pdde_stability(n=15)
141157

142158
# default values
143159
a0 = 2;
@@ -171,4 +187,5 @@ function pdde_stability(n=15)
171187
return PEP(Av)
172188

173189

190+
174191
end

test/gallery.jl

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,13 @@ using Test
144144
@test_throws MethodError nep_gallery("beam", 15, 8)
145145
@test_throws ErrorException nep_gallery("beam", 15, t=8)
146146

147+
148+
@info "Testing hadeler"
149+
nep=nep_gallery("nlevp_native_hadeler")
150+
A=compute_Mder(nep,3.0);
151+
@test isreal(A)
152+
153+
147154
@info "non-existing example"
148155
@test_throws ErrorException nep_gallery("non-existing example")
149156

0 commit comments

Comments
 (0)