Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create new tangent type for MajoranaReg? #7

Open
jlbosse opened this issue Dec 12, 2022 · 0 comments
Open

Create new tangent type for MajoranaReg? #7

jlbosse opened this issue Dec 12, 2022 · 0 comments
Assignees

Comments

@jlbosse
Copy link
Collaborator

jlbosse commented Dec 12, 2022

In order to get backward mode AD working I had to add the function :(*)(number::Real, reg::MajoranaReg) which is only a sensible operation if reg is a (co-)tangent register and not sensible if it is the primal register. This opens up potential incosistencies because we can do
expect(op, a * reg) but this doesn't satisfy expect(op, a * reg) == a * expect(op, reg).

One possible solution here is to add a TangentMajoranaReg type and only allow multiplication
with a scalar for that one.

@jlbosse jlbosse self-assigned this Dec 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant