BELFEM 0.9.3
Berkeley Lab Finite Element Framework
Loading...
Searching...
No Matches
cl_Material.hpp
Go to the documentation of this file.
1/*
2 * BELFEM -- The Berkeley Lab Finite Element Framework
3 * Copyright (c) 2026, The Regents of the University of California,
4 * through Lawrence Berkeley National Laboratory (subject to receipt of any required
5 * approvals from the U.S. Dept. of Energy). All rights reserved.
6 *
7 * Developers: Christian Messe, Gregory Giard
8 *
9 * See the top-level LICENSE file for the complete license and disclaimer.
10 */
11
12#ifndef BELFEM_CL_MATERIAL_HPP
13#define BELFEM_CL_MATERIAL_HPP
14#include "globals.hpp"
15
16#include <cmath>
17
18#include "typedefs.hpp"
19#include "constants.hpp"
20#include "assert.hpp"
21#include "cl_Bitset.hpp"
22#include "cl_Cell.hpp"
23
24// note: NEVER include cl_Vector.hpp or cl_Matrix.hpp here, or any class that uses it.
25// Doing so would break the API for the user defined materials.
26
27namespace belfem
28{
47 constexpr real gTAlphaSwitchMax = 273.15 ;
48
55 constexpr real gDefaultEcrit = 1e-4 ;
56}
57
58//#include "cl_Mesh.hpp"
59
60#if defined(__clang__)
61#pragma clang diagnostic push
62#pragma clang diagnostic ignored "-Wformat-security"
63#pragma clang diagnostic ignored "-Wformat"
64#pragma clang diagnostic ignored "-Wunused-variable"
65#pragma clang diagnostic ignored "-Wunused-parameter"
66
67#elif defined(__GNUC__) || defined(__GNUG__)
68#pragma GCC diagnostic push
69#pragma GCC diagnostic ignored "-Wformat"
70#pragma GCC diagnostic ignored "-Wunused-variable"
71#pragma GCC diagnostic ignored "-Wunused-parameter"
72
73#elif defined(BELFEM_INTEL)
74 // Intel compiler diagnostics
75#pragma warning(push)
76 // disable format warnings
77#pragma warning(disable: 1011)
78 // disable unused variable warnings
79#pragma warning(disable: 177)
80 // keep your original one
81#pragma warning(disable: 1595)
82
83#endif
84
85// Forward declaration (full definition only needed in implementation files)
86
87#include "cl_JcFunction.hpp"
88
89namespace belfem
90{
91//------------------------------------------------------------------------------
92 namespace material
93 {
94 class BhCurve ;
95 class SplineLookupTable ;
96 }
97
98//------------------------------------------------------------------------------
99
122
124 {
125 T = 0, // temperature [K]
126 normB = 1, // magnitude of in-plane magnetic field [T] (HTS, for lambda and rho)
127 angleBxJ = 2, // angle between B and j [rad]
128 angleNxB = 3, // angle between surface normal and B [rad]
129 normH = 4, // magnetic field strength [A/m] (for mu in ferromagnetic materials)
130 normJ = 5,
131 Jc = 6,
132 rho = 7,
133 UNDEFINED = 8
134 };
135
137
153 {
154 density = 0, // density [kg/m³]
155 E = 1, // Young's modulus [Pa]
156 nu = 2, // Poisson's ratio [-]
157 cp = 3, // specific heat capacity [J/(kg·K)]
158 lambda = 4, // thermal conductivity [W/(m·K)]
159 mu = 5, // magnetic permeability [H/m], defined as ∂B/∂H
160 rho = 6, // electric resistivity [Ω·m]
161 alpha = 7, // thermal expansion coefficient [1/K], defined as (1/l)·∂l/∂T, not (1/l)·Δl/ΔT!
162 Rp02 = 8, // yield stress [Pa]
163 debye = 9, // Debye temperature [K]
164 rho_i = 10, // inner resistivity of noble metal [Ω·m]
165 kohler_trans = 11, // Kohler parameter for transverse magnetoresistance [-]
166 kohler_long = 12, // Kohler parameter for longitudinal magnetoresistance [-]
167 T_crit = 13, // critical temperature [K]
168 M = 14, // molar mass [kg/mol]
169 Gamma = 15, // impurity parameter [-]
170 R = 16, // specific gas constant [J/(kg·K)]
171 T_max = 17, // maximum temperature [K]
172 ref_density = 18, // reference density [kg/m³]
173 T_ref_density = 19, // temperature at reference density [K]
174 gamma = 20, // linear Debye parameter [J/(kg·K²)], cv = γ·T + β·T³ = ∂cp/∂T at T=0
175 beta = 21, // cubic Debye parameter [J/(kg·K⁴)], cv = γ·T + β·T³
176 q = 22, // number of atoms per molecule [-] (default: 1)
177 debye0K = 23, // Debye temperature at 0 K [K]
178 rho_i_ref = 24, // reference inner resistivity [Ω·m]
179 T_ref_rho_i = 25, // temperature at reference inner resistivity [K]
180 A_bloch_gruen = 26, // A-parameter for Bloch-Grüneisen law [-]
181 n_bloch_gruen = 27, // n-parameter for Bloch-Grüneisen law [-]
182 RRR = 28, // residual resistivity ratio [-]
183 rho_0 = 29, // residual resistivity [Ω·m]
184 layer_thickness = 30, // characteristic length, e.g., layer thickness [m]
185 ec = 31, // critical electric field [V/m]
186 jc = 32, // critical current density [A/m²]
187 n = 33, // exponent for power law [-]
188 Tcurie = 34, // Curie temperature [K]
189 A_electron_magnon = 35, // electron-magnon scattering parameter [ Ω · m / K² ]
190 A_spin_disorder = 36, // spin disorder amplitude [ Ω · m ]
191 grueneisen = 37, // Grüneisen parameter
192 density_correction = 38, // density scaling factor, to correct solder thickness [-]
193 rho0_pure = 39, // resistivity from TPCR for pure metals
194 UNDEFINED = 40
195 };
196
202 constexpr size_t gNumNonConstantMaterialProperties = static_cast< size_t >( MaterialProperty::T_crit ) ;
203
204 constexpr size_t gNumMaterialProperties = static_cast< size_t >( MaterialProperty::UNDEFINED ) ;
205
206 string
207 to_string( const MaterialProperty aProperty ) ;
208
209 unit
210 get_unit( const MaterialProperty aProperty ) ;
211
223 enum class ResistivityLaw
224 {
228 };
229
230 class Material ;
231
232 typedef real ( MatFunc1 )( const Material * , const real ) ; // T
233 typedef real ( MatFunc2 )( const Material *, const real, const real ) ;
234 typedef real ( MatFunc3 )( const Material *, const real, const real, const real ) ;
235 typedef real ( DefectFunc )( const real, const real, const real, const real ) ;
236 typedef real ( HeatFunc )( const real, const real, const real, const real ) ;
237
270 {
271 const proc_t mCommRank ;
272
273 const MaterialType mType ;
274
275 const bool mIsIsotropic ; // Flag for isotropic properties (default: true)
276
277 string mLabel ; // Material label (e.g., "Copper", "YBCO")
278
279 string mNumber = "" ; // Material number/identifier if it exists
280
281 // bitwise flags for this vertex
282 // 1: used by kernel
283 // 7: reserved for factory
284 uint8_t mFlags = 0;
285
286 Bitset< gNumMaterialProperties > mHaveProperty ; // Flags which properties are implemented
287
288 Cell< real > mConstantProperties ; // Storage for constant property values
289
290 Cell< MaterialDependencyBitset * > mPropertyDependencies ; // Tracks dependencies for each property
291
292 //Piecewise resistivity parameters
293 real mNff = 3.0 ;
294 real mD = 2.5 ;
295
297 real mRhoMin = 0.0 ;
298
303 real mTAlphaSwitch = BELFEM_QUIET_NAN ;
304
308 ResistivityLaw mResistivityLaw = ResistivityLaw::PowerLaw ;
309
310 // Function pointers for property evaluation (dispatched based on dependencies)
311 real ( Material::*mFunctionDensity ) ( const real T ) const = nullptr ;
312
313 real ( Material::*mFunctionCp ) ( const real T ) const = nullptr ;
314 real ( Material::*mFunctionLambda ) ( const real T ) const = nullptr ;
315
316 real ( Material::*mFunctiondCpdT ) ( const real T ) const = nullptr ;
317 real ( Material::*mFunctiondLambdadT ) ( const real T ) const = nullptr ;
318
319 real ( Material::*mFunctiond2CpdT2 ) ( const real T ) const = nullptr ;
320
321 real ( Material::*mFunctionRho ) ( const real T ) const = nullptr ;
322 real ( Material::*mFunctionRhoI ) ( const real T ) const = nullptr ;
323 real ( Material::*mFunctiondRhodT ) ( const real T ) const = nullptr ;
324
325 real ( Material::*mFunctionE ) ( const real T ) const = nullptr ;
326 real ( Material::*mFunctionNu ) ( const real T ) const = nullptr ;
327
328 real ( Material::*mFunctionAlpha ) ( const real T ) const = nullptr ;
329
330 real ( Material::*mFunctionRp02 ) ( const real T ) const = nullptr ;
331 real ( Material::*mFunctionDebye ) ( const real T ) const = nullptr ;
332
333 DefectFunc * mDefectFunction = nullptr ;
334 HeatFunc * mHeatFunction = nullptr ;
335
339 void * mDefectHandle = nullptr ;
340
342 void * mHeatHandle = nullptr ;
343
344 // we don't want all materials to access private functions
345 // but for this one, it's OK
347
348 protected:
349
359 real
360 jc_eval( const real T, const real normB, const real angleNxB ) const ;
361
365 real
366 djc_eval_dB( const real T, const real normB, const real angleNxB ) const ;
367
369 real
370 dn_eval_dB( const real T, const real normB, const real angleNxB ) const ;
371
376 real
377 djc_eval_dT( const real T, const real normB, const real angleNxB ) const ;
378
380 real
381 dn_eval_dT( const real T, const real normB, const real angleNxB ) const ;
382
383 real
384 n_eval( const real T, const real normB, const real angleNxB ) const ;
385
390 void
391 check_riva_n_source() const ;
392
393 real ( Material::*mFunctionRhoKohler ) ( const real T, const real normB, const real angle ) const = nullptr ;
394 real ( Material::*mFunctiondRhoKohlerdT ) ( const real T, const real normB, const real angle ) const = nullptr ;
395 real ( Material::*mFunctiondRhoKohlerdB ) ( const real T, const real normB, const real angle ) const = nullptr ;
396 real ( Material::*mFunctiondRhoKohlerdbeta ) ( const real T, const real normB, const real angle ) const = nullptr ;
397
398 real ( Material::*mFunctionH ) ( const real B ) const = nullptr ;
399 real ( Material::*mFunctionMu ) ( const real H, const real T ) const = nullptr ;
400 void ( Material::*mFunctionDMuDH )( double, double&, double& ) const = nullptr ;
401
402 // Function objects (material owns and deletes these)
403
406
407//------------------------------------------------------------------------------
408 public:
409//------------------------------------------------------------------------------
410
411 Material( const MaterialType aType, const bool aIsIsotropic=true ) ;
412
414 virtual ~Material() ;
415
416 // Non-copyable and non-movable (Rule of Five)
417 Material( const Material & ) = delete ;
418 Material & operator=( const Material & ) = delete ;
419 Material( Material && ) = delete ;
420 Material & operator=( Material && ) = delete ;
421
422//------------------------------------------------------------------------------
423// Property Checks
424//------------------------------------------------------------------------------
425
426 bool
427 have( const MaterialProperty aProperty ) const ;
428
429 bool
430 have_defect() const ;
431
432 bool
433 have_heating() const ;
434
435 bool
436 use_piecewise() const ;
437
438 bool
439 depends( const MaterialProperty aProperty, const MaterialDependency aDependency ) const ;
440
442 dependencies( const MaterialProperty aProperty ) const ;
443
444 bool
445 is_isotropic() const ;
446
448 type() const ;
449
450//------------------------------------------------------------------------------
451// Parameters and Tools
452//------------------------------------------------------------------------------
453
454 const string &
455 label() const ;
456
458 const string &
459 number() const ;
460
470 void
471 load_bh_curve( const material::BhCurve * aCurve );
472
473 void
474 flag( const uint8_t aIndex = 0 );
475
476 void
477 unflag( const uint8_t aIndex = 0 );
478
479 bool
480 is_flagged( const uint8_t aIndex = 0 ) const ;
481
482 bool
483 is_constant( const MaterialProperty aProperty ) const ;
484
486 virtual void
487 set_RRR( const real RRR ) ;
488
489//------------------------------------------------------------------------------
490// Mass and Weight
491//------------------------------------------------------------------------------
492
501 virtual real
502 density( const real T=gTroom ) const ;
503
510 real
511 ref_density() const ;
512
514 real
515 M() const ;
516
517//------------------------------------------------------------------------------
518// Thermal Properties
519//------------------------------------------------------------------------------
520
526 virtual real
527 cp( const real T=gTroom ) const ;
528
529 virtual real
530 dcpdT( const real T=gTroom ) const ;
531
532 virtual real
533 d2cpdT2( const real T=gTroom ) const ;
534
540 virtual real
541 lambda( const real T=gTroom ) const ;
542
543 virtual real
544 dlambdadT( const real T=gTroom ) const ;
545
558 virtual real
559 lambda( const real T, const real B, const real beta ) const ;
560
561 virtual real
562 dlambdadT( const real T, const real B, const real beta ) const ;
563
564 virtual real
565 dlambdadB( const real T, const real B, const real beta ) const ;
566
567 virtual real
568 dlambdadbeta( const real T, const real B, const real beta ) const ;
569
578 virtual real
579 lambda( const real T, const real B_par, const real B_perp, const real J ) const ;
580
581 virtual real
582 dlambdadT( const real T, const real B_par, const real B_perp, const real J ) const ;
583
584//------------------------------------------------------------------------------
585// Electric Properties
586//------------------------------------------------------------------------------
587
595 virtual real
596 rho( const real T ) const ;
597
598 virtual real
599 drhodT( const real T ) const ;
600
613 virtual real
614 rho( const real T, const real B, const real beta ) const ;
615
616 virtual real
617 drhodT( const real T, const real B, const real beta ) const ;
618
619 virtual real
620 drhodB( const real T, const real B, const real beta ) const ;
621
622 virtual real
623 drhodbeta( const real T, const real B, const real beta ) const ;
624
636 real
637 rho_powerlaw( const real normJ ) const ;
638
639 real
640 rho_powerlaw( const real normJ, const real x, const real y, const real z, const real t ) const ;
641
652 real
653 rho_powerlaw( const real normJ, real normB, const real angleNxB ) const ;
654
655 real
656 rho_powerlaw( const real normJ, real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
657
669 real
670 rho_powerlaw( const real normJ, const real T, real normB, const real angleNxB ) const ;
671
672 real
673 rho_powerlaw( const real normJ, const real T, real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
674
675 //Temperature dependent only cases (custom)
676 real
677 rho_powerlaw( const real normJ, const real T ) const ;
678
679 real
680 rho_powerlaw( const real normJ, const real T, const real x, const real y, const real z, const real t ) const ;
681
690 real
691 rho_piecewise( const real normJ ) const ;
692
693 real
694 rho_piecewise( const real normJ, const real x, const real y, const real z, const real t ) const ;
695
704 real
705 rho_piecewise( const real normJ, real normB, const real angleNxB ) const ;
706
707 real
708 rho_piecewise( const real normJ, real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
709
719 real
720 rho_piecewise( const real normJ, const real T, real normB, const real angleNxB ) const ;
721
722 real
723 rho_piecewise( const real normJ, const real T, real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
724
725 //Temperature dependent only cases (custom)
726 real
727 rho_piecewise( const real normJ, const real T ) const ;
728
729 real
730 rho_piecewise( const real normJ, const real T, const real x, const real y, const real z, const real t ) const ;
731
747 real
748 rho_riva( const real normJ, const real T, const real normB, const real angleNxB ) const ;
749
751 real
752 rho_riva( const real normJ, const real T, const real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
753
755 real
756 drho_riva_dJ( const real normJ, const real T, const real normB, const real angleNxB ) const ;
757
758 real
759 drho_riva_dJ( const real normJ, const real T, const real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
760
762 real
763 drho_riva_dB( const real normJ, const real T, const real normB, const real angleNxB ) const ;
764
765 real
766 drho_riva_dB( const real normJ, const real T, const real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
767
769 real
770 drho_riva_dT( const real normJ, const real T, const real normB, const real angleNxB ) const ;
771
772 real
773 drho_riva_dT( const real normJ, const real T, const real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
774
775 real
776 n( const real normB, const real angleNxB, const real T ) const ;
777
778 real
779 n( const real normB, const real angleNxB ) const ;
780
781 real
782 jc( const real normB, const real angleNxB, const real T ) const ;
783
784 real
785 jc( const real normB, const real angleNxB ) const ;
786
787 //Case of jc with user-defined defect
788 real
789 jc( const real normB, const real angleNxB, const real T, const real x, const real y, const real z, const real t ) const ;
790
791 real
792 jc( const real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
793
804 real
805 drho_powerlaw_dJ( const real normJ, const real T, const real normB, const real angleNxB ) const ;
806
807 real
808 drho_powerlaw_dJ( const real normJ, const real T, const real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
809
810 // Overloads matching rho_powerlaw signatures
811 real
812 drho_powerlaw_dJ( const real normJ ) const ;
813
814 real
815 drho_powerlaw_dJ( const real normJ, const real x, const real y, const real z, const real t ) const ;
816
817 real
818 drho_powerlaw_dJ( const real normJ, const real T ) const ;
819
820 real
821 drho_powerlaw_dJ( const real normJ, const real T, const real x, const real y, const real z, const real t ) const ;
822
823 real
824 drho_powerlaw_dJ( const real normJ, const real normB, const real angleNxB ) const ;
825
826 real
827 drho_powerlaw_dJ( const real normJ, const real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
828
839 real
840 drho_piecewise_dJ( const real normJ, const real T, const real normB, const real angleNxB ) const ;
841
842 real
843 drho_piecewise_dJ( const real normJ, const real T, const real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
844
856 real
857 drho_powerlaw_dB( const real normJ, const real T, const real normB, const real angleNxB ) const ;
858
860 real
861 drho_powerlaw_dB( const real normJ, const real T, const real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
862
876 real
877 drho_powerlaw_dT( const real normJ, const real T, const real normB, const real angleNxB ) const ;
878
880 real
881 drho_powerlaw_dT( const real normJ, const real T, const real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
882
900 real
901 drho_piecewise_dB( const real normJ, const real T, const real normB, const real angleNxB ) const ;
902
904 real
905 drho_piecewise_dB( const real normJ, const real T, const real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
906
922 real
923 drho_piecewise_dT( const real normJ, const real T, const real normB, const real angleNxB ) const ;
924
926 real
927 drho_piecewise_dT( const real normJ, const real T, const real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
928
929 // Overloads matching rho_piecewise signatures
930 real
931 drho_piecewise_dJ( const real normJ ) const ;
932
933 real
934 drho_piecewise_dJ( const real normJ, const real x, const real y, const real z, const real t ) const ;
935
936 real
937 drho_piecewise_dJ( const real normJ, const real T ) const ;
938
939 real
940 drho_piecewise_dJ( const real normJ, const real T, const real x, const real y, const real z, const real t ) const ;
941
942 real
943 drho_piecewise_dJ( const real normJ, const real normB, const real angleNxB ) const ;
944
945 real
946 drho_piecewise_dJ( const real normJ, const real normB, const real angleNxB, const real x, const real y, const real z, const real t ) const ;
947
953 virtual real
954 rho_i( const real T ) const ;
955
956//------------------------------------------------------------------------------
957// Magnetic Properties
958//------------------------------------------------------------------------------
959
965 virtual real
966 H( const real B ) const ;
967
974 virtual real
975 mu( const real H, const real T=BELFEM_QUIET_NAN ) const ;
976
983 virtual void
984 dmudH( const real H, real & mu, real & dmudH ) const ;
985
986//------------------------------------------------------------------------------
987// Mechanical Properties
988//------------------------------------------------------------------------------
989
995 virtual real
996 E( real T=gTroom ) const ;
997
1003 virtual real
1004 nu( real T=gTroom ) const ;
1005
1011 virtual real
1012 G( real T=gTroom ) const ;
1013
1019 virtual real
1020 K( real T=gTroom ) const ;
1021
1029 virtual real
1030 alpha( real T=gTroom ) const ;
1031
1037 virtual real
1038 l( real T ) const ;
1039
1045 virtual real
1046 Rp02( real T=gTroom ) const ;
1047
1048//------------------------------------------------------------------------------
1049// Other Properties
1050//------------------------------------------------------------------------------
1051
1057 virtual real
1058 debye( const real T ) const ;
1059
1069 virtual void
1070 set_bh_curve( const material::BhCurve * aCurve );
1071
1078 void
1079 set_jc_function( const material::JcFunction * aFunction );
1080
1087 void
1088 set_n_function( const material::JcFunction * aFunction );
1089
1090 void
1091 set_piecewise( const bool aUsePiecewise );
1092
1093 void
1094 set_resistivity_law( const ResistivityLaw aLaw );
1095
1097 resistivity_law() const ;
1098
1099 bool
1100 use_riva() const ;
1101//------------------------------------------------------------------------------
1102// API for user defined functions
1103//------------------------------------------------------------------------------
1104
1118 virtual void
1120 const MaterialProperty Property,
1121 const MaterialDependency Dependency,
1122 MatFunc1 * Function ) ;
1123
1137 virtual void
1139 const MaterialProperty Property,
1140 const MaterialDependency Dependency1,
1141 const MaterialDependency Dependency2,
1142 MatFunc2 * Function ) ;
1143
1158 virtual void
1160 const MaterialProperty Property,
1161 const MaterialDependency Dependency1,
1162 const MaterialDependency Dependency2,
1163 const MaterialDependency Dependency3,
1164 MatFunc3 * Function ) ;
1165
1173 void
1174 set_user_defined_defect( DefectFunc * Function ) ;
1175
1185 void
1186 read_defect( const string & aLibraryPath,
1187 const string & aLabel ) ;
1188
1195 void
1196 set_user_defined_heating( HeatFunc * Function ) ;
1197
1208 void
1209 read_heating( const string & aLibraryPath,
1210 const string & aLabel ) ;
1211
1224 virtual real
1226 const MaterialProperty Property,
1227 const real T ) const ;
1228
1229 virtual real
1231 const MaterialProperty Property,
1232 const real T ) const ;
1233
1247 virtual void
1249 const MaterialProperty Property,
1250 const std::vector< real > & Coefficients ) ;
1251
1252 virtual void
1254 const MaterialProperty Property,
1255 const Cell< real > & Coefficients ) ;
1256
1270
1274 void
1275 set_label( const string & aLabel ) ;
1276
1277 void
1278 set_number( const string & aNumber ) ;
1279
1280 void
1281 set_have( const MaterialProperty aProperty, const bool aHave=true ) ;
1282
1283 void
1284 reset_dependencies( const MaterialProperty aProperty );
1285
1286 void
1287 set_dependency( const MaterialProperty aProperty, const MaterialDependency aDependency ) ;
1288
1289 void
1290 set_constant( const MaterialProperty aProperty, const real aValue ) ;
1291
1292 void
1293 set_custom( const MaterialProperty aProperty ) ;
1294
1295 real
1296 constant_property( const MaterialProperty aProperty ) const ;
1297
1298 virtual real
1299 spline_property( const MaterialProperty aProperty, const real aX ) const ;
1300
1301 virtual real
1302 dspline_property( const MaterialProperty aProperty, const real aX ) const ;
1303
1304 virtual real
1305 ddspline_property( const MaterialProperty aProperty, const real aX ) const ;
1306
1307 virtual void
1308 set_table_flags( const bool aFlag );
1309
1310 virtual real
1311 jc_custom( const real T ) const ;
1312
1313 virtual real
1314 n_custom( const real T ) const ;
1315
1319 real
1320 volumetric_heatload( const real x, const real y, const real z, const real time ) const ;
1321
1322//------------------------------------------------------------------------------
1323 protected:
1324//------------------------------------------------------------------------------
1325
1329 real
1330 n_eval_raw( const real T, const real normB, const real angleNxB ) const ;
1331
1335 bool
1336 riva_rho_pl( const real normJ, const real jc, const real n, const real ec, real & rhoPL ) const ;
1337
1342 static real
1343 piecewise_bezier_sqrt( const real a, const real b, const real c ) ;
1344
1345//------------------------------------------------------------------------------
1359
1365 void
1366 create_spline( const MaterialProperty aProperty,
1367 const real adYdX0=BELFEM_QUIET_NAN,
1368 const real adYdX1=BELFEM_QUIET_NAN,
1369 const real aStep=4.0 ) ;
1370
1379 real
1380 alpha_switch_temperature() const ;
1381
1382 real
1383 density_const( const real T ) const ;
1384
1385 virtual real
1386 density_custom( const real T ) const ;
1387
1395 real
1396 return_zero( const real T ) const ;
1397
1398 real
1399 cp_const( const real T ) const ;
1400
1401 real
1402 dcpdT_finite_difference( const real T ) const ;
1403
1404 real
1405 d2cpdT2_finite_difference( const real T ) const ;
1406
1407 real
1408 cp_spline( const real T ) const ;
1409
1410 real
1411 dcpdT_spline( const real T ) const ;
1412
1413 real
1414 d2cpdT2_spline( const real T ) const ;
1415
1416 virtual real
1417 cp_custom( const real T ) const ;
1418
1419 virtual real
1420 dcpdT_custom( const real T ) const ;
1421
1422 virtual real
1423 d2cpdT2_custom( const real T ) const ;
1424
1425 real
1426 lambda_const( const real T ) const ;
1427
1428 real
1429 dlambdadT_finite_difference( const real T ) const ;
1430
1431 real
1432 lambda_spline( const real T ) const ;
1433
1434 real
1435 dlambdadT_spline( const real T ) const ;
1436
1437 virtual real
1438 lambda_custom( const real T ) const ;
1439
1440 virtual real
1441 dlambdadT_custom( const real T ) const ;
1442
1443 real
1444 drhodT_finite_difference( const real T ) const ;
1445
1446 real
1447 rho_const( const real T ) const ;
1448
1449 virtual real
1450 rho_custom( const real T ) const ;
1451
1452 virtual real
1453 drhodT_custom( const real T ) const ;
1454
1455 virtual real
1456 rho_spline( const real T ) const ;
1457
1458 virtual real
1459 drhodT_spline( const real T ) const ;
1460
1461 virtual real
1462 rho_kohler( const real T, const real normB, const real angleJxB ) const ;
1463
1464 virtual real
1465 drhodT_kohler( const real T, const real normB, const real angleJxB ) const ;
1466
1467 virtual real
1468 drhodB_kohler( const real T, const real normB, const real angleJxB ) const ;
1469
1470 virtual real
1471 drhodbeta_kohler( const real T, const real normB, const real angleJxB ) const ;
1472
1473 virtual real
1474 rho_table( const real T, const real normB, const real angleJxB ) const ;
1475
1476 virtual real
1477 drhodT_table( const real T, const real normB, const real angleJxB ) const ;
1478
1479 virtual real
1480 drhodB_table( const real T, const real normB, const real angleJxB ) const ;
1481
1482 virtual real
1483 drhodbeta_table( const real T, const real normB, const real angleJxB ) const ;
1484
1485 virtual real
1486 lambda_custom( const real T, const real normB, const real angle ) const ;
1487
1488 virtual real
1489 lambda_table( const real T, const real normB, const real angle ) const ;
1490
1491 real
1492 H_const( const real B ) const ;
1493
1494 virtual real
1495 H_bhcurve( const real B ) const ;
1496
1497 real
1498 mu_const( const real H, const real T ) const ;
1499
1500 virtual real
1501 mu_bhcurve( const real H, const real T ) const ;
1502
1503 virtual real
1504 mu_custom( const real H, const real T ) const ;
1505
1506 void
1507 dmudH_const( const real H, real & mu, real & dmudH ) const ;
1508
1509 virtual void
1510 dmudH_bhcurve( const real H, real & mu, real & dmudH ) const ;
1511
1512 real
1513 E_const( const real T ) const ;
1514
1515 real
1516 E_spline( const real T) const ;
1517
1518 virtual real
1519 E_custom( const real T ) const ;
1520
1521 virtual real
1522 dEdT_custom( const real T ) const ;
1523
1524 real
1525 nu_const( const real T ) const ;
1526
1527 real
1528 nu_spline( const real T ) const ;
1529
1530 virtual real
1531 nu_custom( const real T ) const ;
1532
1533 real
1534 alpha_const( const real T ) const ;
1535
1536 real
1537 alpha_spline( const real T ) const ;
1538
1539 virtual real
1540 alpha_custom( const real T ) const ;
1541
1542 real
1543 Rp02_const( const real T ) const ;
1544
1545 real
1546 Rp02_spline( const real T ) const ;
1547
1548 virtual real
1549 Rp02_custom( const real T ) const ;
1550
1551 real
1552 debye_const( const real T ) const ;
1553
1554 real
1555 debye_spline( const real T ) const ;
1556
1557 virtual real
1558 debye_custom( const real T ) const ;
1559
1560 virtual real
1561 rho_i_custom( const real T ) const ;
1562
1563 real
1564 rho_i_spline( const real T ) const ;
1565
1566 virtual void
1567 reset_spline( const MaterialProperty aProperty ) ;
1568
1569 virtual void
1570 create_spline( real (Material::*aFunction)(const real aT) const,
1571 const MaterialProperty aProperty,
1572 const uint aStartBC,
1573 const uint aEndBC,
1574 const real adYdX0=BELFEM_QUIET_NAN,
1575 const real adYdX1=BELFEM_QUIET_NAN,
1576 const real aStep=4.0 ) ;
1577
1578 };
1579
1580 inline const string &
1582 {
1583 return mLabel ;
1584 }
1585
1586 inline const string &
1588 {
1589 return mNumber ;
1590 }
1591
1592 inline MaterialType
1594 {
1595 return mType ;
1596 }
1597
1598 inline void
1599 Material::flag( const uint8_t aIndex )
1600 {
1601 BELFEM_ASSERT( aIndex < 8, "Flag index %u out of bounds (must be < 8)",
1602 ( unsigned int ) aIndex );
1603 mFlags |= ( 1 << aIndex );
1604 }
1605
1606 inline void
1607 Material::unflag( const uint8_t aIndex )
1608 {
1609 BELFEM_ASSERT( aIndex < 8, "Flag index %u out of bounds (must be < 8)",
1610 ( unsigned int ) aIndex );
1611 mFlags &= ~( 1 << aIndex );
1612 }
1613
1614 inline bool
1615 Material::is_flagged( const uint8_t aIndex ) const
1616 {
1617 BELFEM_ASSERT( aIndex < 8, "Flag index %u out of bounds (must be < 8)",
1618 ( unsigned int ) aIndex );
1619 return mFlags & ( 1 << aIndex );
1620 }
1621
1622 inline bool
1623 Material::have( const MaterialProperty aProperty ) const
1624 {
1625 return mHaveProperty.test( static_cast< size_t >( aProperty ) ) ;
1626 }
1627
1628 inline bool
1630 {
1631 return mDefectFunction != nullptr ;
1632 }
1633
1634 inline bool
1636 {
1637 return mHeatFunction != nullptr ;
1638 }
1639
1640 inline bool
1642 {
1643 return mResistivityLaw == ResistivityLaw::Piecewise ;
1644 }
1645
1646 inline bool
1648 {
1649 return mResistivityLaw == ResistivityLaw::Riva ;
1650 }
1651
1652 inline ResistivityLaw
1654 {
1655 return mResistivityLaw ;
1656 }
1657
1658 inline bool
1659 Material::depends( const MaterialProperty aProperty, const MaterialDependency aDependency ) const
1660 {
1661 return mPropertyDependencies( static_cast< size_t >( aProperty ) )->test( static_cast< uint >( aDependency ));
1662 }
1663
1664 inline const MaterialDependencyBitset *
1666 {
1667 return mPropertyDependencies( static_cast< size_t >( aProperty ) ) ;
1668 }
1669
1670 inline bool
1672 {
1673 return mIsIsotropic ;
1674 }
1675
1676 inline bool
1678 {
1679 return ! std::isnan( mConstantProperties( static_cast< index_t >( aProperty ) ) ) ;
1680 }
1681
1682 inline real
1684 {
1685 BELFEM_ASSERT( this->is_constant( aProperty ), "Property is not constant" ) ;
1686 return mConstantProperties( static_cast< size_t >( aProperty ) ) ;
1687 }
1688
1689//------------------------------------------------------------------------------
1690
1691 inline real
1693 {
1695 "Material '%s' does not have density assigned", this->label().c_str() ) ;
1696
1697 return ( this->*mFunctionDensity )( T );
1698 }
1699
1700 inline real
1702 {
1704 "Wrong function call for Material::density");
1706 }
1707
1708 inline real
1710 {
1712 "Material %s does not have a reference density set", mLabel.c_str() );
1714 "Material %s does not have a temperature for the reference density set", mLabel.c_str() );
1715
1716 if ( T == mConstantProperties( static_cast< index_t >( MaterialProperty::T_ref_density ) ) )
1717 {
1718 return mConstantProperties( static_cast< index_t >( MaterialProperty::ref_density ) ) ;
1719 }
1720
1721 return mConstantProperties( static_cast< index_t >( MaterialProperty::ref_density ) ) / std::pow( this->l( T ), 3.0 ) ;
1722 }
1723
1724 inline real
1726 {
1728 "Material %s does not have a reference density set", mLabel.c_str() );
1730 }
1731
1732 inline real Material::M() const
1733 {
1734 return this->constant_property( MaterialProperty::M );
1735 }
1736
1737 inline real
1739 {
1740 BELFEM_ASSERT( this->have( MaterialProperty::cp ), "Material does not have specific heat capacity" ) ;
1741
1742 return ( this->*mFunctionCp )( T );
1743 }
1744
1745 inline real
1747 {
1749 }
1750
1751 inline real Material::dcpdT( const real T ) const
1752 {
1753 BELFEM_ASSERT( this->have( MaterialProperty::cp ), "Material does not have specific heat capacity" ) ;
1754
1755 return (this->*mFunctiondCpdT )( T ) ;
1756 }
1757
1758 inline real Material::d2cpdT2( const real T ) const
1759 {
1760 BELFEM_ASSERT( this->have( MaterialProperty::cp ), "Material does not have specific heat capacity" ) ;
1761
1762 return (this->*mFunctiond2CpdT2 )( T ) ;
1763 }
1764
1765 inline real
1767 {
1768 return 0. ;
1769 }
1770
1771 inline real
1773 {
1774 return 0.5 * ( this->cp( T + gFinDiffDeltaT )
1775 - this->cp( T - gFinDiffDeltaT ) ) /gFinDiffDeltaT ;
1776 }
1777
1778 inline real
1780 {
1781 return ( this->cp( T + gFinDiffDeltaT ) - 2. * this->cp( T )
1782 + this->cp( T - gFinDiffDeltaT ) ) / ( gFinDiffDeltaT * gFinDiffDeltaT );
1783 }
1784
1785 inline real
1787 {
1788 return this->spline_property( MaterialProperty::cp, T );
1789 }
1790
1791 inline real
1793 {
1794 return this->dspline_property( MaterialProperty::cp, T );
1795 }
1796
1797 inline real
1799 {
1800 return this->ddspline_property( MaterialProperty::cp, T );
1801 }
1802
1803//------------------------------------------------------------------------------
1804
1805 inline real
1806 Material::lambda( const real T ) const
1807 {
1808 BELFEM_ASSERT( this->is_isotropic(), "Material %s is not isotropic", mLabel.c_str() ) ;
1810 "Material does not have thermal conductivity" ) ;
1811 return (this->*mFunctionLambda )( T ) ;
1812 }
1813
1814 inline real
1816 {
1818 }
1819
1820 inline real
1821 Material::dlambdadT( const real T ) const
1822 {
1823 BELFEM_ASSERT( this->is_isotropic(), "Material %s is not isotropic", mLabel.c_str() ) ;
1825 "Material does not have thermal conductivity" ) ;
1826
1827 return (this->*mFunctiondLambdadT )( T ) ;
1828 }
1829
1830 inline real
1832 {
1833 return 0.5 * ( this->lambda( T + gFinDiffDeltaT )
1834 - this->lambda( T - gFinDiffDeltaT ) ) /gFinDiffDeltaT ;
1835 }
1836
1837 inline real
1839 {
1840 return this->spline_property( MaterialProperty::lambda, T );
1841 }
1842
1843 inline real
1845 {
1846 return this->dspline_property( MaterialProperty::lambda, T );
1847 }
1848
1849 inline real
1850 Material::lambda( const real T, const real B, const real beta ) const
1851 {
1852 BELFEM_ASSERT( this->is_isotropic(), "Material %s is not isotropic", mLabel.c_str() ) ;
1854 "Material %s does not have thermal conductivity", mLabel.c_str() ) ;
1855
1857 "wrong function call for Material::lambda in material %s", mLabel.c_str() ) ;
1858
1859 return this->lambda( T );
1860 }
1861
1862 inline real
1863 Material::dlambdadT( const real T, const real B, const real beta ) const
1864 {
1865 BELFEM_ASSERT( this->is_isotropic(), "Material %s is not isotropic", mLabel.c_str() ) ;
1867 "Material %s does not have thermal conductivity", mLabel.c_str() ) ;
1868
1870 "wrong function call for Material::dlambdadT in material %s", mLabel.c_str() ) ;
1871
1872 return this->dlambdadT( T );
1873 }
1874
1875 inline real
1876 Material::dlambdadB( const real T, const real B, const real beta ) const
1877 {
1878 BELFEM_ASSERT( this->is_isotropic(), "Material %s is not isotropic", mLabel.c_str() ) ;
1880 "Material %s does not have thermal conductivity", mLabel.c_str() ) ;
1881
1883 "wrong function call for Material::dlambdadB in material %s", mLabel.c_str() ) ;
1884
1885 return 0.;
1886 }
1887
1888 inline real
1889 Material::dlambdadbeta( const real T, const real B, const real beta ) const
1890 {
1891 BELFEM_ASSERT( this->is_isotropic(), "Material %s is not isotropic", mLabel.c_str() ) ;
1893 "Material %s does not have thermal conductivity", mLabel.c_str() ) ;
1894
1896 "wrong function call for Material::dlambdadbeta in material %s", mLabel.c_str() ) ;
1897
1898 return 0.;
1899 }
1900
1901//------------------------------------------------------------------------------
1902
1903 inline real
1904 Material::lambda( const real T, const real B_par, const real B_perp, const real J ) const
1905 {
1906 BELFEM_ASSERT( this->is_isotropic(), "Material %s is not isotropic", mLabel.c_str() ) ;
1908 "Material %s does not have thermal conductivity", mLabel.c_str() ) ;
1909
1910 BELFEM_ASSERT( mType == MaterialType::HTS, "wrong function call for Material::lambda" ) ;
1911
1912 return this->lambda( T );
1913 }
1914
1915 inline real
1916 Material::dlambdadT( const real T, const real B_par, const real B_perp, const real J )const
1917 {
1918 BELFEM_ASSERT( this->is_isotropic(), "Material %s is not isotropic", mLabel.c_str() ) ;
1920 "Material %s does not have thermal conductivity", mLabel.c_str() ) ;
1921
1923 "wrong function call for Material::dlambdadT in material %s", mLabel.c_str() ) ;
1924
1925 return this->dlambdadT( T );
1926 }
1927
1928//------------------------------------------------------------------------------
1929
1930 inline real
1931 Material::rho( const real T ) const
1932 {
1933 BELFEM_ASSERT( this->is_isotropic(), "Material %s is not isotropic", mLabel.c_str() ) ;
1935 "Material %s does not have electric resistivity", mLabel.c_str() ) ;
1936
1937 return ( this->*mFunctionRho )( T ) ;
1938 }
1939
1940 inline real
1941 Material::drhodT( const real T ) const
1942 {
1943 BELFEM_ASSERT( this->is_isotropic(), "Material %s is not isotropic", mLabel.c_str() ) ;
1945 "Material %s does not have electric resistivity", mLabel.c_str() ) ;
1946
1947 return ( this->*mFunctiondRhodT )( T ) ;
1948 }
1949
1950 inline real
1952 {
1953 return 0.5 * ( this->rho( T + gFinDiffDeltaT )
1954 - this->rho( T - gFinDiffDeltaT ) ) / gFinDiffDeltaT ;
1955 }
1956
1957 inline real
1958 Material::rho_const( const real T ) const
1959 {
1961 }
1962
1963 inline real
1965 {
1966 return this->drhodT_finite_difference( T );
1967 }
1968
1969 inline real
1971 {
1972 return this->spline_property( MaterialProperty::rho, T );
1973 }
1974
1975 inline real
1977 {
1978 return this->dspline_property( MaterialProperty::rho, T );
1979 }
1980
1981 inline real
1982 Material::rho( const real T, const real B, const real beta ) const
1983 {
1984
1985 BELFEM_ASSERT( mFunctionRhoKohler != nullptr, "Material %s does not have a Kohler function", mLabel.c_str() ) ;
1986
1988 "wrong function call for Material::rho in %s", mLabel.c_str() ) ;
1989
1990 return this->rho( T );
1991 }
1992
1993 inline real
1994 Material::drhodT( const real T, const real B, const real beta ) const
1995 {
1996
1997 BELFEM_ASSERT( mFunctionRhoKohler != nullptr, "Material %s does not have a Kohler function", mLabel.c_str() ) ;
1998
2000 "wrong function call for Material::drhodT in %s", mLabel.c_str() ) ;
2001
2002 return this->drhodT( T );
2003 }
2004
2005 // base fallback: a metal without field-dependent resistivity has no
2006 // B or beta sensitivity — no Kohler function required here, the
2007 // Metal override handles the field-dependent case
2008 inline real
2009 Material::drhodB( const real T, const real B, const real beta ) const
2010 {
2012 "wrong function call for Material::drhodB in %s", mLabel.c_str() ) ;
2013
2014 return 0. ;
2015 }
2016
2017 inline real
2018 Material::drhodbeta( const real T, const real B, const real beta ) const
2019 {
2021 "wrong function call for Material::drhodbeta in %s", mLabel.c_str() ) ;
2022
2023 return 0. ;
2024 }
2025
2026//------------------------------------------------------------------------------
2027
2028 inline real
2029 Material::H( const real B ) const
2030 {
2031 return (this->*mFunctionH ) ( B );
2032 }
2033
2034 inline real
2035 Material::H_const( const real B ) const
2036 {
2037 return B * constant::nu0 ;
2038 }
2039
2040//------------------------------------------------------------------------------
2041
2042 inline real
2043 Material::mu( real H, const real T ) const
2044 {
2045 return ( this->*mFunctionMu )( H, T );
2046 }
2047
2048 inline real
2049 Material::mu_const( real H, const real T ) const
2050 {
2052 }
2053
2054//------------------------------------------------------------------------------
2055
2056 inline void
2057 Material::dmudH( const real H, real & mu, real & dmudH ) const
2058 {
2059 ( this->*mFunctionDMuDH )( H, mu, dmudH );
2060 }
2061
2062 inline void
2064 {
2066 dmudH = 0.0 ;
2067 }
2068
2069//------------------------------------------------------------------------------
2070
2071 inline real
2073 {
2074 BELFEM_ASSERT( this->is_isotropic(), "Material %s is not isotropic", mLabel.c_str() ) ;
2076 "Material %s does not have Youngs Modulus", mLabel.c_str() ) ;
2077 return ( this->*mFunctionE )( T );
2078 }
2079
2080 inline real
2081 Material::E_const( const real T ) const
2082 {
2083 return this->constant_property( MaterialProperty::E );
2084 }
2085
2086 inline real
2087 Material::E_spline( const real T ) const
2088 {
2089 return this->spline_property( MaterialProperty::E, T );
2090 }
2091
2092//------------------------------------------------------------------------------
2093
2094 inline real
2096 {
2097 BELFEM_ASSERT( this->is_isotropic(),
2098 "Material %s is not isotropic", mLabel.c_str() ) ;
2100 "Material does not have Poisson Ratio" ) ;
2101
2102 return ( this->*mFunctionNu )( T );
2103 }
2104
2105 inline real
2106 Material::nu_const( const real T ) const
2107 {
2109 }
2110
2111 inline real
2112 Material::nu_spline( const real T ) const
2113 {
2114 return this->spline_property( MaterialProperty::nu, T );
2115 }
2116
2117//------------------------------------------------------------------------------
2118
2119 inline real
2121 {
2122 return this->E( T ) / ( 2.0 * ( 1.0 + this->nu( T ) ) ) ;
2123 }
2124
2125//------------------------------------------------------------------------------
2126
2127 inline real
2129 {
2130 return this->E( T ) / ( 3.0 * ( 1.0 - 2.0 * this->nu( T ) ) ) ;
2131 }
2132
2133//------------------------------------------------------------------------------
2134
2135 inline real
2137 {
2138 BELFEM_ASSERT( this->is_isotropic(), "Material %s is not isotropic", mLabel.c_str() ) ;
2140 "Material %s does not have thermal expansion", mLabel.c_str() ) ;
2141
2142 return ( this->*mFunctionAlpha )( T );
2143 }
2144
2145 inline real
2147 {
2149 }
2150
2151 inline real
2153 {
2154 return this->spline_property( MaterialProperty::alpha, T );
2155 }
2156
2157//------------------------------------------------------------------------------
2158
2159//------------------------------------------------------------------------------
2160
2161 inline real
2163 {
2164 BELFEM_ASSERT( this->is_isotropic(), "Material %s is not isotropic", mLabel.c_str() ) ;
2166 "Material %s does not have yield stress", mLabel.c_str() ) ;
2167
2168 return ( this->*mFunctionRp02 )( T );
2169 }
2170
2171 inline real
2173 {
2175 }
2176
2177 inline real
2179 {
2180 return this->spline_property( MaterialProperty::Rp02, T );
2181 }
2182
2183//------------------------------------------------------------------------------
2184
2185 inline real
2187 {
2188 BELFEM_ASSERT( this->is_isotropic(), "Material %s is not isotropic", mLabel.c_str() ) ;
2190 "Material %s does not have Debye temperature", mLabel.c_str() ) ;
2191
2192 return ( this->*mFunctionDebye )( T );
2193 }
2194
2195 inline real
2197 {
2199 }
2200
2201 inline real
2203 {
2204 return this->spline_property( MaterialProperty::debye, T );
2205 }
2206
2207 inline real
2208 Material::rho_i( const real T ) const
2209 {
2210 return ( this->*mFunctionRhoI )( T );
2211 }
2212
2213 inline real
2215 {
2216 return this->spline_property( MaterialProperty::rho_i, T );
2217 }
2218
2219//------------------------------------------------------------------------------
2220
2221 inline real
2223 {
2224 BELFEM_ASSERT( ! std::isnan( mTAlphaSwitch ),
2225 "%s: alpha split temperature is not set, create_low_temperature_alpha() "
2226 "must run before alpha is evaluated", mLabel.c_str() );
2227 return mTAlphaSwitch ;
2228 }
2229
2230//------------------------------------------------------------------------------
2231
2232 inline real
2233 Material::volumetric_heatload( const real x, const real y, const real z, const real time ) const
2234 {
2235 BELFEM_ASSERT( mHeatFunction != nullptr , "No heat function set for material %s", mLabel.c_str() ) ;
2236 return this->mHeatFunction( x, y, z, time ) ;
2237 }
2238
2239}
2240
2241#include "powerlaws.hpp"
2242
2243// The pop MUST mirror the push at the top of this header condition for
2244// condition. It used to test BELFEM_CLANG / BELFEM_GCC / BELFEM_INTEL, which
2245// are BELFEM build defines, while the push tests compiler builtins. A
2246// translation unit that includes this header without those defines -- every
2247// user-material plugin built from UserMaterialTemplate.cmake -- therefore
2248// pushed and never popped, silently disabling -Wformat, -Wunused-variable and
2249// -Wunused-parameter for the rest of the file.
2250#if defined(__clang__)
2251#pragma clang diagnostic pop
2252
2253#elif defined(__GNUC__) || defined(__GNUG__)
2254#pragma GCC diagnostic pop
2255
2256#elif defined(BELFEM_INTEL)
2257#pragma warning(pop)
2258
2259#endif
2260
2261#endif //BELFEM_CL_MATERIAL_HPP
#define BELFEM_ASSERT(aCheck,...)
Definition assert.hpp:244
Base class hierarchy for critical current density (Jc) and n-value functions.
Bitset()=default
trivial constructor
Base class for all materials in BELFEM.
Definition cl_Material.hpp:270
void reset_dependencies(const MaterialProperty aProperty)
Definition cl_Material.cpp:237
virtual real drhodB_kohler(const real T, const real normB, const real angleJxB) const
Definition cl_Material.cpp:615
virtual void dmudH_bhcurve(const real H, real &mu, real &dmudH) const
Definition cl_Material.cpp:987
virtual real dEdT_custom(const real T) const
Definition cl_Material.cpp:532
real dcpdT_spline(const real T) const
Definition cl_Material.hpp:1792
void set_user_defined_heating(HeatFunc *Function)
Set a user-defined volumetric heat load [ W/m³ ] as a function of x, y, z [ m ] and t [ s ].
Definition cl_Material.cpp:793
virtual real d2cpdT2(const real T=gTroom) const
Definition cl_Material.hpp:1758
virtual real H(const real B) const
Magnetic field strength from flux density.
Definition cl_Material.hpp:2029
real Rp02_spline(const real T) const
Definition cl_Material.hpp:2178
const MaterialDependencyBitset * dependencies(const MaterialProperty aProperty) const
Definition cl_Material.hpp:1665
void set_label(const string &aLabel)
PROTECTED INTERFACE FOR DERIVED MATERIALS.
Definition cl_Material.cpp:205
bool have(const MaterialProperty aProperty) const
Definition cl_Material.hpp:1623
void dmudH_const(const real H, real &mu, real &dmudH) const
Definition cl_Material.hpp:2063
Material(const MaterialType aType, const bool aIsIsotropic=true)
Definition cl_Material.cpp:149
void set_constant(const MaterialProperty aProperty, const real aValue)
Definition cl_Material.cpp:257
bool is_constant(const MaterialProperty aProperty) const
Definition cl_Material.hpp:1677
real rho_powerlaw(const real normJ) const
Power law resistivity for HTS (constant jc and n).
Definition powerlaws.hpp:202
virtual real K(real T=gTroom) const
Bulk modulus.
Definition cl_Material.hpp:2128
virtual real rho(const real T) const
Electrical resistivity (isotropic).
Definition cl_Material.hpp:1931
virtual real jc_custom(const real T) const
Definition cl_Material.cpp:581
virtual real drhodT_kohler(const real T, const real normB, const real angleJxB) const
Definition cl_Material.cpp:608
real lambda_const(const real T) const
Definition cl_Material.hpp:1815
real n(const real normB, const real angleNxB, const real T) const
Direct evaluation of the n-value as a function of , and .
Definition powerlaws.hpp:992
void set_resistivity_law(const ResistivityLaw aLaw)
Definition cl_Material.cpp:807
virtual real E(real T=gTroom) const
Young's modulus.
Definition cl_Material.hpp:2072
real cp_const(const real T) const
Definition cl_Material.hpp:1746
MaterialType type() const
Definition cl_Material.hpp:1593
virtual void dmudH(const real H, real &mu, real &dmudH) const
Magnetic permeability and its derivative.
Definition cl_Material.hpp:2057
virtual real drhodbeta_table(const real T, const real normB, const real angleJxB) const
Definition cl_Material.cpp:650
real rho_const(const real T) const
Definition cl_Material.hpp:1958
virtual real lambda(const real T=gTroom) const
Thermal conductivity (isotropic).
Definition cl_Material.hpp:1806
real n_eval_raw(const real T, const real normB, const real angleNxB) const
Definition powerlaws.hpp:94
real drho_riva_dB(const real normJ, const real T, const real normB, const real angleNxB) const
dρ/d|B| of rho_riva: w²·dρ_PL/dB ( dρ_n/dB = 0 on this path )
Definition powerlaws.hpp:2615
virtual real alpha_custom(const real T) const
Definition cl_Material.cpp:553
virtual real lambda_custom(const real T) const
Definition cl_Material.cpp:512
virtual real evaluate_polynomial(const MaterialProperty Property, const real T) const
Evaluate a polynomial for a given property (for UserDefinedMaterial).
Definition cl_Material.cpp:924
Material(Material &&)=delete
virtual real rho_spline(const real T) const
Definition cl_Material.hpp:1970
const material::JcFunction * mJcFunction
Definition cl_Material.hpp:404
virtual real cp(const real T=gTroom) const
Specific heat capacity.
Definition cl_Material.hpp:1738
bool depends(const MaterialProperty aProperty, const MaterialDependency aDependency) const
Definition cl_Material.hpp:1659
real dcpdT_finite_difference(const real T) const
Definition cl_Material.hpp:1772
virtual real drhodT(const real T) const
Definition cl_Material.hpp:1941
bool is_isotropic() const
Definition cl_Material.hpp:1671
bool use_piecewise() const
Definition cl_Material.hpp:1641
void load_bh_curve(const material::BhCurve *aCurve)
Activate a B-H curve as the permeability source (ferromagnets).
Definition cl_Material.cpp:957
void set_number(const string &aNumber)
Definition cl_Material.cpp:211
virtual real drhodbeta_kohler(const real T, const real normB, const real angleJxB) const
Definition cl_Material.cpp:622
virtual real spline_property(const MaterialProperty aProperty, const real aX) const
Definition cl_Material.cpp:999
void set_user_defined_defect(DefectFunc *Function)
Set a user-defined defect function with x, y, z, t dependencies.
Definition cl_Material.cpp:785
real drho_piecewise_dT(const real normJ, const real T, const real normB, const real angleNxB) const
Derivative of piecewise resistivity with respect to T at fixed J, |B|, θ ( T-leg ).
Definition powerlaws.hpp:2209
real jc_eval(const real T, const real normB, const real angleNxB) const
O1 "full-signature policy" helpers: the assembly path always passes the full ( T, normB,...
Definition powerlaws.hpp:84
real dlambdadT_spline(const real T) const
Definition cl_Material.hpp:1844
void set_custom(const MaterialProperty aProperty)
Definition cl_Material.cpp:396
virtual real drhodT_custom(const real T) const
Definition cl_Material.hpp:1964
real drho_piecewise_dB(const real normJ, const real T, const real normB, const real angleNxB) const
Derivative of piecewise resistivity with respect to |B| at fixed J, T, θ
Definition powerlaws.hpp:2058
void read_heating(const string &aLibraryPath, const string &aLabel)
Read a heating function from a plugin library.
Definition cl_Material.cpp:894
real H_const(const real B) const
Definition cl_Material.hpp:2035
real drho_piecewise_dJ(const real normJ, const real T, const real normB, const real angleNxB) const
Derivative of piecewise resistivity with respect to current density magnitude.
Definition powerlaws.hpp:1830
real(Material::*) mFunctiondRhoKohlerdB(const real T, const real normB, const real angle) const
Definition cl_Material.hpp:395
real debye_const(const real T) const
Definition cl_Material.hpp:2196
real cp_spline(const real T) const
Definition cl_Material.hpp:1786
real drho_riva_dJ(const real normJ, const real T, const real normB, const real angleNxB) const
dρ/d|J| of rho_riva: w²·dρ_PL/dJ with w = ρ_n/(ρ_PL+ρ_n)
Definition powerlaws.hpp:2584
virtual real dlambdadB(const real T, const real B, const real beta) const
Definition cl_Material.hpp:1876
real density_const(const real T) const
Definition cl_Material.hpp:1701
real drhodT_finite_difference(const real T) const
Definition cl_Material.hpp:1951
real(Material::*) mFunctiondRhoKohlerdT(const real T, const real normB, const real angle) const
Definition cl_Material.hpp:394
virtual real rho_i(const real T) const
Intrinsic (phonon) electrical resistivity of a metal, ρ = ρ_i(T) + ρ_0.
Definition cl_Material.hpp:2208
real return_zero(const real T) const
Shared binding for derivative channels that are identically zero.
Definition cl_Material.hpp:1766
real dn_eval_dB(const real T, const real normB, const real angleNxB) const
d(n)/d|B|, same routing as djc_eval_dB
Definition powerlaws.hpp:128
virtual void set_bh_curve(const material::BhCurve *aCurve)
Assign a B-H curve to this material.
Definition cl_Material.cpp:671
void(Material::*) mFunctionDMuDH(double, double &, double &) const
Definition cl_Material.hpp:400
void set_dependency(const MaterialProperty aProperty, const MaterialDependency aDependency)
Definition cl_Material.cpp:246
void set_jc_function(const material::JcFunction *aFunction)
Assign a critical current density function.
Definition cl_Material.cpp:677
virtual void set_user_defined_polynomial(const MaterialProperty Property, const std::vector< real > &Coefficients)
Set a polynomial function for a property (for UserDefinedMaterial).
Definition cl_Material.cpp:949
bool have_defect() const
Definition cl_Material.hpp:1629
virtual real rho_custom(const real T) const
Definition cl_Material.cpp:574
real volumetric_heatload(const real x, const real y, const real z, const real time) const
Artificial volumetric heat load [ W/m³ ] from the heating plugin.
Definition cl_Material.hpp:2233
virtual real dlambdadT_custom(const real T) const
Definition cl_Material.cpp:519
void set_have(const MaterialProperty aProperty, const bool aHave=true)
Definition cl_Material.cpp:224
virtual real drhodB(const real T, const real B, const real beta) const
Definition cl_Material.hpp:2009
virtual real mu_bhcurve(const real H, const real T) const
Definition cl_Material.cpp:979
real drho_powerlaw_dB(const real normJ, const real T, const real normB, const real angleNxB) const
Derivative of power-law resistivity with respect to |B| at fixed J, T, θ ( jc = jc(T,...
Definition powerlaws.hpp:2002
virtual real density_custom(const real T) const
Definition cl_Material.hpp:1709
static real piecewise_bezier_sqrt(const real a, const real b, const real c)
Definition powerlaws.hpp:67
virtual real evaluate_derivative_of_polynomial(const MaterialProperty Property, const real T) const
Definition cl_Material.cpp:932
virtual real drhodT_table(const real T, const real normB, const real angleJxB) const
Definition cl_Material.cpp:636
real rho_piecewise(const real normJ) const
Piecewise resistivity for HTS (constant jc and n).
Definition powerlaws.hpp:430
const string & number() const
Empty if the material has no number.
Definition cl_Material.hpp:1587
real(Material::*) mFunctionMu(const real H, const real T) const
Definition cl_Material.hpp:399
virtual real lambda_table(const real T, const real normB, const real angle) const
Definition cl_Material.cpp:664
real djc_eval_dB(const real T, const real normB, const real angleNxB) const
Definition powerlaws.hpp:120
bool riva_rho_pl(const real normJ, const real jc, const real n, const real ec, real &rhoPL) const
Definition powerlaws.hpp:2519
real n_eval(const real T, const real normB, const real angleNxB) const
Definition powerlaws.hpp:104
real jc(const real normB, const real angleNxB, const real T) const
Direct evaluation of the critical current density .
Definition powerlaws.hpp:1023
virtual real rho_i_custom(const real T) const
Definition cl_Material.cpp:594
void set_piecewise(const bool aUsePiecewise)
Definition cl_Material.cpp:800
real djc_eval_dT(const real T, const real normB, const real angleNxB) const
Definition powerlaws.hpp:144
real dn_eval_dT(const real T, const real normB, const real angleNxB) const
d(n)/dT, same routing as djc_eval_dT
Definition powerlaws.hpp:152
real M() const
Molar mass [kg/mol].
Definition cl_Material.hpp:1732
virtual real H_bhcurve(const real B) const
Definition cl_Material.cpp:972
const string & label() const
Definition cl_Material.hpp:1581
void flag(const uint8_t aIndex=0)
Definition cl_Material.hpp:1599
virtual real drhodT_spline(const real T) const
Definition cl_Material.hpp:1976
real Rp02_const(const real T) const
Definition cl_Material.hpp:2172
virtual real drhodbeta(const real T, const real B, const real beta) const
Definition cl_Material.hpp:2018
bool have_heating() const
Definition cl_Material.hpp:1635
virtual void set_user_defined_function(const MaterialProperty Property, const MaterialDependency Dependency, MatFunc1 *Function)
Set a user-defined function with one dependency (for UserDefinedMaterial).
Definition cl_Material.cpp:755
real drho_powerlaw_dT(const real normJ, const real T, const real normB, const real angleNxB) const
Derivative of power-law resistivity with respect to T at fixed J, |B|, θ ( T-leg: jc(T),...
Definition powerlaws.hpp:2151
ResistivityLaw resistivity_law() const
Definition cl_Material.hpp:1653
virtual real rho_table(const real T, const real normB, const real angleJxB) const
Definition cl_Material.cpp:629
virtual real dspline_property(const MaterialProperty aProperty, const real aX) const
Definition cl_Material.cpp:1006
real nu_spline(const real T) const
Definition cl_Material.hpp:2112
void check_riva_n_source() const
Definition cl_Material.cpp:818
virtual real density(const real T=gTroom) const
Density as a function of temperature.
Definition cl_Material.hpp:1692
virtual real drhodB_table(const real T, const real normB, const real angleJxB) const
Definition cl_Material.cpp:643
void unflag(const uint8_t aIndex=0)
Definition cl_Material.hpp:1607
Material & operator=(const Material &)=delete
real debye_spline(const real T) const
Definition cl_Material.hpp:2202
virtual real G(real T=gTroom) const
Shear modulus.
Definition cl_Material.hpp:2120
real dlambdadT_finite_difference(const real T) const
Definition cl_Material.hpp:1831
real constant_property(const MaterialProperty aProperty) const
Definition cl_Material.hpp:1683
virtual real nu_custom(const real T) const
Definition cl_Material.cpp:539
virtual real l(real T) const
Relative length after thermal expansion.
Definition cl_Material.cpp:1038
virtual real dlambdadbeta(const real T, const real B, const real beta) const
Definition cl_Material.hpp:1889
Material & operator=(Material &&)=delete
virtual real rho_kohler(const real T, const real normB, const real angleJxB) const
Definition cl_Material.cpp:601
real(Material::*) mFunctionRhoKohler(const real T, const real normB, const real angle) const
Definition cl_Material.hpp:393
virtual real ddspline_property(const MaterialProperty aProperty, const real aX) const
Definition cl_Material.cpp:1013
real E_const(const real T) const
Definition cl_Material.hpp:2081
virtual void set_table_flags(const bool aFlag)
Definition cl_Material.cpp:993
virtual real dcpdT_custom(const real T) const
Definition cl_Material.cpp:499
real alpha_spline(const real T) const
Definition cl_Material.hpp:2152
Material(const Material &)=delete
virtual real Rp02(real T=gTroom) const
Yield stress (0.2% offset).
Definition cl_Material.hpp:2162
real nu_const(const real T) const
Definition cl_Material.hpp:2106
real d2cpdT2_spline(const real T) const
Definition cl_Material.hpp:1798
virtual void set_RRR(const real RRR)
RRR = rho( 273 K ) / rho( 0 K ); noble metals only.
Definition cl_Material.cpp:217
real E_spline(const real T) const
Definition cl_Material.hpp:2087
const material::JcFunction * mNFunction
Definition cl_Material.hpp:405
real drho_riva_dT(const real normJ, const real T, const real normB, const real angleNxB) const
dρ/dT of rho_riva: w²·dρ_PL/dT + (1−w)²·dρ_n/dT
Definition powerlaws.hpp:2658
real(Material::*) mFunctiondRhoKohlerdbeta(const real T, const real normB, const real angle) const
Definition cl_Material.hpp:396
real lambda_spline(const real T) const
Definition cl_Material.hpp:1838
virtual real debye_custom(const real T) const
Definition cl_Material.cpp:567
real d2cpdT2_finite_difference(const real T) const
Definition cl_Material.hpp:1779
virtual real E_custom(const real T) const
Definition cl_Material.cpp:525
virtual real mu_custom(const real H, const real T) const
Definition cl_Material.cpp:546
real drho_powerlaw_dJ(const real normJ, const real T, const real normB, const real angleNxB) const
Derivative of power-law resistivity with respect to current density magnitude.
Definition powerlaws.hpp:1251
virtual real cp_custom(const real T) const
Definition cl_Material.cpp:492
real mu_const(const real H, const real T) const
Definition cl_Material.hpp:2049
real(Material::*) mFunctionH(const real B) const
Definition cl_Material.hpp:398
virtual real d2cpdT2_custom(const real T) const
Definition cl_Material.cpp:506
real alpha_const(const real T) const
Definition cl_Material.hpp:2146
virtual real debye(const real T) const
Debye temperature.
Definition cl_Material.hpp:2186
void read_defect(const string &aLibraryPath, const string &aLabel)
Read a defect from the library.
Definition cl_Material.cpp:864
virtual real dlambdadT(const real T=gTroom) const
Definition cl_Material.hpp:1821
void set_n_function(const material::JcFunction *aFunction)
Assign a power law exponent function.
Definition cl_Material.cpp:705
virtual real dcpdT(const real T=gTroom) const
Definition cl_Material.hpp:1751
real alpha_switch_temperature() const
Temperature below which alpha is taken from the Grueneisen branch.
Definition cl_Material.hpp:2222
real ref_density() const
Reference density at reference temperature.
Definition cl_Material.hpp:1725
virtual real mu(const real H, const real T=BELFEM_QUIET_NAN) const
Magnetic permeability.
Definition cl_Material.hpp:2043
virtual real nu(real T=gTroom) const
Poisson's ratio.
Definition cl_Material.hpp:2095
bool use_riva() const
Definition cl_Material.hpp:1647
bool is_flagged(const uint8_t aIndex=0) const
Definition cl_Material.hpp:1615
virtual real alpha(real T=gTroom) const
Thermal expansion coefficient.
Definition cl_Material.hpp:2136
real rho_i_spline(const real T) const
Definition cl_Material.hpp:2214
real rho_riva(const real normJ, const real T, const real normB, const real angleNxB) const
Riva-law resistivity: the superconducting power-law channel in parallel with the normal-state channel...
Definition powerlaws.hpp:2554
virtual real n_custom(const real T) const
Definition cl_Material.cpp:588
virtual real Rp02_custom(const real T) const
Definition cl_Material.cpp:560
real drhodB(const real T, const real B, const real beta) const override
Definition cl_Material_Alloy.hpp:173
real dlambdadT(const real T, const real B, const real beta) const override
Definition cl_Material_Alloy.hpp:213
real lambda(const real T, const real B, const real beta) const override
Thermal conductivity with magnetoresistance.
Definition cl_Material_Alloy.hpp:207
real drhodT(const real T, const real B, const real beta) const override
Definition cl_Material_Alloy.hpp:157
real drhodbeta(const real T, const real B, const real beta) const override
Definition cl_Material_Alloy.hpp:190
real rho(const real T, const real B, const real beta) const override
Electrical resistivity with magnetoresistance (Kohler's rule).
Definition cl_Material_Alloy.hpp:145
B-H curve for ferromagnetic materials.
Definition cl_BhCurve.hpp:61
Base class for critical current density (Jc) and n-value functions.
Definition cl_JcFunction.hpp:135
Definition cl_Material_SplineLookupTable.hpp:25
real l(real T) const override
Relative length after thermal expansion, from integrated alpha spline.
Definition cl_Material_SplineLookupTable.hpp:182
real ddspline_property(const MaterialProperty aProperty, const real aX) const override
Definition cl_Material_SplineLookupTable.hpp:174
void reset_spline(const MaterialProperty aProperty) override
Definition cl_Material_SplineLookupTable.cpp:115
real dspline_property(const MaterialProperty aProperty, const real aX) const override
Definition cl_Material_SplineLookupTable.hpp:166
void create_spline(real(Material::*aFunction)(const real aT) const, const MaterialProperty aProperty, const uint aStartBC, const uint aEndBC, const real adYdX0, const real adYdX1, const real aStep) override
Definition cl_Material_SplineLookupTable.cpp:123
real spline_property(const MaterialProperty aProperty, const real aX) const override
Definition cl_Material_SplineLookupTable.hpp:158
const real nu0
inverse of magnetic constant in (A*m)/(V*s)
Definition constants.hpp:80
USER GUIDES:
Definition cl_Capacitor.cpp:16
constexpr size_t gNumNonConstantMaterialProperties
Number of non-constant material properties.
Definition cl_Material.hpp:202
ResistivityLaw
E-J law used for a superconductor's resistivity.
Definition cl_Material.hpp:224
@ PowerLaw
Definition cl_Material.hpp:225
@ Riva
Definition cl_Material.hpp:227
@ Piecewise
Definition cl_Material.hpp:226
unit get_unit(const MaterialProperty aProperty)
Definition cl_Material.cpp:57
std::array< real, 7 > unit
Definition typedefs.hpp:71
MaterialDependency
Definition cl_Material.hpp:124
@ UNDEFINED
Definition cl_Material.hpp:133
@ angleBxJ
Definition cl_Material.hpp:127
@ Jc
Definition cl_Material.hpp:131
@ UserDefined
Definition cl_SourceFunction.hpp:66
constexpr real gTroom
Definition typedefs.hpp:63
unsigned int uint
Definition typedefs.hpp:30
constexpr real gTAlphaSwitchMax
Upper bound for the thermal expansion split temperature [K].
Definition cl_Material.hpp:47
real MatFunc1(const Material *, const real)
Definition cl_Material.hpp:232
int proc_t
Definition commtypes.hpp:29
constexpr real gDefaultEcrit
Critical electric field of the power law, in V/m, when none is given.
Definition cl_Material.hpp:55
real MatFunc3(const Material *, const real, const real, const real)
Definition cl_Material.hpp:234
MaterialProperty
All material properties that can be defined.
Definition cl_Material.hpp:153
@ nu
Definition cl_Material.hpp:156
@ gamma
Definition cl_Material.hpp:174
@ A_electron_magnon
Definition cl_Material.hpp:189
@ T_max
Definition cl_Material.hpp:171
@ UNDEFINED
Definition cl_Material.hpp:194
@ rho_0
Definition cl_Material.hpp:183
@ ref_density
Definition cl_Material.hpp:172
@ kohler_trans
Definition cl_Material.hpp:165
@ alpha
Definition cl_Material.hpp:161
@ ec
Definition cl_Material.hpp:185
@ A_bloch_gruen
Definition cl_Material.hpp:180
@ density
Definition cl_Material.hpp:154
@ E
Definition cl_Material.hpp:155
@ debye0K
Definition cl_Material.hpp:177
@ density_correction
Definition cl_Material.hpp:192
@ Tcurie
Definition cl_Material.hpp:188
@ M
Definition cl_Material.hpp:168
@ q
Definition cl_Material.hpp:176
@ A_spin_disorder
Definition cl_Material.hpp:190
@ rho
Definition cl_Material.hpp:160
@ mu
Definition cl_Material.hpp:159
@ lambda
Definition cl_Material.hpp:158
@ rho0_pure
Definition cl_Material.hpp:193
@ debye
Definition cl_Material.hpp:163
@ cp
Definition cl_Material.hpp:157
@ rho_i
Definition cl_Material.hpp:164
@ rho_i_ref
Definition cl_Material.hpp:178
@ Rp02
Definition cl_Material.hpp:162
@ jc
Definition cl_Material.hpp:186
@ layer_thickness
Definition cl_Material.hpp:184
@ kohler_long
Definition cl_Material.hpp:166
@ T_ref_rho_i
Definition cl_Material.hpp:179
@ Gamma
Definition cl_Material.hpp:169
@ T_ref_density
Definition cl_Material.hpp:173
@ n_bloch_gruen
Definition cl_Material.hpp:181
@ RRR
Definition cl_Material.hpp:182
@ grueneisen
Definition cl_Material.hpp:191
@ T_crit
Definition cl_Material.hpp:167
real HeatFunc(const real, const real, const real, const real)
Definition cl_Material.hpp:236
uint32_t index_t
Definition typedefs.hpp:52
real MatFunc2(const Material *, const real, const real)
Definition cl_Material.hpp:233
constexpr size_t gNumMaterialProperties
Definition cl_Material.hpp:204
constexpr real gFinDiffDeltaT
Definition typedefs.hpp:66
real DefectFunc(const real, const real, const real, const real)
Definition cl_Material.hpp:235
double real
Definition typedefs.hpp:36
Bitset< static_cast< size_t >(MaterialDependency::UNDEFINED) > MaterialDependencyBitset
Definition cl_Material.hpp:136
MaterialType
Material classification based on physical behavior.
Definition cl_Material.hpp:113
@ HTS
Definition cl_Material.hpp:116
@ LookupAlloy
Definition cl_Material.hpp:118
@ PureMetal
Definition cl_Material.hpp:117
@ NonMetal
Definition cl_Material.hpp:120
@ CompositeAlloy
Definition cl_Material.hpp:119
string to_string(const DomainType aDomainType)
Definition en_DomainType.cpp:21
Definition debye.f90:11
Inline E–J resistivity models for HTS materials and their Jacobians.
#define BELFEM_QUIET_NAN
Definition typedefs.hpp:86