Changing the settings of ADDA

28 views
Skip to first unread message

小出真叶

unread,
Nov 19, 2024, 3:19:05 AM11/19/24
to adda-d...@googlegroups.com
Hello all,

I have a question about changing the settings of ADDA.
First, I would like to know how to change the error tolerance of ADDA calculations. We want to perform more precise calculations than the default settings, so we need to reduce the tolerance of ADDA calculations. Please tell us how to change the tolerance of ADDA calculations.
Second, I would like to know how to change the file extensions of the output files from ADDA calculations. By default, the output files CrossSec-Y, log, and mueller do not have extensions. For our research purposes, we need these output files to have a .txt extension. Please tell us how to change the extensions of CrossSec-Y, log, and mueller files.
I look forward to your response.
Thank you very much.
Sincerely yours,
 Manato Koide

Maxim Yurkin

unread,
Nov 19, 2024, 5:24:38 AM11/19/24
to adda-d...@googlegroups.com, 小出真叶
Dear Manato,

Concerning the accuracy, this is covered in Section 4.1 "General applicability" of the manual. In short, the main parameter controlling the accuracy is the dipole size (or number of dipoles), but you need to change it manually and see what happens, since it is hard to estimate the accuracy a priori.  You should also try different DDA formulations, such as FCD or IGT (or IGT_SO) - in some cases they can improve accuracy a lot almost for free.

If you use orientation averaging, the number of orientations is also a relevant parameter. ADDA will try to reach the specified accuracy (for orientational averaging of Cext), but the required number of orientations for that may be unfeasibly large. Other parameters, such as the threshold of the iterative solver or the number of scattering angles for computation of asymmetry parameter are usually good enough by default. You should worry about them only if you aim at extremely good accuracy, say 4 digits, or some equivalence testing.

Concerning the second question, if you really need to add the extensions, you may play with the defines in const.h and then recompile ADDA. Specifically, look at F_LOG, F_MUEL, F_XSUF and F_YSUF (the latter will affect all file names ending with -X or -Y). For instance, change
#define F_LOG           "log"
to
#define F_LOG           "log.txt"

However, I think that this approach is necessary only if you run ADDA manually and process the output also manually with some software that expects .txt extension (although I am not aware of the latter, e.g., Notepad++ can easily open any files, including the ones without extension). If you use any scripts (e.g., bash or python) to run ADDA or to process the output, it is preferable to add rename commands to this script. This way your workflow will be based on the main version of ADDA, automatically benefiting from future updates.

Maxim.

P.S. This answer has been forwarded to your e-mail address for your convenience. However, if you want to continue the discussion please reply to the group's e-mail. You are also advised to check the corresponding discussion thread at http://groups.google.com/group/adda-discuss and/or subscribe to it to receive automatic notifications, since other answers/comments will not be necessarily forwarded to your e-mail.
--
You received this message because you are subscribed to the Google Groups "ADDA questions and answers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adda-discuss...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/adda-discuss/TYZPR01MB64090899C6CABE75BB947C61FE202%40TYZPR01MB6409.apcprd01.prod.exchangelabs.com.


Reply all
Reply to author
Forward
0 new messages