Simple example on how to compute the power loss at a circular aperture.

```
# Finesse 2 example
# Detecting the power loss at a mirror with
# an aperture as a function of the aperture seize
# Beam radius = 1mm
# Andreas Freise, 13.11.2019
l l1 1 0 n1
gauss g1 l1 n1 1m -1
s s1 1 n1 n2
m m1 0.5 0.5 0 n2 n3
s s2 1 n3 n4
maxtem 0
pd refl n2
noplot refl
set Pr refl re
pd trans n3
noplot trans
set Pt trans re
func PowerLoss = 1 - $Pr - $Pt
yaxis log abs
xaxis m1 rap lin 0.2m 3m 100
pyterm pdf
```

Slightly off topic, but can use dummy variables to tune the ration between the mirror and beam radius:

```
var ratio 1 # define ratio as dummy variable
set _ratio ratio re # this is requires for the func command
func rap = $_ratio * 0.001 # compute the aperture size
noplot rap # we don't want to plot the aperture size
put m1 rap $rap # set the aperture
xaxis ratio relsize lin 0.2 3 100 # now we can tune the ratio
```

Note that the second parameter in the xaxis command (‘relsize’) is just a random string when you use xaxis with a dummy variable.

Parameter handling will be much improved in Finesse 3, see for example this post.

In situations like this one, is there a simple way to express the x axis in dimensionless units automatically with Finesse? (Such as rap/spot_size for this case)

Also “# Mirror radius = 1m” should be beam size.

Thank, you I’ll fix the comment on the beam radius.

Yes you can use a dummy variable to tune the ratio between mirror size and beam size, I’ll add the example code above as well.