is_consistent: Check if the matrix equation Ax = b is consistent

View source: R/is_consistent.R

is_consistentR Documentation

Check if the matrix equation Ax = b is consistent

Description

Check if the matrix equation Ax = b is consistent

Usage

is_consistent(A, b)

Arguments

A

The matrix A

b

The vector b

Value

This function returns TRUE if there is a solution to the equation Ax = b and FALSE if there is not a solution to the equation Ax = b

Examples


library(dasc2594)
A <- diag(2)
b <- 1:2
# expect TRUE
is_consistent(A, b)

A <- matrix(c(1, 0, 1, 0), 2, 2)
b <- 1:2
# expect FALSE
is_consistent(A, b)

jtipton25/dasc2594 documentation built on Oct. 7, 2022, 3:46 p.m.