Skip to main content

Helllo, 

I was converting a codeV to zemax file and the vignetting factors won’t convert correctly. Could someone tell me how to manually calculate and find what the zemax VDX and VXC values for this field  in codeV would be?

XAN 0.616    YAN 0.0    VUX 0.2436505794   VLX  0.0    VUY 0.0   VLY0.0

I can’t calculate the zemax vignetting factors VDX and VCX! 

thanks!

Hi Nafiseh,

I want to first point out that there is not a 1:1 conversion between CodeV vignetting factors and OpticStudio vignetting factors:

  • CodeV:
    • Individually control the 4 marginal rays
    • Always has the pupil ellipse axis oriented with the object space X/Y axis
  • OpticStudio:
    • X & Y marginal ray are paired together
    • Compression (VCxy) controls the shape of the pupil (ellipse vs circle)
    • Decenter (VDxy) affects the chief ray
    • TAN can rotate the pupil ellipse axis with respect to the object space X/Y axis

So while we can converter the marginal rays accurately from CodeV to OpticStudio, the chief ray will be affected.  Extreme care should be taken in analysis which use Chief Ray as the reference; if VDxy is ever used in the Field Data Editor, then either Ignore Vignetting Factors or Centroid Reference should be used for analysis.

To convert from CodeV to OpticStudio, the equations are as follows:

  • VCX = (VLX + VUX) / 2
  • VCY = (VLY + VUX) / 2
  • VDX = (VLX - VUX) / 2
  • VDY = (VLY - VUY) / 2

thank you for your response! using these formulas you provided I calculated the values and entered it manually.

The wavefront map in CodeV shows the beam is clipped in the right side while the zemax doesn’t clip the beam. Is there any setting I need to change so the beam gets clipped? I realized if I multiply all 4 vignetting values by -1 the beam gets clipped but what does a negative vcx even mean? 


A negative vcx would mean the pupil getting larger. How is the aperture of the lens defined in the CodeV and OS files?


Just thinking about this some more…

Vignetting factors are (at least in OS) an ad-hoc way to describe field-dependent pupil shapes. The notionally circular pupil becomes a decentered ellipse. This is fine for a lot of work, but to be sure you model the real pupil accurately you should remove the VFs, put a hard aperture on the Stop, and increase the aperture slightly so you are overfilling the pupil. This will waste some rays, but ensure that the pupil is completely sampled at all fields.

I don’t know how CodeV does this, but I’m sure they do it well. But we may be comparing two ways to approximate the pupil shape. It may be better if you’re really concerned about this to simply overfill the pupil.

Just a thought,

  • Mark

this is the codeV .seq file for one of the lenses;

S     -454.6548 0.0 REFL
  SLB "primary"
  CIR 36.0
  ADY -106.74
  CIR EDG 40.0
  ADY EDG -106.74
  CON
  K   -0.827158
  CUM 0.0; THM 12.7

My Zemax model aperture was set to 40 at first which I think wasn’t correct so I set it to a circular aperture with radius 36 and decenter -106.74 I also forced the semi-diameter to be 36.


I’m afraid I don’t read CodeV 😎but when you ran the Convertor, did it give any error messages?


Only the vignetting values were too many sig. figs so I had to reduce them to 14 decimals. and some of the apertures had ELX and ELY which I assumed are the edges but I entered the clear apertures manually and they should be correct. 


Reply