目次

XafsM2 : XAFS測定プログラム

1. 概要

あいちSR BL5S1でXAFS測定に使用されているプログラムです。 このプログラムは更新が頻繁(平均して月1以上)なので、ほとんどの場合、ここにあるのは現時点の最新より古い version だということにご注意下さい。 測定の前にインターフェイスを見知っておきたい様な場合にご利用下さい。 また、XafsM2 で測定し作成されたデータファイルを再度読み込んで確認するためのビュワーとして使用することもできます。 この目的のためには多少古いバージョンでも問題ありません。

2. マニュアル

3. ダウンロード(主たる変更点)

このリストの一番上のものが最新です。 もし、一番上のものが「Exeのみ」だった場合、「環境込」の最新版(リストの上にあるもの)をまず入手、展開してその中に最新の「Exeのみ」を入れてください。

4. 設定ファイルの例

  1. XAFSM.dat 少し新しい例
  2. NewXAFSM.dat 拡張設定

5. 基本的な機能

XafsM2 は多くの機能が盛り込まれていますが、実現されている基本的な機能を挙げます。

  1. XAFSスペクトル測定時に利用可能な機能
    • ステップスキャン、Quick スキャンをサポートします。
    • Quick スキャンでは、繰り返し周期を指定した反復測定が可能です。
    • 多軸の試料ステージを併用して、複数の試料を自動で交換しながら測定したり、一つの試料内の異なる点を順次測定することができます。
    • 複数の検出器を同時に使用して測定が行えます。
    • 測定中に、I0, I, log(I0/I) やその微分等を随時選択して表示できます。
  2. 測定準備中に利用可能な機能
    • 幾つかの予め設定されたエネルギーや、指定したエネルギーに分光器を移動できます。
    • 多軸のステージに複数試料を載せている場合、指定した試料に移動できます。
    • 分光器の角度や、スリット、ステージの高さ等様々な可動軸を横軸に、I0, I1 等を縦軸にとったスキャンができます。
    • XafsM2 に繋がれた様々な検出器の値をモニターできます。
  3. 蛍光検出用の19ch SSDで利用可能な機能
    • SSDの各チャンネルを GUI 常で視覚的に On/Off 可能です。
    • 蛍光X線スペクトルの表示は予め校正されていて、数10eV程度以上の精度のエネルギーのグラフとして見ることができます。
    • ほとんどの、K線、L線の蛍光位置が登録されていて、蛍光X線スペクトル上で確認できます。
    • SSDに対するエネルギーウインドウの設定が mouse を使用した GUI で行えます。
    • XAFS測定中に各チャンネルの信号を確認することや、選択したチャンネルだけの合計を見ることが可能です。
    • XAFS測定の各点に対応した、蛍光X線スペクトルを全て保存することができます。これを用いて、測定後にエネルギーウインドウを変更したXAFSスペクトルを生成することができます。
  4. 多軸の試料ステージ等と連動して利用可能な機能
    • XafsM2 から制御可能なたくさんの軸(試料ステージの可動軸やスリット、ビームラインの光学系の各種の可動軸等)から2つの軸を選択し、2次元のマッピング測定を行うことができます。
    • この機能によって、試料位置を透過X線や蛍光X線の強度マップで確認することや、特定のエネルギーにウインドウをかけた蛍光X線でマップを作ることで試料中の元素分布を確認すること、マップ上で確認した特定の位置に1クリックで移動し、その場所でXAFS測定を行うこと、などが簡単にできます。

XafsM2のXAFS測定画面(ステップスキャンモード) XafsM2の測定準備画面 XafsM2のSSD設定画面

6. 等波数測定の実装 (Imlrementation of "Equal Step in k" mode)

WN2KEV          : double : Constant to convert wave number to energy.   WN2KEV = hbar * hbar / ( 2 * me * ( 1000 * e ) )
eqInK_          : bool   : true when "eq in k" mode is expected to be activated in the region.
eqInKInTheMode_ : bool   : true when "eq in k" mode is activated.
                           (the measurement step is in the region where the k should be changed by equal step.)
eqInKE0KeV_     : double : The original energy : E0. Wave number of electron is given as "sqrt( ( E - eqInKE0KeV_ ) / WN2KEV )"
eqInKCount_     : int    : Roughly say, measured point in "eq in k" mode is "k = dk * eqInKCount_ + k0".

The code till 2023.10.26.

      if ( ! eqInKInTheMode_ ) {                    // when "eq in k" has not been activated.
                                                    // The energy to go (GoToKeV) is calculated as usual with block parameters.
                                                    
                                                    // May be you don't need to care about the following a few lines of codes.
	if ( SMeasInDeg ) {                         // if ( Step and "eq in deg" )
	  Delta = SBlockStartInDeg[MeasB+1] - SBlockStartInDeg[MeasB];
	  GoToKeV = u->deg2keV( Delta/SBlockPoints[MeasB]*MeasS + SBlockStartInDeg[MeasB] );
	} else {                                    // if ( Step and "eq in displayed unit" )
	  Delta = SBlockStartAsDisp[MeasB+1] - SBlockStartAsDisp[MeasB];
	  GoToKeV = u->any2keV( SBLKUnit, Delta / SBlockPoints[MeasB] * MeasS
				+ SBlockStartAsDisp[MeasB] );
	}

	if ( eqInK_ ) {                             // if "eq in k" mode is expected to be activated over the boundary energy.
	  if ( GoToKeV > eqInKFromEkeV_ ) {         // Check if the calculated (with block params) energy "GoToKeV" 
                                                    // beyond the boundary energy "eqInKFromKeV_" or not.
	    eqInKInTheMode_ = true;                 // When beyond, the "eq in k" is activated.
                                                    // but, since the GoToKeV has already been calculated, 
                                                    // the flag "eqInKInTheMode_" is effective from the next measurement step.
	  }
	}
      } else {                                      // When "eq in k" mode is activated.
	eqInKCount_++;                              // Count up the "eq in k" step, which is set to be 0 when the measurement started.
                                                    // So that the eqInKCount_ == 1 
                                                    // at the first time (after the "eqInKInTheMode is true) control arrives here.
	
	double k0 = sqrt( ( eqInKFromEkeV_ - eqInKE0keV_ ) / WN2KEV ); // The wave number at the energy "eqInKFromKeV"
	double k = k0 + eqInKStep_ * eqInKCount_;                      // The wave number to be measured.
	if ( k > eqInKMaxK_ ) {                                        // If the wave number is larger than the max.
	  MeasStage = 11;                                              // The control move to the other stage.
	  break;
	}
	GoToKeV = WN2KEV * k*k + eqInKE0keV_;                          // Convert the wave number to be measured into keV.
      }
      MoveCurThPosKeV( GoToKeV );                                      // Move the Current Theter to the Position selected with the unit keV. 

The new code edited 2023.10.26.

      if ( ! eqInKInTheMode_ ) {                    // when "eq in k" has not been activated.
                                                    // The energy to go (GoToKeV) is calculated as usual with block parameters.
                                                    
        ... some lines are hide ...
        
	if ( eqInK_ ) {                             // if "eq in k" mode is expected to be activated over the boundary energy.
	  if ( GoToKeV > eqInKFromEkeV_ ) {         // Check if the calculated (with block params) energy "GoToKeV" 
                                                    // beyond the boundary energy "eqInKFromKeV_" or not.
	    eqInKInTheMode_ = true;                 // When beyond, the "eq in k" is activated.
                                                    // but, since the GoToKeV has already been calculated, 
                                                    // the flag "eqInKInTheMode_" is effective from the next measurement step.
	  }
	}
      } 
      
      //
      // This block is no longer the "else block", but new if block to check the "eqInKInTheMode_" again, which can be changed before this block.
      //
      if ( eqInKInTheMode_ ) {                      // When "eq in k" mode is activated.

        // The count up is postponed.
	/* eqInKCount_++;                              // Count up the "eq in k" step, which is set to be 0 when the measurement started.
         *                                           // So that the eqInKCount_ == 1 
         *                                           // at the first time (after the "eqInKInTheMode is true) control arrives here.
	 */

	double k0 = sqrt( ( eqInKFromEkeV_ - eqInKE0keV_ ) / WN2KEV ); // The wave number at the energy "eqInKFromKeV"
	double k = k0 + eqInKStep_ * eqInKCount_;                      // The wave number to be measured.
	if ( k > eqInKMaxK_ ) {                                        // If the wave number is larger than the max.
	  MeasStage = 11;                                              // The control move to the other stage.
	  break;
	}
	GoToKeV = WN2KEV * k*k + eqInKE0keV_;                          // Convert the wave number to be measured into keV.

        // new position of the count up.
        eqInKCount_++;
      }
      MoveCurThPosKeV( GoToKeV );                                      // Move the Current Theter to the Position selected with the unit keV. 

7. 履歴と過去のバージョン

過去のバージョン


当 web ページとその下のページに関するお問い合わせ等ございましたら、連絡先にご連絡をお願いします。
田渕のページのルート