Skip to content

Commit 438eebd

Browse files
committed
stick with previous way and comment the alternative for future use
1 parent 3f7e7d5 commit 438eebd

File tree

1 file changed

+13
-11
lines changed

1 file changed

+13
-11
lines changed

src/LP-NGWP.jl

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -230,17 +230,19 @@ end
230230

231231
function const_meyer_wavelets(𝚽, Uf; idx = 1:size(Uf, 1))
232232
N = size(𝚽, 1)
233-
# # assemble smooth orthogonal projector custom to nodes `idx`
234-
# P = Uf[idx, :]' * Uf[idx, idx]
235-
# if diag(P) == χ(idx, N)
236-
# B = 𝚽[:, idx]
237-
# else
238-
# # folding the eigenspace, i.e., 𝚽's column space
239-
# Y = 𝚽 * P
240-
# # find its column space's orthogonal basis
241-
# B = svd(Y).U
242-
# end
243-
B = 𝚽 * Uf[:, idx]
233+
# 1. nice interpretable way by smooth orthogonal projector
234+
# assemble smooth orthogonal projector custom to nodes `idx`
235+
P = Uf[idx, :]' * Uf[idx, idx]
236+
if diag(P) == χ(idx, N)
237+
B = 𝚽[:, idx]
238+
else
239+
# folding the eigenspace, i.e., 𝚽's column space
240+
Y = 𝚽 * P
241+
# find its column space's orthogonal basis
242+
B = svd(Y).U
243+
end
244+
# 2. alternative faster way by orthogonal unfolding operator
245+
# B = 𝚽[:, idx] * Uf[idx, idx]
244246
# perform varimax rotation to get the meyer_wavelets
245247
Wavelets = varimax(B)
246248
return Wavelets

0 commit comments

Comments
 (0)