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

Handle single basis in embed #24

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

a-eghrari
Copy link

@a-eghrari a-eghrari commented Jun 12, 2024

This commit addresses the issue where the embed function fails when it receives a single basis instead of a composite basis as input. This issue has been discussed in QuantumOpticsBase.jl's issues #159.

This commit addresses the issue where the `embed` function fails when it receives a single basis instead of a composite basis as input.
@a-eghrari
Copy link
Author

This seems to create an ambiguity when we call, for example

embed(FockBasis(2) ⊕ FockBasis(2), 1, create(FockBasis(2)))

One way is to add type assserstion to the ops argument of the definition of embed(b::SumBasis, indices, ops) in file bases.jl

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

Successfully merging this pull request may close these issues.

1 participant