-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathskpfa.hh
33 lines (32 loc) · 1.29 KB
/
skpfa.hh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
/**
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
#pragma once
#include "blis.h"
/**
* \brief Calculate Pfaffian (&optionally inverse) of antisymmetric matrix A.
* The tri-diagonal decomposition is returned after computation is complete.
*
* \param uplo Only 'U' allowed.
* \param n Dimension of A.
* \param _A (IN/OUT) Array (base address of) A. Contains tri-diag part of decomposition on exit.
* \param ldA Leading dimension size of A (row-skip).
* \param _G (OUT) Array of the same size as A. Contains gaussian elimination part on exit.
* \param ldG Leading dimension size of G (row-skip).
* \param iPov (OUT) Povoting information of size n+1.
* \param inv Whether inverse would be calculated and stored in A.
* \param dPfa (OUT) Single-FP buffer for returning final Pfaffian computed.
* \param _Work Scratch space. Use 8*n if not sure.
* \param lWork Scratch space size.
*/
template <typename T>
signed skpfa(uplo_t uplo,
dim_t n,
T *_A, inc_t ldA,
T *_G, inc_t ldG,
signed *iPov,
bool inv,
T *dPfa,
T *_Work, dim_t lWork);