subroutine get_jcob(detj,jcob,jinv,pn,co_xn)implicit none
real(8)::co_xn(nnd_e,dimens),detj
real(8)::jcob(dimens,dimens),jinv(dimens,dimens),pn(nnd_e,dimens)
integer::i,j,k
jcob=0.0;jinv=0.0
if(dimens==2) then
do i=1,nnd_e
jinv(1,1)=jinv(1,1)+pn(i,2)*co_xn(i,2)
jinv(1,2)=jinv(1,2)-pn(i,1)*co_xn(i,2)
jinv(2,1)=jinv(2,1)-pn(i,2)*co_xn(i,1)
jinv(2,2)=jinv(2,2)+pn(i,1)*co_xn(i,1)
end do
detj=jinv(1,1)*jinv(2,2)-jinv(1,2)*jinv(2,1)
欢迎光临 Fortran Coder (http://bbs.fcode.cn/) | Powered by Discuz! X3.2 |