Re: [Ifeffit] report bugs

2016-06-22 Thread Robert Gordon

HI,

This was also reported earlier this month and Bruce has indicated it is 
on his .todo list.

http://www.mail-archive.com/ifeffit%40millenia.cars.aps.anl.gov/msg05587.html

You can use the stand alone version to prepare and save the atoms.inp file.
This file can then be imported (Add) in the main Artemis window under 
Feff calculations

and run in the atoms window that appears when this is done.

regards,
Robert

On 6/22/2016 11:24 PM, Shaofeng Wang wrote:

Dr. Chu,

I met this program, too. The beta version of 0.9.25 is ok.

王少锋



--
Shaofeng Wang, Ph.D of Geochemistry
Environmental Molecular Science Group
Institute of Applied Ecology, Chinese Academy of Sciences
Shenyang, 110016, China
wangshaof...@iae.ac.cn
www.iae.cas.cn

-原始邮件- From: 储胜启
Sent: Thursday, June 23, 2016 10:09 AM
To: ifeffit@millenia.cars.aps.anl.gov
Subject: [Ifeffit] report bugs

Hi, deal bruce,

I have found a bug. When I click the button ‘Run Atoms’ in Artemis 
program, it will crash suddenly. I have tried this in different OS, 
Windows XP and Win7, and got the same error. The log file said as 
follows:


Demeter version 0.9.24

Can't call method "workspace" on an undefined value at 
C:/MyProgramm/DemeterPerl/perl/site/lib/Demeter/UI/Atoms/Xtal.pm line 
1004.


Best wishes,

-Shengqi Chu

Beijing Synchrotron Radiation Facility, Beijing 100049,China

___
Ifeffit mailing list
Ifeffit@millenia.cars.aps.anl.gov
http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit
Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit

___
Ifeffit mailing list
Ifeffit@millenia.cars.aps.anl.gov
http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit
Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit


___
Ifeffit mailing list
Ifeffit@millenia.cars.aps.anl.gov
http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit
Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit


Re: [Ifeffit] report bugs

2016-06-22 Thread Shaofeng Wang

Dr. Chu,

I met this program, too. The beta version of 0.9.25 is ok.

王少锋



--
Shaofeng Wang, Ph.D of Geochemistry
Environmental Molecular Science Group
Institute of Applied Ecology, Chinese Academy of Sciences
Shenyang, 110016, China
wangshaof...@iae.ac.cn
www.iae.cas.cn

-原始邮件- 
From: 储胜启

Sent: Thursday, June 23, 2016 10:09 AM
To: ifeffit@millenia.cars.aps.anl.gov
Subject: [Ifeffit] report bugs

Hi, deal bruce,

I have found a bug. When I click the button ‘Run Atoms’ in Artemis 
program, it will crash suddenly. I have tried this in different OS, Windows 
XP and Win7, and got the same error. The log file said as follows:


Demeter version 0.9.24

Can't call method "workspace" on an undefined value at 
C:/MyProgramm/DemeterPerl/perl/site/lib/Demeter/UI/Atoms/Xtal.pm line 1004.


Best wishes,

-Shengqi Chu

Beijing Synchrotron Radiation Facility, Beijing 100049,China

___
Ifeffit mailing list
Ifeffit@millenia.cars.aps.anl.gov
http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit
Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit 



___
Ifeffit mailing list
Ifeffit@millenia.cars.aps.anl.gov
http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit
Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit


Re: [Ifeffit] Use of restraint

2016-06-22 Thread Bruce Ravel


Maureen,

A restraint is implemented in Larch and Ifeffit as a term that is 
evaluated then added in quadrature to the chi-square fitting metric.  It 
can be of any functional form.  Matt's example in the talk that you 
provided the link for involves a well-shaped functional form using 
ifeffit's built-in "penalty" function.  That function is has linear 
walls with a flat bottom.


The idea of that functional form is that you think you know the 
approximate value of parameter.  For instance, you might think that S02 
should be between 0.7 and 0.95.  As long as the fitted value of S02 is 
between 0.7 and 0.95, the penalty will evaluate to 0 and there will be 
no addition to chi-square.  As the fitted value of S02 wanders outside 
of that range, the restraint takes on a value which is added in 
quadrature to chi-square.


The way to think about this is that the restraint encourages S02 to stay 
within range, but allows it to go outside of the range if the data part 
of the fit improves enough to overcome the penalty imposed by the 
restraint part of the fit.  So S02 can be a bit outside of the range if 
it really, truly improves things.  To say that another way, the 
restraint is a way to allow the fit to prove your initial assumption 
wrong (or accept it if it is right).


The restraint is not required to have this functional form.  The 
well-shaped function is handy, but it can be anything.  Here's an 
example: 
http://bruceravel.github.io/demeter/documents/Artemis/extended/bvs.html#using-a-bond-valance-sum-as-a-restraint 
 (That's mostly taken from a similar example Matt presented in a talk 
on bond valence sums -- a bit of googling should turn up that talk of his.)


In Artemis, you specify the restraint with a math repression.  In that 
sense, it is just like a def parameter.  However, the restraint is 
handled differently behind the scenes.  Ifeffit and Larch each have 
their way of specifying a restraint -- Artemis does the right thing with 
the restraint's math expression.


At the end of the fit, Artemis simply evaluates the math expression. 
That evaluation is the thing that is added in quadrature to the data 
part of chi-square.  The chi-square reported in the log file is the 
sum-in-quadrature of the data part and the restraint part.


All of that makes all kinds of sense, but only because I haven't 
discussed how much you should trust you assumptions.  That is, in the 
S02 example above, you need to decide how strongly you believe that S02 
should be between 0.7 and 0.95.  If you are highly confident, then the 
scaling factor should be large.  That will make the evaluation of the 
restraint a large number even for a small deviation from the bounds. 
When added in quadrature to the data part of chi-square, this will have 
the effect of only allowing S02 to wander out of bounds if is REALLY, 
REALLY improves the fit.


If, on the other hand, you aren't feeling very confident of your 
assumption about S02, make the scale a small number.  This will have the 
effect of allowing a much bigger deviation from the bounds before the 
penalty applied to chi-square has an impact.


The thing about "square root of chi-square" is an observation that's 
been made over the years.  That's a size that tends to be neither large 
nor small in the sense explained above.  It's a size that doesn't show 
high confidence in the assumption, but does show some confidence.  How 
much confidence you have is something you have to decide for yourself.


Hope that helps,
B


On 06/22/2016 09:05 AM, Maureen Le Bars wrote:

Hello,

I have a couple of questions about data analysis on artemis

I used a restraint for my fits. I've read some documentation about it
and found Matt Newville's talk
(https://pubweb.bnl.gov/~frenkel/BNLworkshop2001/newville.pdf). It is
reported that a restraint adds a "V" term to the chi-square (slides
number 16 and 17).

According to this formula, what is the number that artemis gives for the
"restrain" parameter at the end of the fit? How should we consider this
number in the evaluation of the fit ?

I also don't really know very much about the scaling factor to apply in
the formula : scale*penalty(X,a,b). I've read that the square root of
chi-squareseems to be a good size from some of Bruce Ravel's answers in
ifeffit mailing list. How does the scaling factor control the restraint
? What is its relationship with the chi-square ?

Thank you in advance for your help,

Maureen

/PhD student at CIRAD - ADEME//
//CEREGE - Europôle de l'Arbois//
//BP 80//
//13545 Aix en Provence Cedex 4
France
+33 4 42 97 15 48/



___
Ifeffit mailing list
Ifeffit@millenia.cars.aps.anl.gov
http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit
Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit




--
 Bruce Ravel   bra...@bnl.gov

 National Institute of Standards and Technology
 Synchrotron Science Group at NSLS-II