%Testing the use of structure array
%For more information on structure arrays, select
%Help > MATLAB Help > Programming > Data Types >
%     Structures
numels = 2;
R = 2*eye(3); %Dummy R
for iele = 1:numels
    eps_val = iele*[2e-4 7e-6 2e-4]; %Dummy values
    sig_val = (R*eps_val')';
    geps_val(iele,:) = eps_val; 
    gsig_val(iele,:) = sig_val; 
end
sigepsstruct = struct('eps', geps_val, ...   
                      'sig', gsig_val)

%Extract data from structure
myeps = sigepsstruct.eps
sigxy2 = sigepsstruct.sig(2,3)
fieldnames(sigepsstruct)
