What does bm1 represent in glsc3?

23 views
Skip to first unread message

Chinthaka Jacob

unread,
Sep 8, 2025, 4:46:40 AMSep 8
to Nek5000
Dear Nek Community,

  I am after a quick verification of an implementation. I am computing the volume-integrated squared velocity gradient (see attached equation), and the snippet below is from userchk.

  My understanding is that bm1 stores the lumped nodal volume weight so that summing bm1 over all nodes recovers the domain volume. Is this assumption correct? If not, what is the recommended/most accurate way to evaluate this integral?
Thanks,
Chinthaka.
c-----------------------------------------------------------------------
      subroutine userchk
      include 'SIZE'
      include 'TOTAL'

      real viscous_diss
      parameter(lt=lx1*ly1*lz1*lelv)
      common /myjunk/ dxux(lx1,ly1,lz1,lelv),
     $     dxuz(lx1,ly1,lz1,lelv),dyux(lx1,ly1,lz1,lelv),
     $     dyuz(lx1,ly1,lz1,lelv),dzux(lx1,ly1,lz1,lelv),
     $     dzuz(lx1,ly1,lz1,lelv),dxuy(lx1,ly1,lz1,lelv),
     $     dyuy(lx1,ly1,lz1,lelv),dzuy(lx1,ly1,lz1,lelv)

       call gradm1(dxux,dyux,dzux,vx) ! 1st derivative
       call gradm1(dxuy,dyuy,dzuy,vy)
       call gradm1(dxuz,dyuz,dzuz,vz)

       viscous_diss = (glsc3(dxux,bm1,dxux,lt)
     $   +glsc3(dyux,bm1,dyux,lt)+glsc3(dzuz,bm1,dzuz,lt)
     $   +glsc3(dzux,bm1,dzux,lt)+glsc3(dxuy,bm1,dxuy,lt)
     $   +glsc3(dyuy,bm1,dyuy,lt)+glsc3(dzuy,bm1,dzuy,lt)
     $   +glsc3(dxuz,bm1,dxuz,lt)+glsc3(dyuz,bm1,dyuz,lt))

      return
      end
c-----------------------------------------------------------------------
Eqn.png

Philipp Schlatter

unread,
Sep 8, 2025, 4:55:00 AMSep 8
to nek...@googlegroups.com

yes, that seems correct to me. bm1 is the (lumped) mass matrix.

Philipp

--
You received this message because you are subscribed to the Google Groups "Nek5000" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nek5000+u...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/nek5000/2429d32a-c69f-4602-8192-90932c6a3b89n%40googlegroups.com.

Fischer, Paul

unread,
Sep 8, 2025, 12:42:26 PMSep 8
to Philipp Schlatter, nek...@googlegroups.com

Correct.

 bm1 is the diagonal mass matrix on "mesh 1"  (the velocity mesh on the GLL points)

 bm2 is the diagonal mass matrix on "mesh 2"  (the pressure mesh)

For PN-PN (equal order pressure and velocity approximations), bm1 == bm2.

For PN-PN-2, bm2 is the diagonal mass matrix on the Gauss-Legendre (GL) points


From: nek...@googlegroups.com <nek...@googlegroups.com> on behalf of Philipp Schlatter <psch...@gmail.com>
Sent: Monday, September 8, 2025 3:54 AM
To: nek...@googlegroups.com <nek...@googlegroups.com>
Subject: Re: [nek5000] What does bm1 represent in glsc3?
 
Reply all
Reply to author
Forward
0 new messages