E3SM-Project / HOMMEXX

Clone of ACME for CMDV-SE project to convert HOMME to C++
11 stars 0 forks source link

Elements array m_mp can be moved to Deriv and be just npxnp array #304

Open oksanaguba opened 6 years ago

oksanaguba commented 6 years ago

Homme has elem%mp array, but it does not have to be 'ie' array, see mass_matrix_mod:

    gp=gausslobatto(np)

    do ii=1,nelemd
       do j=1,np
          do i=1,np
              ! MNL: metric term for map to reference element is now in metdet!
             elem(ii)%mp(i,j)=gp%weights(i)*gp%weights(j)
             elem(ii)%rmp(i,j)=elem(ii)%mp(i,j)
          end do
       end do

       kptr=0
       call edgeVpack(edge,elem(ii)%rmp,1,kptr,ii)

    end do

(also, this comm above is not needed)

bartgol commented 6 years ago

I'm ok moving mp out of Elements. If we move in Derivative, then I think we should rename Derivative (since mp has nothing to do with a derivative). Perhaps call it FEMData (or SEMData)?

If I understand Homme correctly, the communication is needed, since rmp should store the reciprocal of the dss-ed mass.

oksanaguba commented 6 years ago

real quadrature is in spheremp and rspheremp. rmp values do not need dss, they depend only on 4x4 grid.

bartgol commented 6 years ago

ah, I see. Then we can remove it I guess.