Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries/ --ompython_omhome=/usr ModelicaTest_3.2.3_ModelicaTest.Fluid.TestComponents.Valves.TestValveVaporizing.conf.json loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaTest 3.2.3+maint.om/package.mo", uses=false) Using package ModelicaTest with version 3.2.3 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaTest 3.2.3+maint.om/package.mo) Using package Modelica with version 3.2.3 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/package.mo) Using package Complex with version 4.0.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo) Using package ModelicaServices with version 4.0.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo) Running command: "" <> buildModelFMU(ModelicaTest.Fluid.TestComponents.Valves.TestValveVaporizing,fileNamePrefix="ModelicaTest_3_2_3_ModelicaTest_Fluid_TestComponents_Valves_TestValveVaporizing",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(ModelicaTest.Fluid.TestComponents.Valves.TestValveVaporizing,fileNamePrefix="ModelicaTest_3_2_3_ModelicaTest_Fluid_TestComponents_Valves_TestValveVaporizing",fmuType="me",version="2.0",platforms={"static"}) Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.001179/0.001178, allocations: 95.34 kB / 15.68 MB, free: 488 kB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.001492/0.001492, allocations: 176.4 kB / 16.57 MB, free: 6.844 MB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/package.mo): time 1.543/1.543, allocations: 205.4 MB / 222.7 MB, free: 5.652 MB / 174.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaTest 3.2.3+maint.om/package.mo): time 0.4125/0.4125, allocations: 43.55 MB / 314.5 MB, free: 9.043 MB / 254.1 MB Notification: Modelica requested package Complex of version 3.2.3. Complex 4.0.0 is used instead which states that it is fully compatible without conversion script needed. Notification: Modelica requested package ModelicaServices of version 3.2.3. ModelicaServices 4.0.0 is used instead which states that it is fully compatible without conversion script needed. Notification: Performance of FrontEnd - loaded program: time 0.000523/0.0005231, allocations: 14.97 kB / 384 MB, free: 8.168 MB / 318.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.1335/0.1341, allocations: 58.86 MB / 442.9 MB, free: 13.19 MB / 382.1 MB Notification: Performance of NFInst.instantiate(ModelicaTest.Fluid.TestComponents.Valves.TestValveVaporizing): time 0.2508/0.3849, allocations: 24.24 MB / 467.1 MB, free: 36.02 MB / 382.1 MB Notification: Performance of NFInst.instExpressions: time 0.01721/0.4022, allocations: 14.78 MB / 481.9 MB, free: 28.05 MB / 382.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 0.0007038/0.403, allocations: 14.34 kB / 481.9 MB, free: 28.04 MB / 382.1 MB Notification: Performance of NFTyping.typeComponents: time 0.0009056/0.4039, allocations: 261 kB / 482.1 MB, free: 27.9 MB / 382.1 MB Notification: Performance of NFTyping.typeBindings: time 0.008681/0.4126, allocations: 2.967 MB / 485.1 MB, free: 26.5 MB / 382.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.01281/0.4254, allocations: 3.099 MB / 488.2 MB, free: 24.94 MB / 382.1 MB Notification: Performance of NFFlatten.flatten: time 0.001444/0.4268, allocations: 0.6092 MB / 488.8 MB, free: 24.62 MB / 382.1 MB Notification: Performance of NFFlatten.resolveConnections: time 0.0004887/0.4273, allocations: 231.3 kB / 489 MB, free: 24.55 MB / 382.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0009444/0.4283, allocations: 440.6 kB / 489.5 MB, free: 24.34 MB / 382.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0003375/0.4286, allocations: 234.2 kB / 489.7 MB, free: 24.24 MB / 382.1 MB Notification: Performance of NFPackage.collectConstants: time 4.484e-05/0.4287, allocations: 18.5 kB / 489.7 MB, free: 24.24 MB / 382.1 MB Notification: Performance of NFFlatten.collectFunctions: time 0.01675/0.4454, allocations: 7.166 MB / 496.9 MB, free: 22.64 MB / 382.1 MB Notification: Performance of NFScalarize.scalarize: time 0.0002046/0.4457, allocations: 83.83 kB / 497 MB, free: 22.61 MB / 382.1 MB Notification: Performance of NFVerifyModel.verify: time 0.0002666/0.446, allocations: 124 kB / 497.1 MB, free: 22.53 MB / 382.1 MB Notification: Performance of NFConvertDAE.convert: time 0.009919/0.4559, allocations: 3.068 MB / 0.4884 GB, free: 21.93 MB / 382.1 MB Notification: Performance of FrontEnd - DAE generated: time 2.785e-06/0.4559, allocations: 0 / 0.4884 GB, free: 21.93 MB / 382.1 MB Notification: Performance of FrontEnd: time 2.605e-06/0.4559, allocations: 1.562 kB / 0.4884 GB, free: 21.93 MB / 382.1 MB Notification: Performance of Transformations before backend: time 7.664e-06/0.456, allocations: 0 / 0.4884 GB, free: 21.93 MB / 382.1 MB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 84 * Number of variables: 84 Notification: Performance of Generate backend data structure: time 0.005763/0.4617, allocations: 1.262 MB / 0.4897 GB, free: 21.13 MB / 382.1 MB Notification: Performance of prepare preOptimizeDAE: time 4.665e-05/0.4618, allocations: 12.77 kB / 0.4897 GB, free: 21.12 MB / 382.1 MB Notification: Performance of preOpt introduceOutputAliases (simulation): time 9.223e-05/0.4619, allocations: 74.91 kB / 0.4898 GB, free: 21.06 MB / 382.1 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.001826/0.4637, allocations: 242.7 kB / 0.49 GB, free: 21.02 MB / 382.1 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0005322/0.4643, allocations: 379 kB / 0.4903 GB, free: 20.72 MB / 382.1 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 4.348e-05/0.4643, allocations: 28.16 kB / 0.4904 GB, free: 20.71 MB / 382.1 MB Notification: Performance of preOpt expandDerOperator (simulation): time 5.312e-05/0.4644, allocations: 33.56 kB / 0.4904 GB, free: 20.7 MB / 382.1 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.001832/0.4662, allocations: 0.6807 MB / 0.4911 GB, free: 20.4 MB / 382.1 MB Notification: Performance of preOpt findStateOrder (simulation): time 1.571e-05/0.4662, allocations: 3.062 kB / 0.4911 GB, free: 20.4 MB / 382.1 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 4.437e-05/0.4663, allocations: 16.69 kB / 0.4911 GB, free: 20.39 MB / 382.1 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 1.473e-05/0.4663, allocations: 12.75 kB / 0.4911 GB, free: 20.39 MB / 382.1 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.002006/0.4683, allocations: 0.6574 MB / 0.4917 GB, free: 20.24 MB / 382.1 MB Warning: The model contains alias variables with redundant start and/or conflicting nominal values. It is recommended to resolve the conflicts, because otherwise the system could be hard to solve. To print the conflicting alias sets and the chosen candidates please use -d=aliasConflicts. Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.002957/0.4713, allocations: 2.847 MB / 0.4945 GB, free: 17.86 MB / 382.1 MB Notification: Performance of preOpt comSubExp (simulation): time 0.00173/0.473, allocations: 0.5327 MB / 0.495 GB, free: 17.72 MB / 382.1 MB Notification: Performance of preOpt evalFunc (simulation): time 0.04772/0.5208, allocations: 24.54 MB / 0.519 GB, free: 14.33 MB / 398.1 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 4.926e-05/0.5209, allocations: 34.5 kB / 0.519 GB, free: 14.29 MB / 398.1 MB Notification: Performance of pre-optimization done (n=27): time 4.989e-06/0.5209, allocations: 5.906 kB / 0.519 GB, free: 14.29 MB / 398.1 MB Notification: Performance of matching and sorting (n=27): time 0.003398/0.5243, allocations: 0.894 MB / 0.5199 GB, free: 13.87 MB / 398.1 MB Notification: Performance of inlineWhenForInitialization (initialization): time 7.067e-05/0.5244, allocations: 106.9 kB / 0.52 GB, free: 13.75 MB / 398.1 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0005341/0.5249, allocations: 379.2 kB / 0.5204 GB, free: 13.5 MB / 398.1 MB Notification: Performance of collectPreVariables (initialization): time 4.445e-05/0.525, allocations: 31.33 kB / 0.5204 GB, free: 13.47 MB / 398.1 MB Notification: Performance of collectInitialEqns (initialization): time 0.000176/0.5252, allocations: 231.2 kB / 0.5206 GB, free: 13.26 MB / 398.1 MB Notification: Performance of collectInitialBindings (initialization): time 8.879e-05/0.5253, allocations: 94.16 kB / 0.5207 GB, free: 13.18 MB / 398.1 MB Notification: Performance of simplifyInitialFunctions (initialization): time 2.24e-05/0.5253, allocations: 10.78 kB / 0.5207 GB, free: 13.17 MB / 398.1 MB Notification: Performance of setup shared object (initialization): time 0.0001537/0.5254, allocations: 345.9 kB / 0.5211 GB, free: 12.83 MB / 398.1 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0005686/0.526, allocations: 178.5 kB / 0.5212 GB, free: 12.7 MB / 398.1 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0006305/0.5267, allocations: 293.1 kB / 0.5215 GB, free: 12.38 MB / 398.1 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.0005857/0.5273, allocations: 197 kB / 0.5217 GB, free: 12.18 MB / 398.1 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 3.788e-06/0.5273, allocations: 0 / 0.5217 GB, free: 12.18 MB / 398.1 MB Notification: Performance of matching and sorting (n=39) (initialization): time 0.001386/0.5287, allocations: 0.5172 MB / 0.5222 GB, free: 11.66 MB / 398.1 MB Notification: Performance of prepare postOptimizeDAE: time 0.0004683/0.5291, allocations: 1.043 MB / 0.5232 GB, free: 10.54 MB / 398.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 8.455e-06/0.5292, allocations: 4 kB / 0.5232 GB, free: 10.53 MB / 398.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 1.831e-05/0.5292, allocations: 8 kB / 0.5232 GB, free: 10.52 MB / 398.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0004964/0.5297, allocations: 111.9 kB / 0.5233 GB, free: 10.41 MB / 398.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 1.268e-05/0.5297, allocations: 7.984 kB / 0.5233 GB, free: 10.41 MB / 398.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0005318/0.5303, allocations: 83.55 kB / 0.5234 GB, free: 10.32 MB / 398.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 4.183e-05/0.5303, allocations: 27.92 kB / 0.5235 GB, free: 10.3 MB / 398.1 MB Notification: Performance of prepare postOptimizeDAE: time 8.195e-06/0.5303, allocations: 4 kB / 0.5235 GB, free: 10.29 MB / 398.1 MB Notification: Performance of postOpt replaceHomotopyWithSimplified (initialization): time 0.001243/0.5316, allocations: 451.5 kB / 0.5239 GB, free: 9.852 MB / 398.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 4.438e-06/0.5316, allocations: 4 kB / 0.5239 GB, free: 9.848 MB / 398.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 7.755e-06/0.5316, allocations: 4.281 kB / 0.5239 GB, free: 9.844 MB / 398.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0004466/0.5321, allocations: 119.6 kB / 0.524 GB, free: 9.73 MB / 398.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 6.602e-06/0.5321, allocations: 4 kB / 0.524 GB, free: 9.727 MB / 398.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.000435/0.5325, allocations: 79.64 kB / 0.5241 GB, free: 9.648 MB / 398.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 3.381e-05/0.5326, allocations: 19.98 kB / 0.5241 GB, free: 9.629 MB / 398.1 MB Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 12 * Number of states: 0 () * Number of discrete variables: 4 (SourceP1.medium.phase,SinkP1.medium.phase,V1.state_b.phase,V1.state_a.phase) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (39): * Single equations (assignments): 39 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (linear and non-linear blocks): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of prepare postOptimizeDAE: time 0.0002908/0.5328, allocations: 245 kB / 0.5243 GB, free: 9.379 MB / 398.1 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 7.939e-05/0.5329, allocations: 39.53 kB / 0.5244 GB, free: 9.34 MB / 398.1 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.002886/0.5358, allocations: 1.994 MB / 0.5263 GB, free: 7.34 MB / 398.1 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 3.268e-05/0.5359, allocations: 39.83 kB / 0.5264 GB, free: 7.301 MB / 398.1 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 6.132e-06/0.5359, allocations: 4 kB / 0.5264 GB, free: 7.297 MB / 398.1 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 7.784e-06/0.5359, allocations: 4 kB / 0.5264 GB, free: 7.293 MB / 398.1 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.001119/0.537, allocations: 1.04 MB / 0.5274 GB, free: 6.203 MB / 398.1 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 5.36e-06/0.5371, allocations: 0 / 0.5274 GB, free: 6.203 MB / 398.1 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0004214/0.5375, allocations: 103.9 kB / 0.5275 GB, free: 6.102 MB / 398.1 MB Notification: Performance of postOpt tearingSystem (simulation): time 4.278e-06/0.5375, allocations: 0 / 0.5275 GB, free: 6.102 MB / 398.1 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 2.267e-05/0.5375, allocations: 8 kB / 0.5275 GB, free: 6.094 MB / 398.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 5.08e-06/0.5375, allocations: 4 kB / 0.5275 GB, free: 6.09 MB / 398.1 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 3.436e-06/0.5375, allocations: 3.953 kB / 0.5275 GB, free: 6.086 MB / 398.1 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.001735/0.5393, allocations: 1.162 MB / 0.5286 GB, free: 4.906 MB / 398.1 MB Notification: Performance of postOpt removeConstants (simulation): time 0.0002914/0.5396, allocations: 263.4 kB / 0.5289 GB, free: 4.629 MB / 398.1 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 6.963e-05/0.5397, allocations: 11.12 kB / 0.5289 GB, free: 4.621 MB / 398.1 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0004214/0.5401, allocations: 63.78 kB / 0.529 GB, free: 4.559 MB / 398.1 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 8.481e-05/0.5402, allocations: 31.95 kB / 0.529 GB, free: 4.527 MB / 398.1 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 2.789e-05/0.5402, allocations: 19.95 kB / 0.529 GB, free: 4.508 MB / 398.1 MB Notification: Performance of sorting global known variables: time 0.0004365/0.5407, allocations: 374.8 kB / 0.5294 GB, free: 4.141 MB / 398.1 MB Notification: Performance of sort global known variables: time 1.7e-07/0.5407, allocations: 0 / 0.5294 GB, free: 4.141 MB / 398.1 MB Notification: Performance of remove unused functions: time 0.005644/0.5463, allocations: 1.132 MB / 0.5305 GB, free: 3.008 MB / 398.1 MB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 1 * Number of states: 0 () * Number of discrete variables: 18 ($cse1.phase,$cse1.region,$cse2.phase,$cse2.region,$cse4.phase,$cse4.region,$cse5.phase,$cse5.region,$cse6.region3boundary,$cse7.region3boundary,$cse8.phase,$cse8.region,$cse9.phase,$cse9.region,$cse13.phase,$cse13.region,SourceP1.medium.phase,SinkP1.medium.phase) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for simulation (38): * Single equations (assignments): 29 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 9 * When equations: 0 * If-equations: 0 * Equation systems (linear and non-linear blocks): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of Backend phase and start with SimCode phase: time 0.01132/0.5577, allocations: 2.817 MB / 0.5332 GB, free: 176 kB / 398.1 MB Notification: Performance of simCode: created initialization part: time 0.002511/0.5602, allocations: 0.921 MB / 0.5341 GB, free: 15.25 MB / 414.1 MB Notification: Performance of simCode: created event and clocks part: time 4.208e-06/0.5602, allocations: 0 / 0.5341 GB, free: 15.25 MB / 414.1 MB Notification: Performance of simCode: created simulation system equations: time 0.0008463/0.5611, allocations: 0.5523 MB / 0.5347 GB, free: 14.7 MB / 414.1 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.001316/0.5624, allocations: 218.8 kB / 0.5349 GB, free: 14.48 MB / 414.1 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.01022/0.5726, allocations: 5.642 MB / 0.5404 GB, free: 8.754 MB / 414.1 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0005239/0.5732, allocations: 0.9992 MB / 0.5414 GB, free: 7.727 MB / 414.1 MB Notification: Performance of simCode: alias equations: time 0.0009533/0.5742, allocations: 0.5432 MB / 0.5419 GB, free: 7.188 MB / 414.1 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0003505/0.5745, allocations: 271.3 kB / 0.5421 GB, free: 6.922 MB / 414.1 MB Notification: Performance of SimCode: time 1.102e-06/0.5745, allocations: 0 / 0.5421 GB, free: 6.922 MB / 414.1 MB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.08046/0.655, allocations: 48.3 MB / 0.5893 GB, free: 6.633 MB / 462.1 MB Notification: Performance of buildModelFMU: configured platform static using cached values: time 0.0001852/0.6552, allocations: 237.4 kB / 0.5895 GB, free: 6.387 MB / 462.1 MB Notification: Performance of buildModelFMU: Generate platform static: time 4.168/4.823, allocations: 4.062 kB / 0.5895 GB, free: 6.383 MB / 462.1 MB (rm -f ModelicaTest_3.2.3_ModelicaTest.Fluid.TestComponents.Valves.TestValveVaporizing.pipe ; mkfifo ModelicaTest_3.2.3_ModelicaTest.Fluid.TestComponents.Valves.TestValveVaporizing.pipe ; head -c 1048576 < ModelicaTest_3.2.3_ModelicaTest.Fluid.TestComponents.Valves.TestValveVaporizing.pipe >> ../files/ModelicaTest_3.2.3_ModelicaTest.Fluid.TestComponents.Valves.TestValveVaporizing.sim & /home/hudson/saved_omc/OMSimulator/install/linux/bin/OMSimulator -r=ModelicaTest_3.2.3_ModelicaTest.Fluid.TestComponents.Valves.TestValveVaporizing_res.mat --tempDir=temp_ModelicaTest_3_2_3_ModelicaTest_Fluid_TestComponents_Valves_TestValveVaporizing_fmu --startTime=0 --stopTime=1.01 --timeout=50 --tolerance=1e-06 ModelicaTest_3_2_3_ModelicaTest_Fluid_TestComponents_Valves_TestValveVaporizing.fmu > ModelicaTest_3.2.3_ModelicaTest.Fluid.TestComponents.Valves.TestValveVaporizing.pipe 2>&1) Environment - environmentSimulation: TODO: How the !@#!# did the simulation report success but simulation result ModelicaTest_3.2.3_ModelicaTest.Fluid.TestComponents.Valves.TestValveVaporizing_res.mat does not exist to compare? outputFormat=mat