Mentions légales du service

Skip to content
Snippets Groups Projects
Commit 743fe5d7 authored by hhakim's avatar hhakim
Browse files

Rename matlab wrapper Faust.get_fact() to Faust.get_factor().

parent 25149d10
No related branches found
No related tags found
No related merge requests found
......@@ -64,7 +64,7 @@ classdef FaustTest < matlab.unittest.TestCase
save(this.test_faust, filepath)
F = Faust(filepath)
for i = 1:get_num_factors(F)
this.verifyEqual(get_fact(this.test_faust,i), get_fact(F,i))
this.verifyEqual(get_factor(this.test_faust,i), get_factor(F,i))
end
delete(filepath)
end
......@@ -78,7 +78,7 @@ classdef FaustTest < matlab.unittest.TestCase
faust_factors=cell(1,nb_fact);
for i=1:nb_fact
faust_factors{i}=get_fact(this.test_faust,i);
faust_factors{i}=get_factor(this.test_faust,i);
end
save(filepath_ref,'faust_factors');
save(this.test_faust,filepath_test)
......@@ -86,7 +86,7 @@ classdef FaustTest < matlab.unittest.TestCase
test_F = Faust(filepath_test)
this.verifyEqual(get_num_factors(ref_F), get_num_factors(test_F))
for i = 1:get_num_factors(ref_F)
this.verifyEqual(get_fact(ref_F,i), get_fact(test_F,i))
this.verifyEqual(get_factor(ref_F,i), get_factor(test_F,i))
end
delete(filepath_ref)
......@@ -106,7 +106,7 @@ classdef FaustTest < matlab.unittest.TestCase
function testGetFactorAndConstructor(this)
disp('testGetFactorAndConstructor()')
for i = 1:this.num_factors
this.verifyEqual(get_fact(this.test_faust, i), full(this.factors{i}))
this.verifyEqual(get_factor(this.test_faust, i), full(this.factors{i}))
end
end
......
......@@ -575,9 +575,9 @@ if (nb_fact_load ~= nb_fact)
end
for i=1:nb_fact
A=get_fact(F_loaded,i);
A=get_factor(F_loaded,i);
if(~isequal(A,factors{i}))
get_fact(F,i)
get_factor(F,i)
error('get_fact : invalid factor');
end
......@@ -613,10 +613,10 @@ end
disp('Ok');
%% get_fact test
%% get_factor test
disp('TEST GET_FACT : ');
for i=1:nb_fact
A=get_fact(F,i);
A=get_factor(F,i);
if(A~=factors{i})
error('get_fact : invalid factor');
end
......@@ -720,11 +720,11 @@ if ( ~isequal(expected_F_conj_full,F_conj_full) )
F_conj_full
error(['conj test 1 failed.']);
end
% test get_fact on conj
% test get_factor on conj
for i=1:nb_fact
A=get_fact(F_conj,i);
A=get_factor(F_conj,i);
if(~isequal(A,conj(factors{i})))
get_fact(F_conj,i)
get_factor(F_conj,i)
error('get_fact : invalid factor');
end
end
......@@ -760,11 +760,11 @@ if ( ~isequal(expected_F_ctranspose_full,F_ctranspose_full) )
F_ctranspose_full
error(['ctranspose test 1 failed.']);
end
% test get_fact on ctranspose
% test get_factor on ctranspose
for i=1:nb_fact
A=get_fact(F_ctranspose,i)
A=get_factor(F_ctranspose,i)
if(~isequal(A,ctranspose(factors{nb_fact-i+1})))
get_fact(F_ctranspose,i)
get_factor(F_ctranspose,i)
error('get_fact : invalid factor');
end
end
......
......@@ -416,7 +416,7 @@ classdef Faust
%> <br/> If F is a real Faust then F_conj == F.
%> <br/> if F is a complex Faust, the Faust object F_conj returned verifies the next assertion for all i=1:get_num_factors(F):
%> @code
%> conj(get_fact(F,i)) == get_fact(F_conj,i)
%> conj(get_factor(F,i)) == get_factor(F_conj,i)
%> @endcode
%>
%> @b Example
......@@ -425,7 +425,7 @@ classdef Faust
%> F_conj = conj(F)
%> @endcode
%>
%> <p/>@b See @b also Faust.get_fact, Faust.get_num_factors, Faust.ctranspose
%> <p/>@b See @b also Faust.get_factor, Faust.get_num_factors, Faust.ctranspose
%>
%======================================================================
function F_conj=conj(F)
......@@ -594,18 +594,18 @@ classdef Faust
%> @b Example
%> @code
%> F = Faust.rand(Faust.MIXTE, Faust.COMPLEX, 2, 5, 50, 100, .5)
%> f1 = get_fact(F,1)
%> f1 = get_factor(F,1)
%> @endcode
%> <p>@b See @b also Faust.get_num_factors
%=====================================================================
function factor = get_fact(F,i)
function factor = get_factor(F,i)
%% GET_FACT Ith factor of the Faust.
%
% A=get_fact(F,i) return the i factor A of the Faust F as a full storage matrix.
% A=get_factor(F,i) return the i factor A of the Faust F as a full storage matrix.
%
% Example of use :
% A=get_fact(F,1) returns the 1st factor of the Faust F.
% A=get_fact(F,4) returns the 4th factor of the Faust F.
% A=get_factor(F,1) returns the 1st factor of the Faust F.
% A=get_factor(F,4) returns the 4th factor of the Faust F.
%
% See also get_num_factors.
......@@ -639,7 +639,7 @@ classdef Faust
%> nf = get_num_factors(F)
%> @endcode
%>
%> <p>@b See @b also Faust.get_fact.
%> <p>@b See @b also Faust.get_factor.
%==========================================================================================
function num_factors = get_num_factors(F)
%% GET_NB_FACTOR Number of factor of the Faust.
......@@ -647,7 +647,7 @@ classdef Faust
% num_factors = get_num_factors(F) return the number of factor of the
% Faust F.
%
% See also get_fact.
% See also get_factor.
if (F.isReal)
num_factors = mexFaustReal('get_nb_factor', F.matrix.objectHandle);
else
......@@ -843,7 +843,7 @@ classdef Faust
%>
%> @endcode
%>
%> <p>@b See @b also Faust.nnz_sum, Faust.rcg, Faust.size, Faust.get_fact
%> <p>@b See @b also Faust.nnz_sum, Faust.rcg, Faust.size, Faust.get_factor
%>
%>
%======================================================================
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment