asserts.notApprox(computed, expected, relTol)
asserts.notApprox(computed, expected, relTol, absTol)
[res, msg] = asserts.notApprox(computed, expected, relTol)
| Parameter | Description |
|---|---|
| computed | Computed numeric value. |
| expected | Value that must not be approximately equal to computed. |
| relTol | Nonnegative finite relative tolerance. |
| absTol | Optional nonnegative finite absolute tolerance. |
| Parameter | Description |
|---|---|
| res | true if the assertion passes, false otherwise. |
| msg | assertion failure message, empty on success. |
The assertion passes when asserts.isapprox would fail.
Both tolerances must be finite nonnegative numeric scalars.
asserts.notApprox(1, 2, eps);
[res, msg] = asserts.notApprox(1, 1, eps);
| Version | Description |
|---|---|
| 2.0.0 | initial version |