2
$\begingroup$

I have set of data of electronic specific heat ($C_{el}/\gamma_n T$) vs temperature ($T/T_c$). My fit equation is this

$$\frac{C_{el}}{\gamma_n T}=-\frac{6}{\pi ^2}\alpha \frac{\mathrm{d} }{\mathrm{d} t}\int_{0}^{\infty }[f*\ln(f)+(1-f)*\ln(1-f)]dy$$

$t=T/T_c$, $f$ is the fermi distribution given by ;

$f(y)= \frac{1}{\exp\left[\frac{\alpha }{t}\sqrt{(\tanh [1.837(1/t-1)^{0.51}])^2+y ^2}\right]+1}$;

$\alpha$ is the fit parameter, you may consider $T_c=5.5$

I tired the precription given here

Regression to fit data with an integral equation

My Code is here,

 h[α_?NumericQ, t_?NumericQ] := {-6*α/(3.14*3.14)}*
 NIntegrate[{D[
 1/(Exp[α*Sqrt[{Tanh[1.837*(1/t - 1)^0.51]}^2 + y^2]/t] + 
      1)*Log[1/(Exp[α*
         Sqrt[{Tanh[1.837*(1/t - 1)^0.51]}^2 + y^2]/t] + 
       1)] + (1 - 
     1/(Exp[α*
          Sqrt[{Tanh[1.837*(1/t - 1)^0.51]}^2 + y^2]/t] + 1))*
   Log[1 - 1/(Exp[α*
          Sqrt[{Tanh[1.837*(1/t - 1)^0.51]}^2 + y^2]/t] + 1)], 
 t]}, {y, 0, ∞}]


 data ={{0.323195763636364, 0.557840860024079}, {0.3319006, 
         0.600799934804363}, {0.340886127272727, 
         0.639986318375706}, {0.350119945454545, 
         0.684545283774048}, {0.359194854545455, 
         0.728787028493261}, {0.368262672727273, 
         0.772480596303758}, {0.387033745454545, 
         0.863418707901043}, {0.404678218181818, 
         0.946863864480626}, {0.422561781818182, 
         1.02894174605389}, {0.440560345454545, 
         1.11675853096735}, {0.458469018181818, 
         1.19588702561508}, {0.476289709090909, 
         1.28900356908129}, {0.494352181818182, 
         1.36753194268344}, {0.512513345454545, 
         1.44442382687088}, {0.530577054545455, 
         1.52513860255128}, {0.5486574, 
         1.61268757899016}, {0.566630236363636, 
         1.69269182859118}, {0.585813963636364, 
         1.78197494463705}, {0.603859690909091, 
         1.86220641802506}, {0.6219008, 1.94677692856268}, {0.6399708, 
         2.00731512950989}, {0.658087109090909, 
         2.08321672050786}, {0.676063945454545, 
         2.12679996044762}, {0.694120345454545, 
         2.1477241658178}, {0.712211690909091, 
         2.13555291300178}, {0.730382418181818, 
         2.08868342579632}, {0.748460254545455, 1.99235135395404},               {0.766518,1.87432757925883}, {0.784746472727273, 
          1.72926503701623}, {0.802872163636364, 
          1.57054700458995}, {0.821021909090909`, 
           1.394635463767}, {0.839189509090909, 
        1.21470123109364}, {0.857382636363636, 
     1.06475296666267}, {0.875464654545455, 
    0.985450924714613}, {0.893474036363636, 
      0.95402882420539}, {0.911454581818182, 
       0.943518363030918}, {0.929713109090909, 
       0.934769247994782}, {0.947911345454545, 
  0.935941815054016}, {0.966096345454545, 
   0.928426646734778}, {0.984215145454545, 
 0.923517882734191}, {1.00237921818182, 0.924673756273926}}
  (*Fit*)
 nlm = NonlinearModelFit[
 data, {h[t, δ], δ > 0}, {{δ, 0.5}}, t];
 (*Summaries*)
 nlm["ParameterTable"]
 Parameter table
 nlm["EstimatedVariance"]^0.5
*Show data, predictions, and 95 % confidence bands for the mean*)
 lower = Transpose[{data[[All, 1]], 
 nlm["MeanPredictionConfidenceIntervals"][[All, 1]]}];

This code is not working. Can anyone help?

$\endgroup$
10
  • 2
    $\begingroup$ Welcome to Mathematica.SE! I suggest the following: 1) As you receive help, try to give it too, by answering questions in your area of expertise. 2) Take the tour and check the faqs! 3) When you see good questions and answers, vote them up by clicking the gray triangles, because the credibility of the system is based on the reputation gained by users sharing their knowledge. Also, please remember to accept the answer, if any, that solves your problem, [by clicking the checkmark sign](tinyurl.com/4srwe26 $\endgroup$
    – Dunlop
    Jan 28, 2020 at 9:36
  • 2
    $\begingroup$ Please give some information about what you have already tried using the software Mathematica. This will help others to give you some advice and maybe even answer your question. Give a list of data if you need to fit using the equation. Also try to have the code / data formatted so it can be copied directly into Mathematica. $\endgroup$
    – Dunlop
    Jan 28, 2020 at 9:37
  • $\begingroup$ @NilabjaKantiSarkar it would be better (& make it a lot easier for us to help you!) if you updated your question with that data, along with your Wolfram Language code attempts in Mathematica :) $\endgroup$ Feb 1, 2020 at 8:26
  • $\begingroup$ @NilabjaKantiSarkar when you write Ces I assume you meant Cel right? the specific heat $\endgroup$
    – user49048
    Feb 1, 2020 at 11:07
  • $\begingroup$ yah. Sorry for the typo $\endgroup$ Feb 1, 2020 at 14:22

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.