SUBROUTINE CADJMOD C Adjusts binary component fluxes so they add up to FLUXTOT(1). C Also makes sure that the separations and position angles are the C same for each filter, adjusts the diameters using the diameter C in filter 1 and the diameter ratios given, and adjusts the magnitude C differences for components after component 1 using the magnitude C difference for filter 1 and the colors for the other filters. C C By J.T. Armstrong 15 Jan 1991 INCLUDE 'BINFIT.INC' REAL*8 FLUXSUM(MXFILT) C Make sure that all the separations and position angles for a given C component are equal, fix up the diameters for filters IG > 1, C and fix up the magnitude differences for components IC > 1 and C filters IG > 1: DO IG = 2, NFILT SEP (1,IG) = SEP (1,1) POSANG(1,IG) = POSANG(1,1) DIAM (1,IG) = DIAM (1,1)*DRATIO(1,IG) END DO DO IC = 2, NCOMP DO IG = 2, NFILT SEP (IC,IG) = SEP (IC,1) POSANG(IC,IG) = POSANG(IC,1) DIAM (IC,IG) = DIAM (IC,1)*DRATIO(IC,IG) DELMAG(IC,IG) = DELMAG(IC,1)+COLOR (IC,IG) D WRITE(OUTC,'(A,I2,A,I2,A,F10.4)') D 1 ' DELMAG(',IC,',',IG,') = ',DELMAG(IC,IG) END DO END DO C Add up relative contributions to FLUXTOT: DO IG = 1, NFILT FLUXSUM(IG) = 1. ! From first component DO IC = 2, NCOMP FLUXSUM(IG) = FLUXSUM(IG) + 10.0**(-0.4*DELMAG(IC,IG)) END DO END DO C Calculate FLUXes from FLUXTOT, FLUXSUM, and DELMAG: DO IG = 1, NFILT FLUX(1,IG) = FLUXTOT(1,IG)/FLUXSUM(IG) DO IC = 2, NCOMP FLUX(IC,IG) = FLUX(1,IG) * 10.0**(-0.4*DELMAG(IC,IG)) D WRITE(OUTC,'(A,I2,A,I2,A,F10.4)') D 1 ' FLUX(',IC,',',IG,') = ',FLUX(IC,IG) END DO END DO RETURN END