Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.

could not resolve subdomain relations

Please login with a confirmed email address before reporting spam

Hi everyone!
i have written this script and i think its right but it gives this error "could not resolve subdomain relations" and error in built-in function geomcsg
any idea where is this message coming from?


clear
clc

POS_Fix=zeros(4,3);

X_Fix=[0 5 0 -5]; Y_Fix=[5 0 -5 0]; Z_Fix=[10.5 11.83 13.17 14.5];
for i=1:4
POS_Fix(i,1)=X_Fix(i);
POS_Fix(i,2)=Y_Fix(i);
POS_Fix(i,3)=Z_Fix(i);
end


X_Var=[12,15,11,11,-12,-11,-7,6,-12,18,-24,25,0,-9,-6,20,-19,21,-14,12,-26,19,3,5,-4,-17,-15,16,19,1,22,-7,-2,7,18,4,-1,-14,2,13];
Y_Var=[18,10,-12,-10,-8,-6,-3,-10,0,6,11,9,20,-15,-4,-10,15,16,-2,7,10,18,-27,-9,-10,-16,-13,-2,6,15,-12,27,16,5,-8,-13,12,24,11,9];
Z_Var=[28,-49,-42,-37,-33,-29,-31,51,33,38,32,-43,38,-35,-41,52,-26,-34,44,-31,-40,-44,36,-42,36,-38,32,32,-50,48,49,29,34,27,-37,-44,41,-48,-44,-33];

POS_Var=zeros(40,3);
for i=1:40
POS_Var(i,1)=X_Var(i);
POS_Var(i,2)=Y_Var(i);
POS_Var(i,3)=Z_Var(i);
end


clear fem
fem.const={'Q1', 1.3e-19};
clear draw

mm=0; nn=5; pp=10.4;
g_fix=sphere3(0.1e0,'pos',[POS_Fix(1,1) POS_Fix(1,2) POS_Fix(1,3)]);%,'axis',[0 0 1],'rot',0);

gf1=sphere3(0.1e0,'pos',[POS_Fix(1,1) POS_Fix(1,2) POS_Fix(1,3)]);
gf2=sphere3(0.1e0,'pos',[POS_Fix(2,1) POS_Fix(2,2) POS_Fix(2,3)]);%,'axis',[0 0 1],'rot',0);
gf3=sphere3(0.1e0,'pos',[POS_Fix(3,1) POS_Fix(3,2) POS_Fix(3,3)]);%,'axis',[0 0 1],'rot',0);
gf4=sphere3(0.1e0,'pos',[POS_Fix(4,1) POS_Fix(4,2) POS_Fix(4,3)]);%,'axis',[0 0 1],'rot',0);

g_fix=geomcomp({gf1 gf2 gf3 gf4});


R=0.99;


gv1=sphere3(R,'pos',[POS_Var(1,1) POS_Var(1,2) POS_Var(1,3)]);%,'axis',[0 0 1],'rot',0);
gv2=sphere3(R,'pos',[POS_Var(2,1) POS_Var(2,2) POS_Var(2,3)]);%,'axis',[0 0 1],'rot',0);
gv3=sphere3(R,'pos',[POS_Var(3,1) POS_Var(3,2) POS_Var(3,3)]);%,'axis',[0 0 1],'rot',0);
gv4=sphere3(R,'pos',[POS_Var(4,1) POS_Var(4,2) POS_Var(4,3)]);%,'axis',[0 0 1],'rot',0);
gv5=sphere3(R,'pos',[POS_Var(5,1) POS_Var(5,2) POS_Var(5,3)]);%,'axis',[0 0 1],'rot',0);
gv6=sphere3(R,'pos',[POS_Var(6,1) POS_Var(6,2) POS_Var(6,3)]);%,'axis',[0 0 1],'rot',0);
gv7=sphere3(R,'pos',[POS_Var(7,1) POS_Var(7,2) POS_Var(7,3)]);%,'axis',[0 0 1],'rot',0);
gv8=sphere3(R,'pos',[POS_Var(8,1) POS_Var(8,2) POS_Var(8,3)]);%,'axis',[0 0 1],'rot',0);
gv9=sphere3(R,'pos',[POS_Var(9,1) POS_Var(9,2) POS_Var(9,3)]);%,'axis',[0 0 1],'rot',0);
gv10=sphere3(R,'pos',[POS_Var(10,1) POS_Var(10,2) POS_Var(10,3)]);%,'axis',[0 0 1],'rot',0);

gv11=sphere3(R,'pos',[POS_Var(11,1) POS_Var(11,2) POS_Var(11,3)]);%,'axis',[0 0 1],'rot',0);
gv12=sphere3(R,'pos',[POS_Var(12,1) POS_Var(12,2) POS_Var(12,3)]);%,'axis',[0 0 1],'rot',0);
gv13=sphere3(R,'pos',[POS_Var(13,1) POS_Var(13,2) POS_Var(13,3)]);%,'axis',[0 0 1],'rot',0);
gv14=sphere3(R,'pos',[POS_Var(14,1) POS_Var(14,2) POS_Var(14,3)]);%,'axis',[0 0 1],'rot',0);
gv15=sphere3(R,'pos',[POS_Var(15,1) POS_Var(15,2) POS_Var(15,3)]);%,'axis',[0 0 1],'rot',0);
gv16=sphere3(R,'pos',[POS_Var(16,1) POS_Var(16,2) POS_Var(16,3)]);%,'axis',[0 0 1],'rot',0);
gv17=sphere3(R,'pos',[POS_Var(17,1) POS_Var(17,2) POS_Var(17,3)]);%,'axis',[0 0 1],'rot',0);
gv18=sphere3(R,'pos',[POS_Var(18,1) POS_Var(18,2) POS_Var(18,3)]);%,'axis',[0 0 1],'rot',0);
gv19=sphere3(R,'pos',[POS_Var(19,1) POS_Var(19,2) POS_Var(19,3)]);%,'axis',[0 0 1],'rot',0);
gv20=sphere3(R,'pos',[POS_Var(20,1) POS_Var(20,2) POS_Var(20,3)]);%,'axis',[0 0 1],'rot',0);

gv21=sphere3(R,'pos',[POS_Var(21,1) POS_Var(21,2) POS_Var(21,3)]);%,'axis',[0 0 1],'rot',0);
gv22=sphere3(R,'pos',[POS_Var(22,1) POS_Var(22,2) POS_Var(22,3)]);%,'axis',[0 0 1],'rot',0);
gv23=sphere3(R,'pos',[POS_Var(23,1) POS_Var(23,2) POS_Var(23,3)]);%,'axis',[0 0 1],'rot',0);
gv24=sphere3(R,'pos',[POS_Var(24,1) POS_Var(24,2) POS_Var(24,3)]);%,'axis',[0 0 1],'rot',0);
gv25=sphere3(R,'pos',[POS_Var(25,1) POS_Var(25,2) POS_Var(25,3)]);%,'axis',[0 0 1],'rot',0);
gv26=sphere3(R,'pos',[POS_Var(26,1) POS_Var(26,2) POS_Var(26,3)]);%,'axis',[0 0 1],'rot',0);
gv27=sphere3(R,'pos',[POS_Var(27,1) POS_Var(27,2) POS_Var(27,3)]);%,'axis',[0 0 1],'rot',0);
gv28=sphere3(R,'pos',[POS_Var(28,1) POS_Var(28,2) POS_Var(28,3)]);%,'axis',[0 0 1],'rot',0);
gv29=sphere3(R,'pos',[POS_Var(29,1) POS_Var(29,2) POS_Var(29,3)]);%,'axis',[0 0 1],'rot',0);
gv30=sphere3(R,'pos',[POS_Var(30,1) POS_Var(30,2) POS_Var(30,3)]);%,'axis',[0 0 1],'rot',0);

gv31=sphere3(R,'pos',[POS_Var(31,1) POS_Var(31,2) POS_Var(31,3)]);%,'axis',[0 0 1],'rot',0);
gv32=sphere3(R,'pos',[POS_Var(32,1) POS_Var(32,2) POS_Var(32,3)]);%,'axis',[0 0 1],'rot',0);
gv33=sphere3(R,'pos',[POS_Var(33,1) POS_Var(33,2) POS_Var(33,3)]);%,'axis',[0 0 1],'rot',0);
gv34=sphere3(R,'pos',[POS_Var(34,1) POS_Var(34,2) POS_Var(34,3)]);%,'axis',[0 0 1],'rot',0);
gv35=sphere3(R,'pos',[POS_Var(35,1) POS_Var(35,2) POS_Var(35,3)]);%,'axis',[0 0 1],'rot',0);
gv36=sphere3(R,'pos',[POS_Var(36,1) POS_Var(36,2) POS_Var(36,3)]);%,'axis',[0 0 1],'rot',0);
gv37=sphere3(R,'pos',[POS_Var(37,1) POS_Var(37,2) POS_Var(37,3)]);%,'axis',[0 0 1],'rot',0);
gv38=sphere3(R,'pos',[POS_Var(38,1) POS_Var(38,2) POS_Var(38,3)]);%,'axis',[0 0 1],'rot',0);
gv39=sphere3(R,'pos',[POS_Var(39,1) POS_Var(39,2) POS_Var(39,3)]);%,'axis',[0 0 1],'rot',0);
gv40=sphere3(R,'pos',[POS_Var(40,1) POS_Var(40,2) POS_Var(40,3)]);%,'axis',[0 0 1],'rot',0);
g_var1=geomcomp({gv1 gv2 gv3 gv4 gv5 gv6 gv7 gv8 gv9 gv10 ...
gv11 gv12 gv13 gv14 gv15 gv16 gv17 gv18 gv19 gv20 ...
gv21 gv22 gv23 gv24 gv25 gv26 gv27 gv28 gv29 gv30 ...
gv31 gv32 gv33 gv34 gv35 gv36 gv37 gv38 gv39 gv40 });
g_cyl_ud=cylinder3(40,33,'pos',[0 0 -58])+cylinder3(40,33,'pos',[0 0 25]);
g_cyl_c1=cylinder3(5.5,50,'pos',[0 0 -25]);
g_cyl_c2=cylinder3(4,50,'pos',[0 0 -25]);
s.objs={g_cyl_ud,g_cyl_c1,g_cyl_c2,g_fix,g_var1}
fem.draw=struct('s',s);
[fem.geom,st]=geomcsg(fem);


0 Replies Last Post May 8, 2013, 7:56 a.m. EDT
COMSOL Moderator

Hello Nima Rezaeian

Your Discussion has gone 30 days without a reply. If you still need help with COMSOL and have an on-subscription license, please visit our Support Center for help.

If you do not hold an on-subscription license, you may find an answer in another Discussion or in the Knowledge Base.

Note that while COMSOL employees may participate in the discussion forum, COMSOL® software users who are on-subscription should submit their questions via the Support Center for a more comprehensive response from the Technical Support team.