sorting.m
来自「ABAQUS is a general purpose finite eleme」· M 代码 · 共 26 行
M
26 行
function [out_mat,r]=sorting(in_mat,x,a); %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% This function sorts the x coordintates because they are from ABAQUS% sorted after node numbers, now they will be sorted after distance% from cracktip - together with the result matrise (stress or strain)%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% [x_out,i]=sort(x); length_x=length(i); [n,m]=size(in_mat); for j=1:n out_mat(j,:)=in_mat(i(j),:); end if min(x)==0; x_out=turn(x_out); out_mat=turn(out_mat); r=1000-a-x_out; elseif max(x)==W; r=x_out-a; end;
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?