Welcome,
Share Files

Scripts 2

mirror(r, h, v, x, y, ac, ao, s, n=1, mode=1, f=0.8): Plots the reflected light beams by a spherical mirror.
r - radius of the mirror, if r>0 the inner part of the mirror is reflective, if r<0 the exterior part of the mirror is reflective
h - x-position of the center of the mirror
v - y-position of the center of the mirror
x=x1 x-position of the origin of the beam (only one beam)
x=[x1,x2,...,xn] x-position of the origin of the beams 1,2,...,n (one or more beams)
y=y1 y-position of the origin of the beam (only one beam)
y=[y1,y2,...,yn] y-position of the origin of the beams 1,2,...,n (one or more beams)
ac - angle of center of the opening of the mirror
ao - opening angle of the mirror
s - number of light beams
n - maximum number of reflections
mode=0 hides the incident beams and hides the origin of the beam
mode=1 shows the incident beams and shows the origin of the beam
mode=2 hides the incident beams and shows the origin of the beam
f - reflection index of the mirror