Logikaj funkcioj

This category contains the Logical functions.

Handling non-logical arguments in logical functions

Por atingi ĉi tiun komandon...

Insert - Function - Category Logical


ESTASNEDISPONEBLA

Liveras je VERA se ĉelo enhavas la prieraran valoron #N/A (valoro ne estas disponebla).

If an error occurs, the function returns FALSE.

Sintakso

ISNA(Value)

Valoro estas la valoro aĆ­ esprimo testota.

Ekzemplo

=ISNA(D3) returns FALSE as a result.

ESTASERARA

Returns the value if the cell does not contain an error value, or the alternative value if it does.

tip

Ĉi tiu funkcio disponeblas ekde versio 4.0 de LibreOffice.


Sintakso

IFERROR(Value; Alternate_value)

Value is the value or expression to be returned if it is not equal or results in an error.

Alternate_value is the value or expression to be returned if the expression or value of Value is equal or results in an error.

Ekzemplo

=IFERROR(C8;C9) where cell C8 contains =1/0 returns the value of C9, because 1/0 is an error.

=IFERROR(C8;C9) where cell C8 contains 13 returns 13, the value of C8, which is not an error.

IFS

IFS is a multiple IF-function.

SWITCH

SWITCH compares expression with value1 to valuen and returns the result belonging to the first value that equals expression. If there is no match and default_result is given, that will be returned.

AĆŹ

Liveras je VERA se almenaƭ unu argumento estas VERA. Ĉi tiu funkcio liveras la valoron FALSA, se ĉiuj argumentoj havas la logikan valoron FALSA.

The arguments are either logical expressions themselves (TRUE, 1<5, 2+3=7, B8<10) that return logical values, or arrays (A1:C3) containing logical values.La argumentoj estas aĆ­ logikaj esprimoj (VERA, 1<5, 2+3=7, B8<10) kiuj liveras logikajn valorojn, aĆ­ tabeloj (A1:C3) kiuj enhavas logikajn valorojn.

Sintakso

OR(Logical 1 [; Logical 2 [; 
 [; Logical 255]]])

Logical 1, Logical 2, 
 , Logical 255 are boolean values, references to cells or to cell ranges of logical values.

note

This function ignores any text or empty cell within a data range. If you suspect wrong results from this function, look for text in the data ranges. To highlight text contents in a data range, use the value highlighting feature.


Ekzemplo

La logikaj valoroj de la eroj 12<11; 13>22, kaj 45=45 estas testotaj.

=AĆŹ(12<11;13>22;45=45) liveras je VERA.

=OR(FALSE();TRUE()) returns TRUE.

FALSA

Liveras la logikan valoron FALSA. La FALSA()-funkcio ne bezonas argumentojn, kaj ĉiam liveras la logikan valoron FALSA.

Sintakso

FALSA()

Ekzemplo

=KAJ(A;B) liveras je FALSA

=NE(KAJ(A;B)) liveras je VERA

KAJ

Liveras je VERA se ĉiuj argumentoj estas veraj. Se unu elemento estas falsa, la funkcio liveras la valoron FALSA.

The arguments are either logical expressions themselves (TRUE, 1<5, 2+3=7, B8<10) that return logical values, or arrays (A1:C3) containing logical values.La argumentoj estas aĆ­ logikaj esprimoj (VERA, 1<5, 2+3=7, B8<10) kiuj liveras logikajn valorojn, aĆ­ tabeloj (A1:C3) kiuj enhavas logikajn valorojn.

Sintakso

AND(Logical 1 [; Logical 2 [; 
 [; Logical 255]]])

Logical 1, Logical 2, 
 , Logical 255 are boolean values, references to cells or to cell ranges of logical values.

note

This function ignores any text or empty cell within a data range. If you suspect wrong results from this function, look for text in the data ranges. To highlight text contents in a data range, use the value highlighting feature.


Ekzemplo

La logikaj valoroj de la eroj 12<13; 14>12, kaj 7<6 estas testotaj:

=KAJ(12<13;14>12;7<6) liveras je FALSA.

=AND(FALSE();TRUE()) returns FALSE.

NE

Complements (inverts) a logical value.

Sintakso

NOT(LogicalValue)

LogicalValue is any value to be complemented.

Ekzemplo

=NOT(A). If A=TRUE then NOT(A) will evaluate FALSE.

SE

Specifas logikan teston farotan.

Sintakso

IF(Test [; [ThenValue] [; [OtherwiseValue]]])

Testo estas valoro aĆ­ esprimo kiu povas esti VERA aĆ­ FALSA.

ThenValue (optional) is the value that is returned if the logical test is TRUE.

OtherwiseValue (optional) is the value that is returned if the logical test is FALSE.

In the LibreOffice Calc functions, parameters marked as "optional" can be left out only when no parameter follows. For example, in a function with four parameters, where the last two parameters are marked as "optional", you can leave out parameter 4 or parameters 3 and 4, but you cannot leave out parameter 3 alone.

Ekzemplo

=IF(A1>5;100;"too small") If the value in A1 is greater than 5, the value 100 is returned; otherwise, the text too small is returned.

=IF(A1>5;;"too small") If the value in A1 is greater than 5, the value 0 is returned because empty parameters are considered to be 0; otherwise, the text too small is returned.

=IF(A1>5;100;) If the value in A1 is less than 5, the value 0 is returned because the empty OtherwiseValue is interpreted as 0; otherwise 100 is returned.

VERA

Atribuas la logikan valoron al VERA. La VERA()-funkcio ne bezonas argumentojn, kaj ĉiam liveras la logikan valoron VERA.

Sintakso

VERA()

Ekzemplo

Se A=VERA kaj B=FALSA the jenaj ekzemploj aperas:

=KAJ(A;B) liveras je FALSA

=AĆŹ(A;B) liveras je VERA

=NE(KAJ(A;B)) liveras je VERA

XOR

Returns true if an odd number of arguments evaluates to TRUE.

The arguments are either logical expressions themselves (TRUE, 1<5, 2+3=7, B8<10) that return logical values, or arrays (A1:C3) containing logical values.La argumentoj estas aĆ­ logikaj esprimoj (VERA, 1<5, 2+3=7, B8<10) kiuj liveras logikajn valorojn, aĆ­ tabeloj (A1:C3) kiuj enhavas logikajn valorojn.

tip

Ĉi tiu funkcio disponeblas ekde versio 4.0 de LibreOffice.


Sintakso

XOR(Logical 1 [; Logical 2 [; 
 [; Logical 255]]])

Logical 1, Logical 2, 
 , Logical 255 are boolean values, references to cells or to cell ranges of logical values.

Ekzemplo

=XOR(TRUE();TRUE()) returns FALSE

=XOR(TRUE();TRUE();TRUE()) returns TRUE

=XOR(FALSE();TRUE()) returns TRUE

Bonvolu subteni nin!