21.01.2015 Views

COMSOL Multiphysics™

COMSOL Multiphysics™

COMSOL Multiphysics™

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

elsconstr<br />

vector. The normal component of this vector is constrained to be zero in the node<br />

points for the shdiv shape function.<br />

Example<br />

Impose a constraint on a vector field E represented using shcurl shape functions of<br />

order 2. The constraint is that the tangential component of E-(2,3) is zero.<br />

clear fem;<br />

fem.geom = circ2;<br />

fem.mesh = meshinit(fem);<br />

fem.shape = 'shcurl(2,''E'')';<br />

fem.dim = {'EX' 'Ey'};<br />

fem.equ.weak = '-(Ex*Ex_test+Ey*Ey_test+dExy_test*dExy)';<br />

clear el gd;<br />

el.elem = 'elsconstr';<br />

el.g = {'1'};<br />

gd.ind = {{'1','2','3','4'}};<br />

gd.shelem{1}{1} = ...<br />

{'s(1)','shcurl',struct('fieldname','E','order','2')};<br />

gd.constr{1}{1} = {'Ex-2','Ey-3'};<br />

gd.cshape{1}{1} = '1';<br />

el.geomdim{1} = {{},gd,{}};<br />

fem.elem = {el};<br />

fem.xmesh = meshextend(fem);<br />

fem.sol = femstatic(fem);<br />

postarrow(fem,{'Ex' 'Ey'});<br />

See Also<br />

elempty, elpconstr, elshape, shdiv, shlag, shcurl<br />

105

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!