Navigation: Scripting Reference Manual > Functions & Subroutines > AddConic

 

AddConic

 

Contact Us: fredsupport@photonengr.com

 

Description

Adds a Conic surface to the associated FRED document.

 

Syntax

n = AddConic ( entity, curv, conic )

 

Parameters

n (Long)

Node number of the new Conic surface.

 

entity As T_ENTITY

The generic entity data for the new Conic surface.

 

curv As Double

The curvature of the new Conic surface.  (cv=1/radius)

 

conic As Double

The conic constant of the new Conic surface.  0=sphere, -1=parabola, <-1=hyperbola, etc.

 

 

Remarks

This function adds a Conic surface to the associated FRED document and returns the identifier of the new surface.  If there is a problem, the error is reported and the function returns a value of -1.

 

The sag equation of the surface is

 

where  

r = Sqrt( x2 + y2)

 

See Also

T_ENTITY

SetConic

GetConic

Examples

Surfaces

 

 

 

 

 

Copyright © Photon Engineering, LLC