Documentation

wfusmat

Fusion of two matrices or arrays

Syntax

C = wfusmat(A,B,METHOD)

Description

C = wfusmat(A,B,METHOD) returns the fused matrix C obtained from the matrices A and B using the fusion method defined by METHOD.

The matrices A and B must be of the same size. The output matrix C is of the same size as A and B.

Available fusion methods are

• Simple, where METHOD is

• 'max' : D = abs(A) abs(B) ; C = A(D) + B(~D)

• 'min' : D = abs(A) abs(B) ; C = A(D) + B(~D)

• 'mean' : C = (A+B) / 2 ; D = ones(size(A))

• 'rand' : C = A(D) + B(~D); D is a Boolean random matrix

• 'img1' : C = A

• 'img2' : C = B

• Parameter-dependent, where METHOD is of the following form:

METHOD = struct('name',nameMETH,'param',paramMETH)

where nameMETH can be

• 'linear' : C = A*paramMETH + B*(1-paramMETH),

where 0paramMETH1

• 'UD_fusion': Up-down fusion, with paramMETH ≥ 0

x = linspace(0,1,size(A,1));
P = x.^paramMETH;

Then each row of C is computed with

C(i,:) = A(i,:)*(1-P(i)) + B(i,:)*P(i);
So C(1,:) = A(1,:) and C(end,:) = B(end,:)

• 'DU_fusion': Down-up fusion

• 'LR_fusion': Left-right fusion (column-wise fusion)

• 'RL_fusion': Right-left fusion (column-wise fusion)

• 'UserDEF': User-defined fusion, paramMETH is a character vector or string scalar 'userFUNCTION' containing a function name such that C = userFUNCTION(A,B).

In addition, [C,D] = wfusmat(A,B,METHOD) returns the Boolean matrix D when defined, or an empty matrix otherwise.

Introduced before R2006a

Wavelet Toolbox Documentation Get trial now