亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? gmfem.m

?? matlab有限元分析工具,比經較全面的一個手冊,請大家下載呀
?? M
字號:
function u = gmfem(brep, mesh, conduct, source, userdata);%   u = gmfem(brep, mesh {, conduct { , source { , userdata}}});% This function solves the boundary value problem%    div (c grad u) = -f% The arguments are: %   brep: the domain on which the bvp is specified.%   mesh: a mesh of the domain, generated by gmmeshgen.%     Quadratic elements not supported; all elements interpreted%     as linear.%   conduct: A function that computes conductivity of the domain.  %      Overridden by the region's conductivity property.  Default is 1.%   source: A function that returns f, the source term.  Overridden by%     the regions's source property. Default is 0.%  Return value u is a vector of nodal values of the solution.  It%  is a zba.if nargin < 2  error('gmfem must have at least two arguments');endif nargin < 3  conduct = '(const 1.0)';endif nargin < 4  source = '(const 0.0)';endif nargin < 5   userdata = '';end%% This routine solves the finite element problem using%% the default ordering (min degree).if ~isa(brep,'zba')  error('First argument passed to gmfem not a zba');endif length(brep) < 1  error('First argument passed to gmfem not a brep');endglobal GM_BREP_TYPE_CODEtypecode = double(brep{0});if ~strcmpi(typecode, GM_BREP_TYPE_CODE)  error('First argument passed to gmfem not a brep');endif ~isa(mesh,'zba')  error('Second argument passed to gmfem not a zba');endif length(mesh) < 1  error('Second argument passed to gmfem not a mesh');endglobal GM_SIMPCOMP_TYPE_CODEtypecode = double(mesh{0});if ~strcmpi(typecode, GM_SIMPCOMP_TYPE_CODE)  error('Second argument passed to gmfem not a mesh');endglobal GM_GEO_ID_PROP;if ~strcmpi(gm_lookup_objprop(brep, GM_GEO_ID_PROP), ...            gm_lookup_objprop(mesh, GM_GEO_ID_PROP))  error('Brep-id code of mesh does not match with brep');enddi = double(brep{2});if di ~= 2 & di ~= 3  error('Only dims 2 and 3 supported.')endif brep{1} ~= di  error('Brep must be full dimensional.')end if mesh{2} ~= di  error('Dimension mismatch between mesh and brep')endif mesh{1} ~= di  error('Mesh must be full dimensional')end[scrap,numvtx] = size(mesh{4});[scrap,numtoplev] = size(mesh{5+di});[scrap,numtoplev2] = size(brep{5+di});if numtoplev ~= numtoplev2  error('Number of regions disagree between mesh and brep');end[scrap,numfacet] = size(mesh{4+di});[scrap,numfacet2] = size(brep{4+di});if numfacet ~= numfacet2  error('Number of facets disagree between mesh and brep');endnumtri = 0;tri = zba([]);for faceind = 0 : numtoplev - 1  [scrap, numtri1] = size(mesh{5+di}{1,faceind});  tri = [tri;mesh{5+di}{1,faceind}'];    numtri = numtri + numtri1;end[scrap,numtri] = size(mesh{5});[scrap,numtoplev] = size(brep{5+di});% Evaluate the conductivity and source.  Loop over top-level% faces of the brep and find the conductivity and source for each.con = zba(-ones(numtri,1));sourceterm = zba(zeros(numvtx,1));vtx_global_to_ordinal = ...   sparse((double(mesh{4}(0,:)))'+1,ones(numvtx,1), (0:numvtx-1)');vtx = mesh{4}(1:di,:)';tri = zba(full(vtx_global_to_ordinal(double(tri)+1)));pos = 0;for fa = 0 : numtoplev - 1  conduct1 = gm_lookup_prop(brep, di, fa, 'conductivity');  if length(conduct1) == 0    conduct1 = conduct;  end  facename = double(brep{5+di}{0,fa});  disp(sprintf('Conductivity on face %s is %s', facename, conduct1))  source1 = gm_lookup_prop(brep, di, fa, 'source');  if length(source1) == 0    source1 = source;  end  disp(sprintf('Source on face %s is %s', facename, source1))%  Evaluate conductivity at the midpoints of the mesh elements% (one-point integration).% tri1 has the vertices of the triangles in% the current toplev face, converted to ordinal numbering.  tri1 = full(vtx_global_to_ordinal(double(mesh{5+di}{1,fa})+1))';  [numtri1,scrap] = size(tri1);  if di == 2    midpoints = (vtx(tri1(:,1),:) + vtx(tri1(:,2),:) + ...                 vtx(tri1(:,3),:)) / 3;  else    midpoints = (vtx(tri1(:,1),:) + vtx(tri1(:,2),:) + ...                 vtx(tri1(:,3),:) + vtx(tri1(:,4),:)) / 4;  end  con1 = gm_conductivity(conduct1, userdata, midpoints);  [m,n] = size(con1);  if m ~= numtri1 | n ~= 1    error('Conductivity call returned a vector of the wrong size.')  end  if any(con1 <= 0)     error('Conductivity routine returned nonpositive conductivity');  end  con(pos:pos+numtri1 - 1) = con1;   sourceterm1 = gm_source(source1, userdata, midpoints);  [m,n] = size(sourceterm1);  if m ~= numtri1 | n ~= 1    error('Source-term call returned a vector of the wrong size.');  end  sourceterm(pos:pos+numtri1 - 1) = sourceterm1;  pos = pos + numtri1;endif any(con <= 0)  error('Some conductivities were not evaluated');end% Set up dirichlet and Neuman BC's.dirval = zba(zeros(numvtx,1));isdir = zba(zeros(numvtx,1));dircount = zba(zeros(numvtx,1));neusum = zba(zeros(numvtx,1));% Loop over faces of dimension di-1 and find out% their boundary values.for fa = 0 : numfacet - 1  bc = gm_strim(gm_lookup_prop(brep, di - 1, fa, 'bc'));  if length(bc) == 0    btype = 'n';    bfunc = '(const 0.0)';  else    %parse the boundary specification.    if bc(1) ~= '(' | bc(end) ~= ')'      error('Boundary condition must be an ordered pair (type func)');    end    bc = gm_strim(bc(2:length(bc)-1));    [btype,bfunc] = strtok(bc);    btype = lower(btype(1));    if btype ~= 'n' & btype ~= 'd'      error('Bc type must be either d or n');    end    bfunc = gm_strim(bfunc);    if length(bfunc) == 0      error('No boundary condition function specified')    end  end  facename = double(brep{4+di}{0,fa});  disp(sprintf('facet %s btype = %s bfunc = %s', ...	facename, btype, bfunc))  % Get the facets lying on this face, converted to  % ordinal indices.  facetlist = ...    zba(full(vtx_global_to_ordinal(double(mesh{4+di}{1,fa})+1))');  [numfacet1, scrap] = size(facetlist);    % String together the vertices of these facets and  % deduplicate for dirichlet bc.  vtxselect = sparse([],[],[],numvtx,1);  vtxselect(double(facetlist(:)) + 1) = ones(numfacet1 * di, 1);  vtxlist = find(vtxselect) - 1;  vtx1 = vtx(vtxlist,:);  [numvtx1, scrap] = size(vtx1);  if numvtx1 == 0    disp(sprintf('Warning: no vertices on facet %d:%d  %s', ...        di-1, fa, brep{4+di}{0,fa}))  else    bcval = gm_bdrycond(bfunc, userdata, vtx1);	    [m,n] = size(bcval);    if m ~= numvtx1 | n ~= 1      error('Bfunc return value is the wrong size');    end    if btype == 'd'      dirval(vtxlist) = dirval(vtxlist) + bcval;      dircount(vtxlist) = dircount(vtxlist) + ones(numvtx1,1);      isdir(vtxlist) = ones(numvtx1,1);    else      neusum  = neusum + gm_neumann(vtx, facetlist, bcval);    end  endend%% dirval holds the sums of the dirichlet boundary values;%% divide by dircount to make them average dirichlet values.dirval(find(isdir)) = dirval(find(isdir)) ./ dircount(find(isdir));%% At least one dirichlet node per connected component to make%% system nonsingular.compo_label = gm_mcompo(mesh);numcompo = max(double(compo_label)) + 1;for componum = 0 : numcompo - 1  if all(isdir(compo_label == componum) == 0)    disp(sprintf('Note: all vertices of component %d have Neumann condition',...          componum));    disp(sprintf('Boundary integral of Neumann data = %e',...       sum(neusum(compo_label == componum))));    disp('(Should be close to zero)');    ff = find(compo_label == componum);    if length(ff) > 0      disp(sprintf('Changing node %d to Dirichlet condition to make the problem well-posed', ff(1)));      isdir(ff(0)) = 1;      dirval(ff(0)) = 0;    end  endend  % Assemble the fe matrix and solve it.[K,f0] = gm_assemble(vtx, tri, isdir, dirval, con);neusum1 = neusum(isdir == 0);sourceterm1 = sourceterm(isdir == 0);f = f0 + neusum1 + sourceterm1;[m,n] = size(K);disp(sprintf('Assembled K is %d-by-%d and contains %d nonzero entries',... m,n,nnz(K)));startflops = flops;u0 = K \ f;endflops = flops;disp(sprintf('%d flops to solve linear system', endflops-startflops))% u0 has a value for all non-dirichlet boundary nodes.% Insert dirichlet nodes.u = zba(zeros(numvtx,1));u(find(isdir == 0)) = u0;u(find(isdir == 1)) = dirval(isdir == 1);% ------------------------------------------------------------------% Copyright (c) 1999 by Cornell University.  All rights reserved.% See the accompanying file 'Copyright' for authorship information,% the terms of the license governing this software, and disclaimers% concerning this software.% ------------------------------------------------------------------% This file is part of the QMG software.  % Version 2.0 of QMG, release date September 3, 1999% ------------------------------------------------------------------

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产精品自拍毛片| 成人免费小视频| 久久 天天综合| 精品成人a区在线观看| 久久草av在线| 国产精品视频观看| 欧美午夜电影在线播放| 日韩高清一级片| 精品国产一区二区三区忘忧草 | 亚洲美女视频一区| 欧洲亚洲国产日韩| 热久久一区二区| 国产婷婷色一区二区三区四区| k8久久久一区二区三区| 亚洲国产一区二区三区青草影视 | 日韩三区在线观看| 国产成人午夜精品5599| 亚洲卡通动漫在线| 日韩一级欧美一级| 99久久777色| 日本欧美一区二区三区| 国产精品视频九色porn| 欧美男女性生活在线直播观看| 韩国一区二区三区| 亚洲韩国精品一区| 久久精品视频免费观看| 91高清视频在线| 国产一区二区在线视频| 亚洲午夜日本在线观看| xfplay精品久久| 欧美日韩国产另类不卡| 丰满岳乱妇一区二区三区 | 精品一区二区成人精品| 亚洲天堂网中文字| 2023国产精品| 欧美日韩一区高清| 波多野结衣亚洲| 免费一级片91| 一区二区国产盗摄色噜噜| 久久精子c满五个校花| 3atv一区二区三区| 一本到三区不卡视频| 国产精品18久久久久久久久| 日本特黄久久久高潮| 一区二区三区不卡视频在线观看| 久久精品视频网| 日韩久久久精品| 色综合久久久久久久久久久| 久久电影网站中文字幕| 亚洲成av人**亚洲成av**| 中文字幕不卡在线播放| www国产成人| 精品久久人人做人人爽| 91精品久久久久久久99蜜桃| 欧美性生活久久| 91捆绑美女网站| 成人一级片网址| 国产成人在线观看免费网站| 久久国产夜色精品鲁鲁99| 亚洲成年人网站在线观看| 亚洲精品v日韩精品| 中文字幕一区在线观看| 国产精品天干天干在线综合| 久久亚洲欧美国产精品乐播| 日韩一区二区精品| 亚洲人妖av一区二区| 亚洲国产精品精华液2区45| 久久综合久久久久88| 欧美一激情一区二区三区| 7777精品久久久大香线蕉| 欧美老年两性高潮| 欧美日韩一区久久| 欧美精品乱码久久久久久| 欧美日韩卡一卡二| 91精品国产一区二区人妖| 欧美老女人在线| 日韩午夜在线影院| 日韩欧美久久一区| 精品国产一区二区三区av性色| 欧美mv日韩mv亚洲| 久久久久国产精品厨房| 欧美国产一区在线| 亚洲视频一区二区在线| 亚洲男女毛片无遮挡| 一区二区三区久久| 丝袜a∨在线一区二区三区不卡| 日本麻豆一区二区三区视频| 免费成人你懂的| 国产一区二区免费在线| 福利一区二区在线| 99re66热这里只有精品3直播| 91久久线看在观草草青青| 欧美人妇做爰xxxⅹ性高电影| 91精品国产综合久久福利软件| 日韩天堂在线观看| 国产亚洲美州欧州综合国| 国产精品国模大尺度视频| 亚洲一区二区精品久久av| 琪琪久久久久日韩精品| 久久国产精品色婷婷| 岛国精品在线播放| 91传媒视频在线播放| 日韩午夜激情视频| 日本一区二区三级电影在线观看 | 日韩一级视频免费观看在线| 久久久久国产精品免费免费搜索| 国产精品久久午夜| 欧洲色大大久久| av中文字幕一区| 欧美精品亚洲一区二区在线播放| 欧美一激情一区二区三区| 亚洲国产精品av| 亚洲高清视频的网址| 国产精品一二三在| 久久精品夜色噜噜亚洲a∨| 国产精品久久久久aaaa樱花| 亚洲永久免费视频| 国产精品白丝jk黑袜喷水| 91黄视频在线观看| 欧美精品一区视频| 亚洲黄色片在线观看| 国产美女av一区二区三区| 欧美在线观看视频在线| 国产亚洲欧美在线| 无码av免费一区二区三区试看| 国产一区二区不卡在线| 欧美亚洲图片小说| 国产精品三级av在线播放| 午夜久久久影院| av一区二区三区| 久久精品人人做人人综合| 亚洲a一区二区| 91尤物视频在线观看| 久久精品亚洲精品国产欧美 | 夜夜精品浪潮av一区二区三区| 精品一区二区三区在线观看国产| 一本一道波多野结衣一区二区| 精品国产3级a| 亚洲电影一级片| 91在线观看成人| 亚洲国产精品精华液ab| 黄色资源网久久资源365| 91精品国产麻豆国产自产在线 | 日韩一区二区精品| 一区二区三区色| 不卡视频一二三四| 久久久精品人体av艺术| 久久爱www久久做| 欧美一区二区在线不卡| 亚洲一区二区视频| 一本大道久久a久久综合婷婷| 中文字幕第一区二区| 国产成人在线影院| 精品国产亚洲在线| 久久99国产精品麻豆| 日韩精品一区二区三区在线观看 | 一区二区三区在线视频观看58| 国产91色综合久久免费分享| 精品国产露脸精彩对白| 久久精品国产精品亚洲综合| 欧美一区二区国产| 日韩国产欧美三级| 欧美一级爆毛片| 精品亚洲porn| 久久九九全国免费| 东方欧美亚洲色图在线| 国产精品丝袜一区| 波波电影院一区二区三区| 国产精品第一页第二页第三页| av动漫一区二区| 中文字幕在线一区免费| 91在线精品一区二区三区| 国产一区二区三区免费| wwwwxxxxx欧美| 国产成人免费在线观看| 中文无字幕一区二区三区| eeuss鲁片一区二区三区在线观看| 中文字幕一区视频| 91福利精品视频| 日本最新不卡在线| 久久婷婷一区二区三区| 成人亚洲精品久久久久软件| 亚洲免费成人av| 欧美日韩在线观看一区二区| 免费观看30秒视频久久| 国产校园另类小说区| 波多野结衣一区二区三区| 夜夜嗨av一区二区三区四季av | 国产精品99久久久久久久vr| 国产精品美女久久福利网站| 色婷婷亚洲综合| 日本不卡一二三| 中文字幕va一区二区三区| 一本一道久久a久久精品| 琪琪久久久久日韩精品| 中文字幕欧美区| 夜夜揉揉日日人人青青一国产精品 | 日韩一区二区三区免费看| 精品亚洲欧美一区| 中文字幕精品综合|