Comments (2)
I have written this, but it is ugly:
def AstigGaussBeam(Fin, wx, wy, x_shift=0, y_shift=0, tx=0, ty=0):
if wx == wy:
return LightPipes.GaussBeam(Fin=Fin, w0=wx, x_shift=x_shift, y_shift=y_shift, tx=tx, ty=ty)
Ex = LightPipes.GaussBeam(Fin=Fin, w0=wx, x_shift=x_shift, y_shift=0, tx=tx, ty=0)
Ey = LightPipes.GaussBeam(Fin=Fin, w0=wy, x_shift=0, y_shift=y_shift, tx=0, ty=ty)
Ix = LightPipes.Intensity(Ex,0)
Iy = LightPipes.Intensity(Ey,0)
Phix = LightPipes.Phase(Ex)
Phiy = LightPipes.Phase(Ey)
(Nx, Ny) = Ix.shape
nmidx = int(_np.round(Nx/2))
nmidy = int(_np.round(Ny/2))
Ix = Ix[nmidy,:]
Ix = _np.tile(Ix, (Ny, 1))
Iy = Iy[:,nmidx]
Iy = _np.tile(Iy, (Nx, 1)).T
Phix = Phix[nmidy,:]
Phix = _np.tile(Phix, (Ny, 1))
Phiy = Phiy[:,nmidx]
Phiy = _np.tile(Phiy, (Nx, 1)).T
Eout = LightPipes.SubIntensity(Fin=Fin, Intens=sqrt(_np.multiply(Ix,Iy)))
Eout = LightPipes.SubPhase(Fin=Eout, Phi=Phix+Phiy)
return Eout
from lightpipes.
Have you tried maybe using Zernike polynomials for this purpose? There is Zernike polynomials info in the manual.
from lightpipes.
Related Issues (20)
- Add Interpol option in Fresnel and Forvard HOT 1
- Warning when paraxiality is violated HOT 2
- Shift with direct integration Forward
- Diffraction From Thin Wire HOT 4
- Step by Step Propagation With a Short Focal Length Lens HOT 3
- LightPipes on an iPad
- LPtest() fails on some systems while installation is correct HOT 1
- Intensity plot gets cut up when attempting to propagate finite airy beam HOT 9
- Cite lightpipes in a paper HOT 2
- lens Following Field Produced by Forward Function
- Airy Beam HOT 6
- LG doughnut mode HOT 4
- Microwave frequencies HOT 3
- A doc example of D4sigma seems to call Centroid instead of D4sigma HOT 1
- LensFarfield in lenses.py but not in __init__.py and documentation HOT 2
- Michelson interferometer with the Zernike aberration HOT 4
- Bessel Beam Simulation from an annulus of light HOT 4
- interference pattern with a focused x-ray beam (spherical coordinates propagation & Steps) HOT 1
- Calculate the power( ratio) in the bucket and times the diffraction limit
- Strehl ratio formula
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from lightpipes.