How can I make this Matlab program possible?

Posted by lebland-matlab on Stack Overflow See other posts from Stack Overflow or by lebland-matlab
Published on 2010-04-10T10:46:11Z Indexed on 2010/04/10 10:53 UTC
Read the original article Hit count: 448

Filed under:
|

I do not know how to combine the indices with the characters, Could you help me to make this program possible:

clc;
clear all;

set1={F,G,FF,GG,X,Y,XX,L,BH,JK}; %set of name vectors
set2={J,K,HG,UY,TR,BC,XW,IOP,ES,QA}; %set of name vectors
set3={AJ,RK,DS,TU,WS,ZZE,ZXW,TYP,ZAA,QWW}; %set of name vectors

for i=1:1:9

    load('C:\Users\Documents\MATLAB\myFile\matrice_'set1(i)'.mat');    
    load('C:\Users\Documents\MATLAB\myFile\matrice_'set1(i+1)'.mat');   

    'set1(i)' = m_'set1(i)';     
    'set1(i+1)' = m_'set1(i+1)';     

for j=1:1:9   

    load('C:\Users\Documents\MATLAB\myFile\matrice_'set2(j)'.mat');     
    load('C:\Users\Documents\MATLAB\myFile\matrice_'set2(j+1)'.mat');  

    'set2(j)' = m_'set2(j)';     
    'set2(j+1)' = m_'set2(j+1)';   

    for k=1:1:8   

        load('C:\Users\Documents\MATLAB\myFile\matrice_'set3(k)'.mat');       
        load('C:\Users\Documents\MATLAB\myFile\matrice_'set3(k+1)'.mat');      
        load('C:\Users\Documents\MATLAB\myFile\matrice_'set3(k+2)'.mat');        

        'set3(k)' = m_'set3(k)' ;      
        'set3(k+1)' = m_'set3(k+1)';     
        'set3(k+2)' = m_'set3(k+2)';      

[Result1'index',Result2'index',Result3'index',Result4'index',Result5'index'] = myFun('set1(i)','set1(i+1)','set2(j)','set2(j+1)','set3(k)','set3(k+1)','set3(k+2)');  %% 9x9x8=648   index=1,2,...,648      

file_name = 'matrice_final'index'.mat';      
save(file_name,'Result1'index'','Result2'index'','Result3'index'','Result4'index'','Result5'index'');        
    clear 'set3(k)' 'set3(k+1)' 'set3(k+2)'   
    end   
clear 'set2(j)' 'set2(j+1)'   
end   
clear 'set1(i)' 'set1(i+1)'

end

© Stack Overflow or respective owner

Related posts about matlab

Related posts about loops