V=pntsrc(par,u,v,band,nu) Calculate the complex visibilities expected for a source location in par and a set of baselines u,v in bands of given number looking up freq in nu par(1) = flux (at band center) par(2) = spectral index (note biased for src not at field center) par(3:4) = l,m position on field
0001 function V=pntsrc(par,u,v,band,nu) 0002 % V=pntsrc(par,u,v,band,nu) 0003 % 0004 % Calculate the complex visibilities expected for a source 0005 % location in par and a set of baselines u,v in bands of 0006 % given number looking up freq in nu 0007 % 0008 % par(1) = flux (at band center) 0009 % par(2) = spectral index (note biased for src not at field center) 0010 % par(3:4) = l,m position on field 0011 0012 % Flux is flux at mean freq 0013 mnu=mean(nu(:)); 0014 0015 % Calc src flux for each freq 0016 s=cvec(par(1).*(nu/mnu).^par(2)); 0017 0018 % Expand out to each vis 0019 s=s(band); 0020 0021 % Dot product of src location and baseline vectors 0022 a=2*pi*(par(3)*u+par(4)*v); 0023 0024 % Expected visibility 0025 V=s.*complex(cos(a),sin(a)); 0026 0027 return