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

how to do automatic simplification (tries)? #49

Open
RobG-LHind opened this issue Aug 29, 2024 · 3 comments
Open

how to do automatic simplification (tries)? #49

RobG-LHind opened this issue Aug 29, 2024 · 3 comments

Comments

@RobG-LHind
Copy link

Hello & thank you for your library on this interesting topic.

sorry, if I may miss the obvious (this is my first contact to julia-libraries).

I created a simple all-to-all graph for 4 qbits:

grafik

as far as I understand, the simplest implementation to a unit-disk graph should be just 2x2 atoms connected to each other (left upper corner). surely the automatic mapping creates something much more complicated (unweighted_res = map_graph(graph; vertex_order=MinhThiTrick());):

grafik

how do I apply simplification on this mapping?
i tried
unweighted_res2 = map_graph( UnWeighted(), graph, vertex_order=MinhThiTrick(), ruleset=UnitDiskMapping.default_simplifier_ruleset(UnWeighted()))
(did not find functions for vertex-reordering).

@GiggleLiu
Copy link
Collaborator

GiggleLiu commented Aug 30, 2024

The reduction in this package is a generic one. Although the method claims to be "optimal up to a constant factor", which can be far from the optimal.

Post-processing based on the mapped graph may help. However, it is not considered a lot in this package.

@RobG-LHind
Copy link
Author

Thank you @GiggleLiu for your quick response.
Do I understand you right, that this was the right approach:

unweighted_res2 = map_graph( UnWeighted(), graph, vertex_order=MinhThiTrick(), ruleset=UnitDiskMapping.default_simplifier_ruleset(UnWeighted()))

and that those rulesets (and maybe added rulesets by me) are working on the grid-(string-)representation (local?)?

is there / do you have an example of using methods of simplifiers.jl on a grid > (4,3) (as in tests)?

@GiggleLiu
Copy link
Collaborator

GiggleLiu commented Aug 31, 2024

Thank you @GiggleLiu for your quick response. Do I understand you right, that this was the right approach:

unweighted_res2 = map_graph( UnWeighted(), graph, vertex_order=MinhThiTrick(), ruleset=UnitDiskMapping.default_simplifier_ruleset(UnWeighted()))

and that those rulesets (and maybe added rulesets by me) are working on the grid-(string-)representation (local?)?

is there / do you have an example of using methods of simplifiers.jl on a grid > (4,3) (as in tests)?

You are right. The simplification rules will be applied repeatedly and locally on the grid. Currently, only the rule of removing dangling edges are considered in the package. I think the grid size is not an issue.

Here is an example of calling simplifier explicitly:

ug3, tape2 = apply_simplifier_gadgets!(copy(ug2); ruleset=[RotatedGadget(UnitDiskMapping.DanglingLeg(), n) for n=0:3])

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

2 participants