Vous êtes sur la page 1sur 3

Rui, GUO Kelen.guo@gmail.


How to Use the Program in ASAP

1. Main Function
Pyramid is the main function, which will call the other functions, for example MACROS.

2. Input
The geometry parameters are defined in MACROS function, in which you can change the size of the object, the position and the number of light, and the position of the rectangle. "COATINGS PROPERTIES
1.00000 0 0.000000 0 'REFLECT' 'ABSORB'"

Define the property of the surfaces. "UNITS MILLIMETER


Define the basic physical parameters. "CURVES

LINE 10.00000 -10.00000 LINE 10.00000 10.00000 17.32051 LINE 0.000000 0.000000 0.000000 COMPOSITE GAP -1 -1 OBJECT =1 INTERFACE COATING "REFLECT" SCATTER MODEL 1 TOWARDS EDGE 1 5" 0. 10.00000 0.000000 17.32051 10.00000 0.000000 10.00000 0. 0.000000 -10.00000

It shows part of the geometry information. These sentences will be automatically generated when you import the object, which can be built in Solidworks or other compatible applications.

This sentence needs to be added every time after the description of the curve. It means five rays will be created from every light point.
"EMITTING DISK -X 60 0 0 500 15 15 ROTATE Z -25 SHIFT Z 5 SHIFT Y -30"

A point of light is in its original position X -60, with 500 rays; the angle is 15 in two directions. First rotate round z, then shift it along z for 5 units then shift it along y for -30 units
"RECTANGLE Z 0 0.001 0.001"

Define the size of one pixel.

Rui, GUO Kelen.guo@gmail.com

3. loop


Define the distance the pixel moved

"1 100"

It means that the loop will be done for 100 times. And finally we will get a CCD of size 100*100.

4. Output data
RAYDATA_kom.txt RAYDATA_int.txt

These two documents will be automatically created in your folder. The information of amplitude and phase angle is in file RAYDATA_kom.txt And the intensity of the ray is in file RAYDATA_int.txt

Every time when you want to regenerate the two files, make sure the old files are deleted; otherwise the data will accumulate and lead to wrong results!

Rui, GUO Kelen.guo@gmail.com

How To Use The Program In MATLAB

1. Purpose
The MATLAB-program is used to reorganise the data from ASAP and finally get a graphic based on physical optics theory.

2. Data

RAYDATA_kom=load('U:\privat\ASAP\RAYDATA_kom.txt'); RAYDATA_int=load('U:\privat\ASAP\RAYDATA_int.txt');

Input the data from related file, the path is changeable.

c=mat2cell(RAYDATA_kom, 10000, [2 1])

the number 100 is changeable according to the size of CCD. For example, when in ASAP the size is 100*100, then here will be 10.000
matrix_int=reshape(a,100,100) matrix_kom=reshape(reform_kom,100,100)

the numbers above should be correct according to the settings of CCD.

3. Result
Run the program and finally you will get a picture of CCD and the other information about the data.