diff --git a/Modelica/Magnetic/FluxTubes/Material/HysteresisEverettParameter/BaseData.mo b/Modelica/Magnetic/FluxTubes/Material/HysteresisEverettParameter/BaseData.mo index 7306573d45..8e6692a912 100644 --- a/Modelica/Magnetic/FluxTubes/Material/HysteresisEverettParameter/BaseData.mo +++ b/Modelica/Magnetic/FluxTubes/Material/HysteresisEverettParameter/BaseData.mo @@ -3,7 +3,7 @@ record BaseData "Base Data Record" extends Modelica.Icons.Record; parameter SI.MagneticFieldStrength Hsat=100 "Hysteresis region between -Hsat .. Hsat"; - parameter Real M(final unit="1")=0.95 + parameter Real M(final unit="T(1/2)")=0.95 "Related to saturation value of magnetization"; parameter Real r(final unit="1")=0.55 "Proportion of the straight region in the vicinity of Hc"; diff --git a/Modelica/Magnetic/FluxTubes/Shapes/HysteresisAndMagnets/GenericHystPreisachEverett.mo b/Modelica/Magnetic/FluxTubes/Shapes/HysteresisAndMagnets/GenericHystPreisachEverett.mo index 6dbe6e2721..9691799966 100644 --- a/Modelica/Magnetic/FluxTubes/Shapes/HysteresisAndMagnets/GenericHystPreisachEverett.mo +++ b/Modelica/Magnetic/FluxTubes/Shapes/HysteresisAndMagnets/GenericHystPreisachEverett.mo @@ -170,11 +170,10 @@ equation H3= -alpha-mat.Hc; H4= beta-mat.Hc; - E = unitT* - ((mat.M*mat.r*(2/pi*atan(mat.q*H1)+1)+(2*mat.M*(1-mat.r))/(1+1/2*(exp(-mat.p1*H1)+exp(-mat.p2*H1))))* - (mat.M*mat.r*(2/pi*atan(mat.q*H2)+1)+(2*mat.M*(1-mat.r))/(1+1/2*(exp(-mat.p1*H2)+exp(-mat.p2*H2))))- - (mat.M*mat.r*(2/pi*atan(mat.q*H3)+1)+(2*mat.M*(1-mat.r))/(1+1/2*(exp(-mat.p1*H3)+exp(-mat.p2*H3))))* - (mat.M*mat.r*(2/pi*atan(mat.q*H4)+1)+(2*mat.M*(1-mat.r))/(1+1/2*(exp(-mat.p1*H4)+exp(-mat.p2*H4))))); + E = ((mat.M*mat.r*(2/pi*atan(mat.q*H1)+1)+(2*mat.M*(1-mat.r))/(1+1/2*(exp(-mat.p1*H1)+exp(-mat.p2*H1))))* + (mat.M*mat.r*(2/pi*atan(mat.q*H2)+1)+(2*mat.M*(1-mat.r))/(1+1/2*(exp(-mat.p1*H2)+exp(-mat.p2*H2))))- + (mat.M*mat.r*(2/pi*atan(mat.q*H3)+1)+(2*mat.M*(1-mat.r))/(1+1/2*(exp(-mat.p1*H3)+exp(-mat.p2*H3))))* + (mat.M*mat.r*(2/pi*atan(mat.q*H4)+1)+(2*mat.M*(1-mat.r))/(1+1/2*(exp(-mat.p1*H4)+exp(-mat.p2*H4))))); der(J) = (if init then 0.5 else 1) * der(E); B = J + mu0 * Hstat; diff --git a/Modelica/Magnetic/FluxTubes/Shapes/HysteresisAndMagnets/GenericHystTellinenEverett.mo b/Modelica/Magnetic/FluxTubes/Shapes/HysteresisAndMagnets/GenericHystTellinenEverett.mo index 7a8657badb..2b648e9191 100644 --- a/Modelica/Magnetic/FluxTubes/Shapes/HysteresisAndMagnets/GenericHystTellinenEverett.mo +++ b/Modelica/Magnetic/FluxTubes/Shapes/HysteresisAndMagnets/GenericHystTellinenEverett.mo @@ -13,14 +13,14 @@ protected mat.Hsat,-mat.Hsat, mat, false) "Saturation polarization"; //final parameter Real mu0 = mat.K * mu_0; - parameter SI.MagneticFluxDensity eps=mat.M/1000; - parameter Real P1 = (mat.M*mat.r*(2/pi*atan(mat.q*(mat.Hsat-mat.Hc))+1)+(2*mat.M*(1-mat.r))/(1+1/2*(exp(-mat.p1*(mat.Hsat-mat.Hc))+exp(-mat.p2*(mat.Hsat-mat.Hc))))); - parameter Real P4 = (mat.M*mat.r*(2/pi*atan(mat.q*(-mat.Hsat-mat.Hc))+1)+(2*mat.M*(1-mat.r))/(1+1/2*(exp(-mat.p1*(-mat.Hsat-mat.Hc))+exp(-mat.p2*(-mat.Hsat-mat.Hc))))); + parameter SI.MagneticFluxDensity eps=Js/1000; + parameter Real P1(final unit="T(1/2)") = (mat.M*mat.r*(2/pi*atan(mat.q*(mat.Hsat-mat.Hc))+1)+(2*mat.M*(1-mat.r))/(1+1/2*(exp(-mat.p1*(mat.Hsat-mat.Hc))+exp(-mat.p2*(mat.Hsat-mat.Hc))))); + parameter Real P4(final unit="T(1/2)") = (mat.M*mat.r*(2/pi*atan(mat.q*(-mat.Hsat-mat.Hc))+1)+(2*mat.M*(1-mat.r))/(1+1/2*(exp(-mat.p1*(-mat.Hsat-mat.Hc))+exp(-mat.p2*(-mat.Hsat-mat.Hc))))); SI.MagneticFieldStrength H2; SI.MagneticFieldStrength H3; - Real P2; - Real P3; + Real P2(final unit="T(1/2)"); + Real P3(final unit="T(1/2)"); Real H_lim; constant SI.MagneticFluxDensity unitT = 1; @@ -32,8 +32,8 @@ equation P2 = (mat.M*mat.r*(2/pi*atan(mat.q*H2)+1)+(2*mat.M*(1-mat.r))/(1+1/2*(exp(-mat.p1*H2)+exp(-mat.p2*H2)))); P3 = (mat.M*mat.r*(2/pi*atan(mat.q*H3)+1)+(2*mat.M*(1-mat.r))/(1+1/2*(exp(-mat.p1*H3)+exp(-mat.p2*H3)))); - hystR = -Js + unitT*(P1*P2-P3*P4) + mu0*Hstat - eps/2; - hystF = Js + unitT*(P4*P2-P3*P1) + mu0*Hstat + eps/2; + hystR = -Js + (P1*P2-P3*P4) + mu0*Hstat - eps/2; + hystF = Js + (P4*P2-P3*P1) + mu0*Hstat + eps/2; annotation (defaultComponentName="core", Icon(graphics={Text( extent={{40,0},{40,-30}}, diff --git a/Modelica/Magnetic/FluxTubes/Utilities/everett.mo b/Modelica/Magnetic/FluxTubes/Utilities/everett.mo index de0c18bd3c..6bbd1dd739 100644 --- a/Modelica/Magnetic/FluxTubes/Utilities/everett.mo +++ b/Modelica/Magnetic/FluxTubes/Utilities/everett.mo @@ -29,11 +29,10 @@ algorithm h3:=-a-p.Hc; h4:=b-p.Hc; - J:= unitT*( - (p.M*p.r*(2/pi*atan(p.q*h1)+1)+(2*p.M*(1-p.r))/(1+1/2*(exp(-p.p1*h1)+exp(-p.p2*h1))))* - (p.M*p.r*(2/pi*atan(p.q*h2)+1)+(2*p.M*(1-p.r))/(1+1/2*(exp(-p.p1*h2)+exp(-p.p2*h2))))- - (p.M*p.r*(2/pi*atan(p.q*h3)+1)+(2*p.M*(1-p.r))/(1+1/2*(exp(-p.p1*h3)+exp(-p.p2*h3))))* - (p.M*p.r*(2/pi*atan(p.q*h4)+1)+(2*p.M*(1-p.r))/(1+1/2*(exp(-p.p1*h4)+exp(-p.p2*h4))))); + J:= ((p.M*p.r*(2/pi*atan(p.q*h1)+1)+(2*p.M*(1-p.r))/(1+1/2*(exp(-p.p1*h1)+exp(-p.p2*h1))))* + (p.M*p.r*(2/pi*atan(p.q*h2)+1)+(2*p.M*(1-p.r))/(1+1/2*(exp(-p.p1*h2)+exp(-p.p2*h2))))- + (p.M*p.r*(2/pi*atan(p.q*h3)+1)+(2*p.M*(1-p.r))/(1+1/2*(exp(-p.p1*h3)+exp(-p.p2*h3))))* + (p.M*p.r*(2/pi*atan(p.q*h4)+1)+(2*p.M*(1-p.r))/(1+1/2*(exp(-p.p1*h4)+exp(-p.p2*h4))))); else J:=0; end if;