Inequality

Element

The area which is the set of solutions of a linear inequality or an inequality of a function graph. For example, an inequality of type \(y \leq f(x)\).

Display the solution set of a linear inequality (less than or equal to). That is, the solution set of the inequality \(y \leq (b \cdot x + c)a\) is shown. In case \(a = 0\), i.e. if the equation of the line is \(bx + c = 0\), the area of the inequality \(bx + c \leq 0\) is shown.

For function graphs the area below the function graph is filled, i.e. the area of the inequality \(y \leq f(x)\). With the attribute inverse:true the area of the inequality \(y \geq f(x)\) is filled.

Usage (signatures)
board.create('inequality', [l]);

The area shown is the area below this line or function graph. With the attribute inverse:true, the inequality 'greater than or equal to' is shown.

Parameters
Name Type Description
l Line | Functiongraph
Examples

Inequality: semi-plane

var p = board.create('point', [1, 3]),
    q = board.create('point', [-2, -4]),
    l = board.create('line', [p, q]),
    ineq = board.create('inequality', [l]);

Inequality: y >= 2/3 x + 1

// Plot the inequality
//     y >= 2/3 x + 1
// or
//     0 >= -3y + 2x +1
var l = board.create('line', [1, 2, -3]),
    ineq = board.create('inequality', [l], {inverse:true});

Inequality (x,y) such that with y >= sin(x)

var f = board.create('functiongraph', ['sin(x)', -2*Math.PI, 2*Math.PI]);

var ineq_lower = board.create('inequality', [f]);
var ineq_greater = board.create('inequality', [f], {inverse: true, fillColor: 'yellow'});

Attributes

Own

inverse

Description

By default an inequality is less (or equal) than. Set inverse to true will consider the inequality greater (or equal) than.

Type
Boolean
Default Value
false
Source
options.js, line 6422

Inherited

Members

Own

none

Inherited

Methods

Own

none

Inherited

Events

Own

none

Inherited

Throws

If the element cannot be constructed with the given parent objects an exception is thrown.

Type
Error

Details

Type
JXG.Curve
Source
element/composition.js, line 2813

Extends