Author Topic: assembly in parallel implementation  (Read 10793 times)

Shu

  • Jr. Member
  • **
  • Posts: 25
assembly in parallel implementation
« on: August 14, 2012, 07:52:31 PM »
Dear All,

I am doing some palatalization work using FEAP. By read the source file, I find that FEAP using PetSc and create a block aij martrix to assemble stiffness matrix. Can anyone introduce this method comparing with normal aij matrix? What is the advantage to do so?

Thanks

Shu

FEAP_Admin

  • Administrator
  • FEAP Guru
  • *****
  • Posts: 993
Re: assembly in parallel implementation
« Reply #1 on: August 14, 2012, 07:57:18 PM »
The choice of BAIJ versus AIJ is mainly dictated by the solver you are using.  For example if you are using prometheus then you have to use BAIJ.  If you are using SuperLU then you have to use AIJ.

In terms of speed, there is a bit of speed up with BAIJ but in general this is not going to be substantial.

Shu

  • Jr. Member
  • **
  • Posts: 25
Re: assembly in parallel implementation
« Reply #2 on: August 15, 2012, 01:47:11 PM »
Thanks for your reply. Also I have a question, when FEAP is trying to assemble the matrix, for example in a blocked way, it has:
          call MatCreateMPIBAIJ(PETSC_COMM_WORLD,nsbk,numpeq,numpeq,
     &                          PETSC_DETERMINE, PETSC_DETERMINE,
     &                          PETSC_NULL_INTEGER, mr(np(246)),
     &                          PETSC_NULL_INTEGER, mr(np(247)),
     &                          Kmatem, ierr)

Where does this np(246) and np(247) comes from? I was trying to search the source code but cannot have a clue. Can you briefly introduce how they are calculated?

Thank.
Shu

FEAP_Admin

  • Administrator
  • FEAP Guru
  • *****
  • Posts: 993
Re: assembly in parallel implementation
« Reply #3 on: August 15, 2012, 05:08:33 PM »
When you partition your problem [graph,node,XX] this information is generated and written to the partitioned input files
by [outd,<bloc>k]; both commands are in parfeap/pmacr7.F.

Then when you start-up your parallel computation, the information for on-diagonal and off-diagonal storage is read in from the parallel input files and stored in mr(np(246)) and mr(np(247)), respectively.  The call sequence is program/pcontr.f calling parfeap/pdomain.F.  [Note there is a dummy pdomain.f in program for serial runs.]

Shu

  • Jr. Member
  • **
  • Posts: 25
Re: assembly in parallel implementation
« Reply #4 on: August 16, 2012, 07:25:00 PM »
Thank you very much for your help!