Exemple #1
0
def test_is_strictly_decreasing():
    """Test whether is_strictly_decreasing returns correct value."""
    assert is_strictly_decreasing(1/(x**2 - 3*x), Interval.Lopen(3, oo))
    assert not is_strictly_decreasing(
        1/(x**2 - 3*x), Interval.Ropen(-oo, S(3)/2))
    assert not is_strictly_decreasing(-x**2, Interval(-oo, 0))
    assert not is_strictly_decreasing(1)
Exemple #2
0
def test_is_strictly_decreasing():
    assert is_strictly_decreasing(1 / (x**2 - 3 * x), Interval.Lopen(3, oo))
    assert is_strictly_decreasing(1 / (x**2 - 3 * x),
                                  Interval.Ropen(-oo,
                                                 S(3) / 2)) is False
    assert is_strictly_decreasing(-x**2, Interval(-oo, 0)) is False
    assert is_strictly_decreasing(1) is False
Exemple #3
0
def test_is_strictly_decreasing():
    """Test whether is_strictly_decreasing returns correct value."""
    assert is_strictly_decreasing(1 / (x**2 - 3 * x), Interval.Lopen(3, oo))
    assert not is_strictly_decreasing(1 / (x**2 - 3 * x),
                                      Interval.Ropen(-oo, Rational(3, 2)))
    assert not is_strictly_decreasing(-(x**2), Interval(-oo, 0))
    assert not is_strictly_decreasing(1)
    assert is_strictly_decreasing(1 / (x**2 - 3 * x), Interval.open(1.5, 3))
Exemple #4
0
def test_is_strictly_increasing():
    assert is_strictly_increasing(4 * x**3 - 6 * x**2 - 72 * x + 30,
                                  Interval.Ropen(-oo, -2))
    assert is_strictly_increasing(4 * x**3 - 6 * x**2 - 72 * x + 30,
                                  Interval.Lopen(3, oo))
    assert is_strictly_increasing(4 * x**3 - 6 * x**2 - 72 * x + 30,
                                  Interval.open(-2, 3)) is False
    assert is_strictly_increasing(-x**2, Interval(0, oo)) is False
    assert is_strictly_decreasing(1) is False
Exemple #5
0
def test_is_strictly_increasing():
    """Test whether is_strictly_increasing returns correct value."""
    assert is_strictly_increasing(4 * x**3 - 6 * x**2 - 72 * x + 30,
                                  Interval.Ropen(-oo, -2))
    assert is_strictly_increasing(4 * x**3 - 6 * x**2 - 72 * x + 30,
                                  Interval.Lopen(3, oo))
    assert not is_strictly_increasing(4 * x**3 - 6 * x**2 - 72 * x + 30,
                                      Interval.open(-2, 3))
    assert not is_strictly_increasing(-x**2, Interval(0, oo))
    assert not is_strictly_decreasing(1)
def test_is_strictly_increasing():
    """Test whether is_strictly_increasing returns correct value."""
    assert is_strictly_increasing(
        4*x**3 - 6*x**2 - 72*x + 30, Interval.Ropen(-oo, -2))
    assert is_strictly_increasing(
        4*x**3 - 6*x**2 - 72*x + 30, Interval.Lopen(3, oo))
    assert not is_strictly_increasing(
        4*x**3 - 6*x**2 - 72*x + 30, Interval.open(-2, 3))
    assert not is_strictly_increasing(-x**2, Interval(0, oo))
    assert not is_strictly_decreasing(1)
Exemple #7
0
def test_strictly_decreasing():
    assert is_strictly_decreasing(1 / (x**2 - 3 * x), Interval.open(1.5, 3))
def test_is_strictly_decreasing():
    assert is_strictly_decreasing(1/(x**2 - 3*x), Interval.open(1.5, 3))
    assert is_strictly_decreasing(1/(x**2 - 3*x), Interval.Lopen(3, oo))
    assert is_strictly_decreasing(1/(x**2 - 3*x), Interval.Ropen(-oo, S(3)/2)) is False
    assert is_strictly_decreasing(-x**2, Interval(-oo, 0)) is False
    assert is_strictly_decreasing(1) is False
def test_is_strictly_increasing():
    assert is_strictly_increasing(4*x**3 - 6*x**2 - 72*x + 30, Interval.Ropen(-oo, -2))
    assert is_strictly_increasing(4*x**3 - 6*x**2 - 72*x + 30, Interval.Lopen(3, oo))
    assert is_strictly_increasing(4*x**3 - 6*x**2 - 72*x + 30, Interval.open(-2, 3)) is False
    assert is_strictly_increasing(-x**2, Interval(0, oo)) is False
    assert is_strictly_decreasing(1) is False
Exemple #10
0
def test_strictly_decreasing():
    assert is_strictly_decreasing(1/(x**2 - 3*x), Interval.open(1.5, 3))