Lines Matching refs:N

105 static PetscErrorCode MatMult_Normal(Mat N, Vec x, Vec y)  in MatMult_Normal()  argument
110 PetscCall(MatShellGetContext(N, &Na)); in MatMult_Normal()
116 static PetscErrorCode MatDestroy_Normal(Mat N) in MatDestroy_Normal() argument
121 PetscCall(MatShellGetContext(N, &Na)); in MatDestroy_Normal()
126 PetscCall(PetscObjectComposeFunction((PetscObject)N, "MatNormalGetMat_C", NULL)); in MatDestroy_Normal()
127 PetscCall(PetscObjectComposeFunction((PetscObject)N, "MatConvert_normal_seqaij_C", NULL)); in MatDestroy_Normal()
128 PetscCall(PetscObjectComposeFunction((PetscObject)N, "MatConvert_normal_mpiaij_C", NULL)); in MatDestroy_Normal()
130 PetscCall(PetscObjectComposeFunction((PetscObject)N, "MatConvert_normal_hypre_C", NULL)); in MatDestroy_Normal()
132 …PetscCall(PetscObjectComposeFunction((PetscObject)N, "MatProductSetFromOptions_normal_seqdense_C",… in MatDestroy_Normal()
133 …PetscCall(PetscObjectComposeFunction((PetscObject)N, "MatProductSetFromOptions_normal_mpidense_C",… in MatDestroy_Normal()
134 PetscCall(PetscObjectComposeFunction((PetscObject)N, "MatShellSetContext_C", NULL)); in MatDestroy_Normal()
141 static PetscErrorCode MatGetDiagonal_Normal(Mat N, Vec v) in MatGetDiagonal_Normal() argument
151 PetscCall(MatShellGetContext(N, &Na)); in MatGetDiagonal_Normal()
153 PetscCall(PetscMalloc1(A->cmap->N, &work)); in MatGetDiagonal_Normal()
154 PetscCall(PetscArrayzero(work, A->cmap->N)); in MatGetDiagonal_Normal()
161 …MPI(MPIU_Allreduce(MPI_IN_PLACE, work, A->cmap->N, MPIU_SCALAR, MPIU_SUM, PetscObjectComm((PetscOb… in MatGetDiagonal_Normal()
162 rstart = N->cmap->rstart; in MatGetDiagonal_Normal()
163 rend = N->cmap->rend; in MatGetDiagonal_Normal()
171 static PetscErrorCode MatGetDiagonalBlock_Normal(Mat N, Mat *D) in MatGetDiagonalBlock_Normal() argument
177 PetscCall(MatShellGetContext(N, &Na)); in MatGetDiagonalBlock_Normal()
226 PetscInt m, n, M, N; in MatConvert_Normal_AIJ() local
231 PetscCall(MatGetSize(A, &M, &N)); in MatConvert_Normal_AIJ()
321 PetscInt n, N, m, M; in MatProductSymbolic_Normal_Dense() local
331 PetscCall(MatGetSize(C, &M, &N)); in MatProductSymbolic_Normal_Dense()
332 if (m == PETSC_DECIDE || n == PETSC_DECIDE || M == PETSC_DECIDE || N == PETSC_DECIDE) { in MatProductSymbolic_Normal_Dense()
334 PetscCall(MatGetSize(B, NULL, &N)); in MatProductSymbolic_Normal_Dense()
337 PetscCall(MatSetSizes(C, m, n, M, N)); in MatProductSymbolic_Normal_Dense()
405 PetscErrorCode MatCreateNormal(Mat A, Mat *N) in MatCreateNormal() argument
411 PetscCall(MatCreate(PetscObjectComm((PetscObject)A), N)); in MatCreateNormal()
412 PetscCall(PetscLayoutReference(A->cmap, &(*N)->rmap)); in MatCreateNormal()
413 PetscCall(PetscLayoutReference(A->cmap, &(*N)->cmap)); in MatCreateNormal()
414 PetscCall(MatSetType(*N, MATSHELL)); in MatCreateNormal()
416 PetscCall(MatShellSetContext(*N, Na)); in MatCreateNormal()
421 PetscCall(MatSetBlockSize(*N, A->cmap->bs)); in MatCreateNormal()
422 PetscCall(MatShellSetOperation(*N, MATOP_DESTROY, (PetscErrorCodeFn *)MatDestroy_Normal)); in MatCreateNormal()
423 PetscCall(MatShellSetOperation(*N, MATOP_MULT, (PetscErrorCodeFn *)MatMult_Normal)); in MatCreateNormal()
424 PetscCall(MatShellSetOperation(*N, MATOP_MULT_TRANSPOSE, (PetscErrorCodeFn *)MatMult_Normal)); in MatCreateNormal()
425 PetscCall(MatShellSetOperation(*N, MATOP_DUPLICATE, (PetscErrorCodeFn *)MatDuplicate_Normal)); in MatCreateNormal()
426 …PetscCall(MatShellSetOperation(*N, MATOP_GET_DIAGONAL, (PetscErrorCodeFn *)MatGetDiagonal_Normal)); in MatCreateNormal()
427 …PetscCall(MatShellSetOperation(*N, MATOP_GET_DIAGONAL_BLOCK, (PetscErrorCodeFn *)MatGetDiagonalBlo… in MatCreateNormal()
428 PetscCall(MatShellSetOperation(*N, MATOP_COPY, (PetscErrorCodeFn *)MatCopy_Normal)); in MatCreateNormal()
429 (*N)->ops->increaseoverlap = MatIncreaseOverlap_Normal; in MatCreateNormal()
430 (*N)->ops->createsubmatrices = MatCreateSubMatrices_Normal; in MatCreateNormal()
431 (*N)->ops->permute = MatPermute_Normal; in MatCreateNormal()
433 …PetscCall(PetscObjectComposeFunction((PetscObject)*N, "MatNormalGetMat_C", MatNormalGetMat_Normal)… in MatCreateNormal()
434 …PetscCall(PetscObjectComposeFunction((PetscObject)*N, "MatConvert_normal_seqaij_C", MatConvert_Nor… in MatCreateNormal()
435 …PetscCall(PetscObjectComposeFunction((PetscObject)*N, "MatConvert_normal_mpiaij_C", MatConvert_Nor… in MatCreateNormal()
437 …PetscCall(PetscObjectComposeFunction((PetscObject)*N, "MatConvert_normal_hypre_C", MatConvert_Norm… in MatCreateNormal()
439 …PetscCall(PetscObjectComposeFunction((PetscObject)*N, "MatProductSetFromOptions_normal_seqdense_C"… in MatCreateNormal()
440 …PetscCall(PetscObjectComposeFunction((PetscObject)*N, "MatProductSetFromOptions_normal_mpidense_C"… in MatCreateNormal()
441 …PetscCall(PetscObjectComposeFunction((PetscObject)*N, "MatShellSetContext_C", MatShellSetContext_I… in MatCreateNormal()
442 …PetscCall(PetscObjectComposeFunction((PetscObject)*N, "MatShellSetContextDestroy_C", MatShellSetCo… in MatCreateNormal()
443 …PetscCall(PetscObjectComposeFunction((PetscObject)*N, "MatShellSetManageScalingShifts_C", MatShell… in MatCreateNormal()
444 PetscCall(MatSetOption(*N, MAT_SYMMETRIC, PETSC_TRUE)); in MatCreateNormal()
446 PetscCall(MatSetVecType(*N, vtype)); in MatCreateNormal()
448 PetscCall(MatBindToCPU(*N, A->boundtocpu)); in MatCreateNormal()
450 PetscCall(MatSetUp(*N)); in MatCreateNormal()
451 PetscCall(PetscObjectChangeTypeName((PetscObject)*N, MATNORMAL)); in MatCreateNormal()