跳到主要内容

CSC

Returns the cosecant of an angle.

Syntax

expression.CSC(arg1);

expression - A variable that represents a ApiWorksheetFunction class.

Parameters

NameRequired/OptionalData typeDefaultDescription
arg1RequiredApiRange | ApiName | numberThe angle in radians for which the cosecant will be returned.

Returns

number

Example

This example shows how to get the cosecant of an angle.

// How to return cosecant.

// Use function to get the cosecant of an angle.

let worksheet = Api.GetActiveSheet();
let func = Api.GetWorksheetFunction();
worksheet.GetRange("A1").SetValue(func.CSC(0.785398));