Re: Second quantization with fermionic operators

2009-11-30 Thread Øyvind Jensen
Nice, Ondrej! Thanks for spending time on this! I remember at one point implementing a trivial .doit() to prevent a crash further up. I was not that familiar with the code at the time, so I didn't want to mess around with the core. It should ideally be removed. Øyvind sø., 29.11.2009 kl.

Re: Second quantization with fermionic operators

2009-11-23 Thread Ondrej Certik
On Tue, Nov 17, 2009 at 2:10 PM, jegerjensen jensen.oyv...@gmail.com wrote: Hi, I know you guys are busy... But do you have an approximate schedule for when the patches may go into trunk? Ondrej, do you disagree with the previous posts? I agree with previous posts. The patches can go in

Re: Second quantization with fermionic operators

2009-11-23 Thread Ondrej Certik
On Mon, Nov 23, 2009 at 1:47 PM, Ondrej Certik ond...@certik.cz wrote: On Tue, Nov 17, 2009 at 2:10 PM, jegerjensen jensen.oyv...@gmail.com wrote: Hi, I know you guys are busy... But do you have an approximate schedule for when the patches may go into trunk? Ondrej, do you disagree with the

Re: Second quantization with fermionic operators

2009-11-23 Thread Ondrej Certik
On Mon, Nov 23, 2009 at 1:50 PM, Ondrej Certik ond...@certik.cz wrote: On Mon, Nov 23, 2009 at 1:47 PM, Ondrej Certik ond...@certik.cz wrote: On Tue, Nov 17, 2009 at 2:10 PM, jegerjensen jensen.oyv...@gmail.com wrote: Hi, I know you guys are busy... But do you have an approximate schedule

Re: Second quantization with fermionic operators

2009-11-23 Thread Øyvind Jensen
The failed assertion XYZ should simply be removed. It fails because of the platform-dependent hash, and is not relevant any more. It used to be relevant when I tried to use the relation [[A,B],C] + [[C,A],B] + [[B,C],A] = 0 to enforce a canonical nesting of commutators. I couldn't

Re: Second quantization with fermionic operators

2009-11-23 Thread Ondrej Certik
On Mon, Nov 23, 2009 at 3:15 PM, Øyvind Jensen jensen.oyv...@gmail.com wrote: The failed assertion XYZ should simply be removed.  It fails because of the platform-dependent hash, and is not relevant any more. It used to be relevant when I tried to use the relation        [[A,B],C] +

Re: Second quantization with fermionic operators

2009-11-17 Thread jegerjensen
Hi, I know you guys are busy... But do you have an approximate schedule for when the patches may go into trunk? Ondrej, do you disagree with the previous posts? Øyvind On 27 Okt, 21:54, Brian Granger ellisonbg@gmail.com wrote: I am fine with this plan.  It will be good to get it in.

Re: Second quantization with fermionic operators

2009-10-27 Thread Øyvind Jensen
I disabled the failing doctest and pushed a commit to the branch wick3 in my repo. I am also extremely busy, so I am afraid I cannot spend much more time on this right now. It seems though, that from a user perspective, the missing documentation strings are not that important. And from a

Re: Second quantization with fermionic operators

2009-10-27 Thread Brian Granger
I am fine with this plan. It will be good to get it in. Brian On Tue, Oct 27, 2009 at 1:39 PM, Øyvind Jensen jensen.oyv...@gmail.comwrote: I disabled the failing doctest and pushed a commit to the branch wick3 in my repo. I am also extremely busy, so I am afraid I cannot spend much more

Re: Second quantization with fermionic operators

2009-10-22 Thread Ondrej Certik
Hi, I don't have time to finish the doctests myself, but on the other hand I don't want to hold this anymore either. The current status is: $ bin/coverage_doctest.py sympy/physics/secondquant.py -- sympy/physics/secondquant.py

Re: Second quantization with fermionic operators

2009-10-18 Thread jegerjensen
I just pushed some of the trivial fixes to github, please pull. Ondrej, I fixed the 'str' variable as well. Øyvind On 15 Okt, 18:54, Brian Granger ellisonbg@gmail.com wrote: On Thu, Oct 15, 2009 at 2:26 AM, Øyvind Jensen jensen.oyv...@gmail.comwrote: Brian, thanks for your

Re: Second quantization with fermionic operators

2009-10-18 Thread jegerjensen
And another push... I overlooked the substitution Wicks - wicks. Øyvind On 18 Okt, 22:51, jegerjensen jensen.oyv...@gmail.com wrote: I just pushed some of the trivial fixes to github, please pull. Ondrej, I fixed the 'str' variable as well. Øyvind On 15 Okt, 18:54, Brian Granger

Re: Second quantization with fermionic operators

2009-10-15 Thread Øyvind Jensen
Brian, thanks for your input! I will make that Exception baseclass, and raise those NotImplementedErrors. I'll do it the coming weekend. I really like your idea of implementing the particle/hole stuff on a higher level, and creating algorithms independent of boson/fermi formalism. That is a

Re: Second quantization with fermionic operators

2009-10-13 Thread jegerjensen
I implemented lots of doctests, and pushed to my new github account: git://github.com/jegerjensen/sympy.git There is still some doctests missing, but I think all the important stuff is covered. Øyvind --~--~-~--~~~---~--~~ You received this message because you

Re: Second quantization with fermionic operators

2009-10-13 Thread Ondrej Certik
I also got this doctest failure: ___ sympy.physics.secondquant.Wicks File /home/ondrej/repos/sympy/sympy/physics/secondquant.py, line 2559, in sympy.physics.secondquant.Wicks Failed example: Wicks(Fd(p)*(F(q)+F(r)), keepOnlyFullyContracted=True)

Re: Second quantization with fermionic operators

2009-10-12 Thread Ondrej Certik
Hi, so I gave it a more thorough look, here is how to play with it: git clone git://github.com/certik/sympy.git cd sympy git checkout -b wick2 origin/wick2 In general I think it looks good and I only have couple minor comments below, after fixing them, let's commit it, so that it's in and we

Re: Second quantization with fermionic operators

2009-10-12 Thread Øyvind Jensen
Nice! Here are patches for the quick and easy stuff. They can be applied to the branch you posted. I also noticed some other small issues, and they are corrected in the patches. 4) please use explicit imports in the example. Then it would be clear that the import: from

Re: Second quantization with fermionic operators

2009-10-12 Thread Ondrej Certik
On Mon, Oct 12, 2009 at 8:41 AM, Ondrej Certik ond...@certik.cz wrote: On Mon, Oct 12, 2009 at 4:51 AM, Øyvind Jensen jensen.oyv...@gmail.com wrote: Nice! Here are patches for the quick and easy stuff.  They can be applied to the branch you posted.  I also noticed some other small issues,

Re: Second quantization with fermionic operators

2009-10-09 Thread Ondrej Certik
On Thu, Oct 8, 2009 at 3:50 AM, jegerjensen jensen.oyv...@gmail.com wrote: Ooops! I have to correct myself: The reason I chose the sparse format for the Fermionic case was not because of storage considerations. Rather because I wanted to treat problems without depending on the number of

Re: Second quantization with fermionic operators

2009-10-09 Thread Alan Bromborsky
Ondrej Certik wrote: On Thu, Oct 8, 2009 at 3:50 AM, jegerjensen jensen.oyv...@gmail.com wrote: Ooops! I have to correct myself: The reason I chose the sparse format for the Fermionic case was not because of storage considerations. Rather because I wanted to treat problems without

Re: Second quantization with fermionic operators

2009-10-09 Thread Ondrej Certik
On Fri, Oct 9, 2009 at 12:52 PM, Alan Bromborsky abro...@verizon.net wrote: Ondrej Certik wrote: On Thu, Oct 8, 2009 at 3:50 AM, jegerjensen jensen.oyv...@gmail.com wrote: Ooops! I have to correct myself: The reason I chose the sparse format for the Fermionic case was not because of

Re: Second quantization with fermionic operators

2009-10-08 Thread Øyvind Jensen
Yes, I am aware of that. Thanks for your patches, I'll try it and see where the bottleneck is. Btw in your first patch, you seem to have a bogus line (with kwargs), which is not used anywhere, unless I am missing something. Ondrej That was indeed an error. It is fixed in this new patch.

Re: Second quantization with fermionic operators

2009-10-08 Thread Øyvind Jensen
Thanks for your swift responses, I've got some comments: * In various places you use the variable str. This is dangerous as str is a builtin type (a string). Absolutely, It should be substituted immediately. * It is a little awkward to have the occupation #'s stored differently for bosons

Re: Second quantization with fermionic operators

2009-10-08 Thread jegerjensen
Ooops! I have to correct myself: The reason I chose the sparse format for the Fermionic case was not because of storage considerations. Rather because I wanted to treat problems without depending on the number of particles and the size of the model space.  I believe the framework will be

Re: Second quantization with fermionic operators

2009-10-07 Thread jegerjensen
For what is worth, I also wrote a wick expansion in sympy, see my wick branch at github: http://github.com/certik/sympy/tree/wick if you run the t.py script in the root directory, it will save all the feynman diagrams to /tmp as png images. It only works for scalar bosons. Your wicks

Re: Second quantization with fermionic operators

2009-10-07 Thread Ondrej Certik
On Wed, Oct 7, 2009 at 4:38 AM, jegerjensen jensen.oyv...@gmail.com wrote: For what is worth, I also wrote a wick expansion in sympy, see my wick branch at github: http://github.com/certik/sympy/tree/wick if you run the t.py script in the root directory, it will save all the feynman

Re: Second quantization with fermionic operators

2009-10-07 Thread Aaron S. Meurer
I think git send-email doesn't work with gmail. Maybe there is a workaround, but I never figured it out, so I just send in my patches manually. Aaron Meurer On Oct 7, 2009, at 3:06 AM, Øyvind Jensen wrote: hmmm... I tried following the patches tutorial to send in my patches with 'git

Re: Second quantization with fermionic operators

2009-10-07 Thread Brian Granger
Øyvind, It will take me a while to go through everything, but I just read through some of it quickly. It all looks quite powerful and nice. One minor thing and one question: * In various places you use the variable str. This is dangerous as str is a builtin type (a string). * It is a little

Re: Second quantization with fermionic operators

2009-10-07 Thread Brian Granger
On Wed, Oct 7, 2009 at 4:19 PM, Ondrej Certik ond...@certik.cz wrote: On Wed, Oct 7, 2009 at 3:46 PM, Brian Granger ellisonbg@gmail.com wrote: Øyvind, It will take me a while to go through everything, but I just read through some of it quickly. It all looks quite powerful and

Re: Second quantization with fermionic operators

2009-10-06 Thread jegerjensen
Thanks, it sure is great to see your enthusiasm :-) It turned out I have made two small changes elsewhere in the code, so I made a total of 4 patches, and I will try to send them in now. About using the Coupled Cluster example as a unit test: On my laptop (from 2005) it takes about 2-3

Re: Second quantization with fermionic operators

2009-10-06 Thread Ondrej Certik
Hey Øyvind, On Tue, Oct 6, 2009 at 12:07 PM, jegerjensen jensen.oyv...@gmail.com wrote: Thanks, it sure is great to see your enthusiasm :-) It turned out I have made two small changes elsewhere in the code, so I made a total of 4 patches, and I will try to send them in now. About using

Second quantization with fermionic operators

2009-10-05 Thread jegerjensen
Hi all, I have implemented a framework for working with fermionic second quantization operators with Sympy and I'd like to submit patches for incorporation in the project. I have tried to reuse the existing Bosonic framework when applicable, and have ended up with code that reproduces a lot

Re: Second quantization with fermionic operators

2009-10-05 Thread Ondrej Certik
Hi! On Mon, Oct 5, 2009 at 12:15 PM, jegerjensen jensen.oyv...@gmail.com wrote: Hi all, I have implemented a framework for working with fermionic second quantization operators with Sympy and I'd like to submit patches for incorporation in the project. I have tried to reuse the existing

Re: Second quantization with fermionic operators

2009-10-05 Thread Brian Granger
Great! I haven't had a chance to work on this for about a year, but Ondrej and I were just talking last week how it would be nice to push this forward more. I have implemented a framework for working with fermionic second quantization operators with Sympy and I'd like to submit patches