View source: R/matrix_scaled.R
scale_matrix | R Documentation |
Create list of factors as in a product
scale_matrix(X, k = NULL, divide = TRUE)
X |
matrix |
k |
scalar to be factored out |
divide |
Should |
if (has_sympy()) {
V <- matrix_sym(2, 2, "v")
a <- symbol("a")
K <- a*V
scale_matrix(K, a)
scale_matrix(V, a, divide = FALSE)
Ks <- scale_matrix(V, a, divide = FALSE)
Ks
W <- matrix_sym(2, 2, "w")
unscale_matrix(Ks) %*% W
unscale_matrix(Ks) %*% W |> scale_matrix(a)
Ksi <- unscale_matrix(Ks) |> inv() |> scale_matrix(a/det(unscale_matrix(Ks)))
(Ksi |> unscale_matrix()) %*% (Ks |> unscale_matrix()) |> simplify()
tex(Ksi)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.