FRED Scripting Archives Tag

Configuration Selection Tool

FRED Optimum supports multiple configurations within a single FRED document using the configuration editor interface found in the FRED menu, Optimize > System Configurations. The configuration editor dialog allows for the definition of multiple configuration variables as well as a mechanism for setting the current...

Read More

Linking Scripts to Toolbar buttons

There is a feature in FRED called “User Tools” which enables you to link your custom scripts to buttons on software’s main toolbar. Thus, by simply pressing the corresponding toolbar button you will be able to run your custom script tool. This article goes through the...

Read More

2D Plotting in FRED

The purpose of this article is to describe two scripts which work together to demonstrate how to plot multiple data series in a custom FRED chart. The FRED file associated with this document contains two embedded scripts: chartLibraryExampleMaster – This script generates a user-specified number of Gaussian profiles...

Read More

RPC Photonics Diffuser BSDF

RPC Photonics has high quality BSDF measurement data available for their engineered diffuser products and it turns out that with a little help the data is essentially already prepared for use in FRED.  The steps below describe how to use the attached FRED script to...

Read More

Direction Spot Diagram Statistics

As of version 14.40 there is no script command equivalent to the directions spot diagram analysis available in the GUI. This knowledge base article details a script utility which manually performs the equivalent directions spot diagram analysis in the scripting language. Download the PDF: Direction-Spot-Diagram-Statistics.pdf Download the FRED...

Read More

Plotting in Excel using COM

The purpose of this document is to describe two scripts which demonstrate the generation of a Gaussian dataset and a data plotting routine that routes data from FRED to Excel directly via COM.  Although the primary intention of this article is to demonstrate how to...

Read More

Animating FRED Results

Many FRED analysis tasks involve some sort of parameterized scan through a set of system configurations and I have found that compiling FRED results as an animated image set is particularly useful for conveying the dynamic behavior of the system output. At the time of...

Read More

Compute Distance Between Objects

The attached FRED file contains an embedded script which shows how you can calculate the distance between two objects using the scripting language. The script works by using the TransformPosition command, which takes a starting coordinate system, a new coordinate system and a position vector...

Read More

Rotating an Object in Scripting

The attached FRED file demonstrates how to use the scripting language to rotate an object through some range of angles in a loop.  Conceptually, the setup is very simple.  We have a focusing ray bundle which passes through a beamsplitter cube down to a detector....

Read More

List Surfaces with Assigned Coating

While making FRED models that had many surfaces and a few different coatings applied throughout the system, I noticed that it became very time consuming to verify that all of the coatings are applied to the correct surfaces since it can only be done surface by surface. The example...

Read More