subroutine CalculateTendency_DGModel2D_t(this)
implicit none
class(DGModel2D_t),intent(inout) :: this
! Local
integer :: i,j,iEl,iVar
call this%solution%BoundaryInterp()
call this%solution%SideExchange(this%mesh)
call this%PreTendency() ! User-supplied
call this%SetBoundaryCondition() ! User-supplied
if(this%gradient_enabled) then
call this%solution%AverageSides()
call this%CalculateSolutionGradient()
call this%SetGradientBoundaryCondition() ! User-supplied
call this%solutionGradient%AverageSides()
endif
call this%SourceMethod() ! User supplied
call this%BoundaryFlux() ! User supplied
call this%FluxMethod() ! User supplied
call this%flux%MappedDGDivergence(this%fluxDivergence%interior)
do concurrent(i=1:this%solution%N+1,j=1:this%solution%N+1, &
iel=1:this%mesh%nElem,ivar=1:this%solution%nVar)
this%dSdt%interior(i,j,iEl,iVar) = &
this%source%interior(i,j,iEl,iVar)- &
this%fluxDivergence%interior(i,j,iEl,iVar)
enddo
endsubroutine CalculateTendency_DGModel2D_t