..where we discuss density operators wrt SymPy

Category: Uncategorized

Week 6 : Tr implementation contd…

This week I continued to work on the Tr operator and the related code needed for partial trace operations.  Following up with the list of tasks I had listed out for this week, I got the following items accomplished this week.

1. PR 1333 merged

2. Submitted PR 1396  for review :

This PR has the following changes:

1. Printing ( default, latex and pretty).  The current output does not display the indices.  I would like some input on this from the reviewers on how to incorporate the information on indices into the output.

2. Handles indices in the constructor of Density class and related methods.

3. Handle partial trace operations especially wrt to Density operators.

4. Notebook example, some of which are listed below:

The activities I have in mind for next week are as follows.

1.  Address review comments on latest PR.

2.  Complete the test cases for existing partial trace implementation for Qubits. My plan is to get this changes merged with the current PR. This should happen by Tuesday.

With these 2 activities, I believe most of what is needed for Tr and density matrices could be considered complete. Again, I expect  @ellisonbg and @flacjacket to provide some input on this.   Assuming, this is true, then I plan to start looking at

3. qapply() method to incorporate density op L and R operations.


BTW, for Emacs lovers and who love IPython Notebook, there is IPython notebook for Emacs now. I have not tried this yet,  but I plan to try this out this week and post my experience.

Happy coding!


Week 5 : Tr class implementation

I had not blogged during last week since I was away at the summer school where I had an opportunity to listen to and talk to both physicists and cs theorists working on the next quantum computer! There were  great presentations and the videos should be available shortly. So, now back to Sympy!

Tasks accomplished this week

My main tasks for this week was to address all comments on pending PR 1333. In addition I had planned to complete printing operations on Tr operator and get started with qubit related Tr operations.  I accomplished the task on addressing comments on PR 1333 and also completed basic printing operations along with having the notebook examples done.  The changes outside of PR 1333 are available in my githhub branch(trace_permute_equal) and I plan to submit a PR for these changes as soon as PR 1333 is merged.

In addition I worked on providing a permute() function and also had to play around with implementation of overriding _hashable_contents() method.  I had spend some time in figuring out the details of such an implementation and there was some discussion on this on the mailing list.  For now, I have these 2 functions implemented ( but commented out) in branch trace_permute_equal.

Therefore, one task that remained but which I could not get to this week was qubit implementation related to Tr.  Also, currently I am in the process of writing up how Tr operations should work on TensorProducts. I should have a write up very soon.

The tasks for next week, therefore would be  (roughly in this order)

1. Share a write up on TensorProduct wrt to Tr operations.

2. Push qubit related changes to my git repo

3. Get started on TensorProduct/Tr and have the first cut ready for review.

4 Get PR 1333 merged.

5. Get branch trace_permute_equal merged. This branch has minor changes and I hope to get this merged as well this week.

Happy coding!

Selected for GSOC 2012

It feels great to be one of the participants chosen to participate in this year’s GSOC.  This blog will continue to have updates regarding my progress through the summer.