You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: dcmBaFromAeroAngles.m
    path of file: ./repos/LADAC/utilities/axes_transformation
    
    the code of the file until where you have to start completion: % dcmBaFromAeroAngles compute direction cosine matrix (DCM) from aerodynamic
% angles alpha and beta
%   The DCM (or rotation matrix) is used to transform a vector given in one
%   frame to another frame by multip
    
function M_ba = dcmBaFromAeroAngles( alpha, beta ) %#codegen

% detect length of input
len_alpha = length(alpha);
% initialize output
M_ba = zeros(3,3,len_alpha);

% for all angles of attack (and sideslip angles)
for i = 1:len_alpha
    
    % compute sine and cosine of alpha and beta (multiple use)
    sin_al = sin(alpha(i));
    cos_al = cos(alpha(i));
    sin_be = sin(beta(i));
    cos_be = cos(beta(i));
    
    % compute the DCM according to [1, page 77] (note that M_ba = M_ab')
    M_ba(:,:,i) = [cos_al*cos_be, -cos_al*sin_be, -sin_al; ...
        sin_be, cos_be, 0; ...
        sin_al*cos_be, -sin_al*sin_be, cos_al ]; 
    
end