Page 1 of 1

About the plot-excitondb.py

Posted: Sun Jan 23, 2022 5:54 pm
by Quxiao
Dear all:
When I use the plot-excitondb.py to plot,I find that,the distance of the x(the def plot_ax in the bandstructure.py) ,it seems that the length is calculated by using the points of the reciprocal space. Shouldn't the abscissa length of the normal energy band graph be calculated by converting it into Cartesian coordinates and then taking the module? It seems that I output the (x=self.distances) in plot_ax conforms to the point of reciprocal space, and the length is directly obtained as the abscissa. So, (x=self.distances) in plot_ax is the abscissa and comes from the distance function, while kpoints in the input distance function seem to be points in the reciprocal space, such as [0.5, 0.5, 0]. I don't know whether my current understanding is correct. Please give me some help.
For example:1、G :[0.0, 0.0, 0.0] ,S[0.5,0.5,0] ,the length of G-S is sqrt(2)*(0.5)[the abscissa is calculated by reciprocal space]
2、G:rlat*[0.0,0.0,0.0] S:rlat*[0.5,0.5,0] rlat is the reciprocal Lattice(RL) unit cell,
the length of G-S should be modulo in Cartesian coordinates and
However,I print the (x =self.distances in def plot_ax),then I find it is equal to sqrt(2)*0.5,which compound the first case.Then multiplied by a constant (such as unit system conversion, etc.), after I processed the output x=self.distances above, it is consistent with the abscissa of the energy band diagram obtained by wannier interpolation. Therefore, I think the x output of plot_ax It should be a simple addition of the values in the relative coordinate system. .
So, I am a little confused, am I understanding right? Is the data shown in this graph the way I understand it?
Finally,
But how do I change the script to get the distance I want in Cartesian coordinates? Because there are too many packages to call yambopy, I am not very skilled, I am not sure where to change the kpoint passed in the calculate_distances function, it seems to use the red_car function, please give me some help.
Thanks!
Best wishes
Quxiao

Re: About the plot-excitondb.py

Posted: Tue Jan 25, 2022 3:49 pm
by Quxiao
Dear all:
I have changed the code and solved the question.
Thanks,I like the yambopy which provided me a new method to use yambo code!
Best wishes
Quxiao
BIT

Re: About the plot-excitondb.py

Posted: Mon Feb 21, 2022 11:54 am
by palful
Hi Quxiao,

We're happy that you're finding yambopy useful!

I'm sorry for being late in replying to this, yet I'm glad you were able to find a solution by customising plot-excitondb.py.

Cheers,
Fulvio

Re: About the plot-excitondb.py

Posted: Mon Mar 27, 2023 3:58 am
by Quxiao
Dear palful:
I just see that reply.Yambopy has provided me with a lot of help.
Thank you very much for your continued help!
Best wishes!
Quxiao