easifem / base

Expandable And Scalable Infrastructure for Finite Element Methods, EASIFEM, is [Modern Fortran](https://fortran-lang.org) framework for solving partial differential equations (PDEs) using finite element methods. EASIFEM "eases" the efforts to develop scientific programs in Fortran.
https://www.easifem.com
Other
8 stars 2 forks source link

Update higher order element in ReferenceQuadrangle_Method #279

Closed vickysharma0812 closed 8 months ago

vickysharma0812 commented 9 months ago
MODULE PROCEDURE Initiate_ref_Quadrangle
REAL(DFP) :: unit_xij(2, 4), biunit_xij(2, 4)
CALL DEALLOCATE (obj)

obj%topology(5) = ReferenceTopology([1, 2], Line2)
obj%topology(6) = ReferenceTopology([2, 3], Line2)
obj%topology(7) = ReferenceTopology([3, 4], Line2)
obj%topology(8) = ReferenceTopology([4, 1], Line2)

END PROCEDURE Initiate_ref_Quadrangle

The order of edges is not correct. It should be (1,2), (4,3), (1,4) and (2,3).

Similar thing happen in higher order element

  aintvec = [1, 2] .append.arange(5_I4B, 3_I4B + order)
  obj%topology(NNS + 1) = ReferenceTopology(aintvec, Linename(order=order))

  aintvec = [2, 3] .append.arange( &
                                  & 3_I4B + order + 1, &
                                  & 3_I4B + order + order - 1_I4B)
  obj%topology(NNS + 2) = ReferenceTopology(aintvec, Linename(order=order))

  aintvec = [3, 4] .append.arange(&
                                  & 2_I4B + 2_I4B * order + 1, &
                                  & 2_I4B + 2_I4B * order + order - 1_I4B)
  obj%topology(NNS + 3) = ReferenceTopology(aintvec, Linename(order=order))

  aintvec = [4, 1] .append.arange( &
                            & 1_I4B + 3_I4B * order + 1,  &
                            & 1_I4B + 3_I4B * order + order - 1_I4B)
vickysharma0812 commented 8 months ago

Moved to issue #141