资源描述:
《单线圈的Matlab仿真与建模》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、view(0,0)view(0,90)view(90,0)functionhmhs[x,y]=meshgrid(0:0.03:4,-2:0.03:2);z=y+0.5;R=1;Bx=-2.*(x.^2.*mfun('EllipticK',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2)))-(x.^2).*mfun('EllipticE',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2)))-2.*R.*mfun('EllipticK',(2.*(R.*x./(R.^2+x.^2+z.
2、^2+2.*R.*x)).^(1/2))).*x+mfun('EllipticK',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2))).*(z.^2)-R.^2.*mfun('EllipticE',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2)))+mfun('EllipticK',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2))).*(R.^2)-mfun('EllipticE',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*
3、R.*x)).^(1/2))).*(z.^2)).*((R.^2+x.^2+z.^2-2.*R.*x)./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2).*z./(R.^2+x.^2+z.^2-2.*R.*x).^(3/2)./x;Bz=2.*(x.^2.*mfun('EllipticK',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2)))-(x.^2).*mfun('EllipticE',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2)))-2.*R.*mfun(
4、'EllipticK',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2))).*x+mfun('EllipticK',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2))).*(R.^2)+mfun('EllipticK',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2))).*(z.^2)-mfun('EllipticE',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2))).*(z.^2)+R.^2.*mfu
5、n('EllipticE',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2)))).*((R.^2+x.^2+z.^2-2.*R.*x)./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2)./(R.^2+x.^2+z.^2-2.*R.*x).^(3/2);%surf(x,z,Bz);B1=sqrt(Bx.^2+Bz.^2);z=y-0.5;Bx=-2.*(x.^2.*mfun('EllipticK',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2)))-(x.^2).*
6、mfun('EllipticE',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2)))-2.*R.*mfun('EllipticK',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2))).*x+mfun('EllipticK',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2))).*(z.^2)-R.^2.*mfun('EllipticE',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2)))+mfun('El
7、lipticK',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2))).*(R.^2)-mfun('EllipticE',(2.*(R.*x./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2))).*(z.^2)).*((R.^2+x.^2+z.^2-2.*R.*x)./(R.^2+x.^2+z.^2+2.*R.*x)).^(1/2).*z./(R.^2+x.^2+z.^2-2.*R.*x).^(3/2)./x;Bz=2.*(x.^2.*mfun('EllipticK',(2.*(R.*x./(R.^2+x
8、.^2+z.^2+2.*R.*x)).