<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Nov 23, 2015, at 10:37 AM, Pande, Ajay K <<a href="mailto:apande@albany.edu" class="">apande@albany.edu</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div id="divtagdefaultwrapper" style="font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; font-size: 12pt; background-color: rgb(255, 255, 255); font-family: Calibri, Arial, Helvetica, sans-serif;" class=""><div style="margin-top: 0px; margin-bottom: 0px;" class="">Hi Eric,</div><div style="margin-top: 0px; margin-bottom: 0px;" class=""><br class=""></div><div style="margin-top: 0px; margin-bottom: 0px;" class="">It does give me the numerical value of the dipole moment, but how do I generate the dipole vector in the pdb structure?</div><div style="margin-top: 0px; margin-bottom: 0px;" class=""><br class=""></div><div style="margin-top: 0px; margin-bottom: 0px;" class="">Thanks</div><div style="margin-top: 0px; margin-bottom: 0px;" class=""><br class=""></div><div style="margin-top: 0px; margin-bottom: 0px;" class="">Ajay</div></div></div></blockquote><div><br class=""></div>If you add the following two lines to the script it will print out the center of mass and dipole vector:</div><div><br class=""></div><div><span class="Apple-tab-span" style="white-space:pre"> </span>print “center of mass:”, com.data()</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>print “dipole:”, dipole.data()</div><div><br class=""></div><div>Make sure the lines are indented to the same level as the final print statement in the original script. With those values you can easily write a BILD format file that will draw an arrow from the center of mass to the (center of mass + dipole) and open that file to show the arrow. The BILD format is described here:</div><div><br class=""></div><div><a href="http://www.cgl.ucsf.edu/chimera/current/docs/UsersGuide/bild.html" class="">http://www.cgl.ucsf.edu/chimera/current/docs/UsersGuide/bild.html</a></div><div><br class=""></div><div>If you are doing this for <i class="">many</i> structures, it would be possible to modify the script itself to create/open the BILD file, but that would be significantly more work. But if you really need it let me know.</div><div><br class=""></div><div>—Eric</div><div><br class=""><blockquote type="cite" class=""><div class=""><div id="divtagdefaultwrapper" style="font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; font-size: 12pt; background-color: rgb(255, 255, 255); font-family: Calibri, Arial, Helvetica, sans-serif;" class=""><div style="margin-top: 0px; margin-bottom: 0px;" class=""><br class=""></div><div style="margin-top: 0px; margin-bottom: 0px;" class=""><br class=""></div><div style="margin-top: 0px; margin-bottom: 0px;" class=""><br class=""></div><div style="margin-top: 0px; margin-bottom: 0px;" class=""><br class=""></div><br class=""><br class=""><div style="" class=""><hr tabindex="-1" style="display: inline-block; width: 636.015625px;" class=""><div id="divRplyFwdMsg" dir="ltr" class=""><font face="Calibri, sans-serif" style="font-size: 11pt;" class=""><b class="">From:</b><span class="Apple-converted-space"> </span>Eric Pettersen <<a href="mailto:pett@cgl.ucsf.edu" class="">pett@cgl.ucsf.edu</a>><br class=""><b class="">Sent:</b><span class="Apple-converted-space"> </span>Thursday, November 19, 2015 7:56 PM<br class=""><b class="">To:</b><span class="Apple-converted-space"> </span>Pande, Ajay K<br class=""><b class="">Cc:</b><span class="Apple-converted-space"> </span><a href="mailto:Chimera-users@cgl.ucsf.edu" class="">Chimera-users@cgl.ucsf.edu</a><br class=""><b class="">Subject:</b><span class="Apple-converted-space"> </span>Re: [Chimera-users] calculating dipole moment of a protein in pdb</font><div class=""> </div></div><div class="">Hi Ajay,<div class=""><span class="Apple-tab-span" style="white-space: pre;"></span>The script referenced in this chimera-users archive message will compute it:</div><div class=""><br class=""></div><div class=""><a id="LPlnk627799" href="http://www.cgl.ucsf.edu/pipermail/chimera-users/2010-February/004780.html" class="">http://www.cgl.ucsf.edu/pipermail/chimera-users/2010-February/004780.html</a></div><div id="LPBorder_GT_14483037953820.4461792358501253" style="margin-top: 20px; margin-bottom: 20px; overflow: auto; width: 649px;" class=""><table id="LPContainer_14483037953810.7723616813367392" style="border-top-width: 1px; border-top-style: solid; border-top-color: rgb(204, 204, 204); border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(204, 204, 204); width: 519px; background-color: rgb(255, 255, 255); position: relative; overflow: auto;" class=""><tbody class=""><tr valign="top" style="border-spacing: 0px;" class=""><td class=""><div id="LPTitle_14483037953820.6295622129413163" style="top: 0px; margin-top: 8px; font-size: 21px; font-family: wf_segoe-ui_semilight, 'Segoe UI Semilight', 'Segoe WP Semilight', 'Segoe UI', 'Segoe WP', Tahoma, Arial, sans-serif; color: rgb(51, 51, 51); margin-left: 14px; margin-right: 14px;" class="">[Chimera-users] BCC CHARGES</div><div id="LPDescription_14483037953820.8486864722593821" style="margin-top: 8px; font-size: 13px; font-family: wf_segoe-ui_normal, 'Segoe UI', 'Segoe WP', Tahoma, Arial, sans-serif; color: rgb(102, 102, 102); margin-left: 14px; margin-right: 14px;" class="">I've attached a script that if you run it (File->Open, or "open ~/ dipole.py" [if it's in your home directory]) will print the dipole moments of all open molecular ...</div><div id="LPUrlContainer_14483037953820.514023261198443" style="margin: 8px 14px 10px; height: 18px; text-overflow: ellipsis; overflow: hidden; white-space: nowrap;" class=""><a target="_blank" href="http://www.cgl.ucsf.edu/pipermail/chimera-users/2010-February/004780.html" id="LPUrlAnchor_14483037953820.4094834771546695" style="font-size: 11px; font-family: wf_segoe-ui_normal, 'Segoe UI', 'Segoe WP', Tahoma, Arial, sans-serif; text-decoration: none;" class="">Read more...</a></div></td></tr></tbody></table></div><div class=""><br class=""></div><div class="">Extracting the script from that message may be challenging, so I’m attaching it again. It’s also available from our Chimera Scripts page:</div><div class=""><br class=""></div><div class=""><a href="http://plato.cgl.ucsf.edu/trac/chimera/wiki/Scripts" class="">http://plato.cgl.ucsf.edu/trac/chimera/wiki/Scripts</a></div><div class=""><br class=""></div><div class="">Like it says in the original message you have to assign partial charges before running the script (Tools->Structure Editing->AddCharge, or the “addcharge” command).</div><div class=""><br class=""></div><div class="">—Eric</div><div class=""><br class=""><div class=""><div class="" style="letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; word-wrap: break-word;"><div class=""><span class="Apple-tab-span" style="white-space: pre;"></span>Eric Pettersen</div><div class=""><span class="Apple-tab-span" style="white-space: pre;"></span>UCSF Computer Graphics Lab</div><div class=""><br class=""></div></div></div></div></div></div></div><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class="">_______________________________________________</span><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class="">Chimera-users mailing list</span><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><a href="mailto:Chimera-users@cgl.ucsf.edu" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class="">Chimera-users@cgl.ucsf.edu</a><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><a href="http://plato.cgl.ucsf.edu/mailman/listinfo/chimera-users" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class="">http://plato.cgl.ucsf.edu/mailman/listinfo/chimera-users</a><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""></div></blockquote></div><br class=""></body></html>