Scilab Website | Contribute with GitLab | Mailing list archives | ATOMS toolboxes
Scilab Online Help
2025.1.0 - Français


pascal

Pascal matrix

Syntax

p = pascal(n)
p = pascal(n, k)

Arguments

n

non-negative scalar integer.

k

a positive integer: 0, 1 or 2. Default value is 0.

p

n x n matrix.

Description

p = pascal(n) returns the Pascal matrix of size n x n. The Pascal matrix is the symmetric matrix, positive definite and has the Cholesky factorization.

p = pascal(n, 0) is equivalent to p = pascal(n).

p1 = pascal(n, 1) returns the lower triangular Cholesky factor of the Pascal matrix, and p1 * p1' = p where p is the result of pascal(n). The result is its own inverse and is equal to the square root of the identity matrix, p1 ^2 = eye(n,n).

p2 = pascal(n, 2) permutes and transposes pascal(n, 1). p2^3 is equal to the cube root of the identity matrix.

Examples

p = pascal(4)

p = pascal(4)
p1 = pascal(4, 1)
p1 * p1' == p
p1 ^ 2

p = pascal(4, 2)
p ^ 3

See also

History

VersionDescription
2025.1.0 Introduction in Scilab.
Report an issue
<< ones Matrice - génération perms >>

Copyright (c) 2022-2024 (Dassault Systèmes)
Copyright (c) 2017-2022 (ESI Group)
Copyright (c) 2011-2017 (Scilab Enterprises)
Copyright (c) 1989-2012 (INRIA)
Copyright (c) 1989-2007 (ENPC)
with contributors
Last updated:
Thu May 22 12:54:24 CEST 2025