Page 1 of 1

How to extract values of real MATC function

Posted: 17 Feb 2019, 06:14
by Duván
Hello,

I'm studying the .SIF file of a PMSM (permanent magnet synchronous machine), that is a motor of a fan. In the model there are 4 permanent magnets and each of them have a time-depending magnetization.

I want to extract the values of the Magnetization 1 and 2 in a .dat file, which are the x and y components of the magnetization (see the code below). I want to analize all the values for each value of variable time.

How can I do this?

Material 3
Name = "PM_right"
Relative Permeability = $ mu_PM
Magnetization 1 = Variable time, timestep size
Real MATC "H_PM*cos(w_m*(tx(0)-tx(1)))"
Magnetization 2 = Variable time, timestep size
Real MATC "H_PM*sin(w_m*(tx(0)-tx(1)))"
End


Thank you in advance.

Re: How to extract values of real MATC function

Posted: 17 Feb 2019, 12:11
by kevinarden
Look at Chapter 47 of the Elmer Models manual
Model 47
Saving scalar values to file
Module name: SaveData
Module subroutines: SaveScalars

Some of the tutorials use this.

I do the x-y plotting in Paraview, which will also export the xy plot data.

Re: How to extract values of real MATC function

Posted: 18 Feb 2019, 01:16
by Duván
Thanks a lot for the answer.