Comments (9)
HI @yu289333 --- You are correct, P([l]) is the power set of the first l integers. Where it is not defined?
from thewalrus.
Then |S| is the number of elements in set S? Thank you so much for explaining.
from thewalrus.
Correct.
from thewalrus.
Sorry for asking all the questions. I'm on the physics side and am overwhelmed by all the math. For N=2, and vector_n = {1, 0}, O{n} should be a 2x2 matrix, it's not possible to go over S∈P([ℓ]), right? Where do I get wrong?
from thewalrus.
For a Two Mode Squeezed State (TMSS), the probability of the |0>0> Fock state is 1-[tanh(r)]^2. I'm having trouble verifying with the torontorian result for vector_n={0,0}
from thewalrus.
And for vector_n={0,1} and {1,0}, the probability is (x-1)/x.(x+ln(1-x)) where x=[tanh(r)]^2. I hope to compare with the torontorian result.
from thewalrus.
Hi --- The easiest way to calculate these probabilities is to use threshold_detection_prob
. For a two mode squeezed vacuum state you can do
import numpy as np
from thewalrus.symplectic import two_mode_squeezing
from thewalrus._torontonian import threshold_detection_prob
n_mean = np.arcsinh(1.0)
cov = two_mode_squeezing(2*n_mean, 0)
mean = np.zeros([4])
patterns = [[0,0], [0,1], [1,0], [1,1]]
probs = [threshold_detection_prob(mean, cov, pat) for pat in patterns]
for i, pat in enumerate(patterns):
print("The probability of the event "+str(pat)+" is "+str(probs[i]))
to get
The probability of the event [0, 0] is (0.4999999999999999+0j)
The probability of the event [0, 1] is (1.1102230246251563e-16+0j)
The probability of the event [1, 0] is (1.1102230246251563e-16+0j)
The probability of the event [1, 1] is (0.5000000000000001+0j)
As for your question
Sorry for asking all the questions. I'm on the physics side and am overwhelmed by all the math. For N=2, and vector_n = {1, 0}, O{n} should be a 2x2 matrix, it's not possible to go over S∈P([ℓ]), right? Where do I get wrong?
in that case [ℓ] = [2] = [0,1]
and the P[ℓ] = [[], [0], [1], [0,1]]
from thewalrus.
Thanks. I forgot to mention that my trouble is to calculate the results of TMSS photons going through a symmetric beam splitter to compare with the original Hong-Ou-Mandel experiment.
from thewalrus.
You can generate the relevant covariance matrices either using the symplectic
module or Strawberry Fields. Once you have the covariance matrix you can pass them to threshold_detection_prob
as above.
from thewalrus.
Related Issues (20)
- Convenience functions to change ordering of quadratures HOT 1
- Why is hbar=2? Physicist may assume hbar=1 HOT 1
- [Thewalrus documentation] The figures in "Basics of Hafnians and Loop Hafnians" are missing HOT 7
- Random interferometer is already implemented in scipy
- [Thewalrus installation] Can not install the version later than 0.15.0 HOT 11
- Add support for calculating the permanent using the BBFG algorithm HOT 4
- Recursive calculation of threshold probabilitites HOT 4
- FTBFS 0.16.2 on aarch64 HOT 5
- I have searched exisisting GitHub issues to make sure the issue does not already exist. HOT 1
- The Qmat functions is off by a complex conjugate
- Library hard crashing when computing BBFG permanent with a 0x0 matrix HOT 4
- Optional arguments in `passive_transformation`
- n_body_marginals is not symmetric
- Displaced torontonian sampling time increase HOT 11
- Tests fail to run: error: unrecognized arguments: --randomly-seed=137 HOT 1
- Banded hafnian algorithm HOT 1
- RuntimeWarning: divide by zero encountered in det HOT 9
- Default method fails on poorly conditioned matrices HOT 4
- Glynn method has an weird prefactor HOT 1
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 thewalrus.