	program mat
	double precision aa(4,4),bb(4,4),cc(4,4),v(4),vv(16)
	double precision ymc(10),ypc(10)
        integer ir(16)
	aa(1,1)=1.
	aa(2,1)=-1.
	aa(3,1)=0.
	aa(4,1)=0.

        aa(1,2)=0.
        aa(2,2)=0.
        aa(3,2)=1.
        aa(4,2)=-1.

        aa(1,3)=1.
        aa(2,3)=0.
        aa(3,3)=1.
        aa(4,3)=0.

        aa(1,4)=0.
        aa(2,4)=1.
        aa(3,4)=0.
        aa(4,4)=1.

	do i=1,4
	do j=1,4
		bb(i,j)=aa(j,i)
	enddo
	enddo
      
          YMC(1) = 279.917
          YMC(2) = 233.4
          YMC(3) = 227.167
          YMC(4) = 180.15
          YMC(5) = 218.133
          YMC(6) = 259.033
          YMC(7) = 264.683
          YPC(1) = 703.55
          YPC(2) = 680.583
          YPC(3) = 686.233
          YPC(4) = 684.067
          YPC(5) = 676.683
          YPC(6) = 661.35
          YPC(7) = 713.333

	v(1)=ypc(1)
	v(2)=ymc(6)
	v(3)=ypc(6)
	v(4)=ymc(1)

	ifree=4
          call DINV(ifree,bb,ifree,IR,IFAIL)
          if (ifail.ne.0) print *,'invers FAILED ',ifail

      call DEQN(ifree,aa,ifree,IR,IFAIL,1,v)
      if (ifail.ne.0) print *,'shit FAILED ',ifail



	write(*,*)v
	end

	

	
