


GETB_ADVEC - compute the B matrix for advection in thermal model
Compute B matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size numgrids*NDOF
For grid i, Bi can be expressed in the basic coordinate system by :
Bi_basic=[Li]
[Li]
[Li]
where h is the interpolation function for grid i.
Usage:
B=GetB_advec(pentaelem,gauss_coord)
See also GETB_CONDUCT, GETBPRIME_ADVEC, CREATEKMATRIX

0001 function B=GetB_advec(pentaelem,gauss_coord) 0002 %GETB_ADVEC - compute the B matrix for advection in thermal model 0003 % 0004 % Compute B matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size numgrids*NDOF 0005 % For grid i, Bi can be expressed in the basic coordinate system by : 0006 % Bi_basic=[Li] 0007 % [Li] 0008 % [Li] 0009 % where h is the interpolation function for grid i. 0010 % 0011 % Usage: 0012 % B=GetB_advec(pentaelem,gauss_coord) 0013 % 0014 % See also GETB_CONDUCT, GETBPRIME_ADVEC, CREATEKMATRIX 0015 0016 num_grids=6; 0017 0018 l1l6=GetNodalFunctions(pentaelem,gauss_coord); 0019 0020 %Build B: 0021 B=zeros(3,num_grids); 0022 0023 for i=1:num_grids, 0024 B(1,i)=l1l6(i); 0025 B(2,i)=l1l6(i); 0026 B(3,i)=l1l6(i); 0027 end