FastFieldSolvers Forum
FastFieldSolvers Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
 All Forums
 FastFieldSolvers
 FastHenry2
 Plane Current Visualization Text Files
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Roger

United Kingdom
12 Posts

Posted - Mar 09 2019 :  20:27:36  Show Profile  Reply with Quote
Hello Enrico,

Using the -d grids option and outputting text files (I don't have MatLab) it outputs files like Jreal1_1.mat etc..
Could you please explain how to interpret the contents of these files?

Thanks --- Roger

Roger

United Kingdom
12 Posts

Posted - Mar 14 2019 :  17:30:50  Show Profile  Reply with Quote
Hello Enrico,

What I'm trying to do is to find the power dissipation in a plane due to eddy currents from a nearby coil.

I wasn't planning on using non-uniform planes, so I didn't read the non-uniform plane memo, which I should have done before posting my original question in this thread. However now reading through that memo I see it describes the format of the Jreal1_1.mat type files. These aren't Matlab files so I can read them into Excel. Also that appears to describe the format of the Gridxxx.mat files as being different from that mentioned on page 33 of the FastHenry User Guide.

I found I can read the Gridxxx.mat MatLab files into MathCad. On page 29 of the non-uniform plane memo it looks like the file gives the current at nodes in the system though I think I either don't understand the result or I'm not reading the data into MathCad correctly.

However it seems the Jxxxx.mat files have essentially the same information and I can read those into excel or MathCad and the data seems to make sense. So it gives one line of data for each segment which gives the x,y,z position of one end of the segment and the x,y,z components of the current density in that segment. So knowing the length, cross-section, and resistivity of each segment I can compute the power dissipation.

The Jxx.mat file contains data for all segments in the system. So in order to automate the process of finding the power dissipation in various planes and parts of the system I need to be able to identify which segments belong to those different parts. Do you know if there is anyway of getting at the part of the system a given line in the file represents, or finding what the xyz position of each end of the segment specified in each line of the file is?

Best Regards
Roger

Go to Top of Page

Enrico

412 Posts

Posted - Mar 16 2019 :  11:11:38  Show Profile  Reply with Quote
Hi Roger,

are you going to use uniform conductive planes, or non-uniform conductive planes?

In general, if your goal is to have the current density in all segments you are interested in, and not only visualize it, you may actually need the Jreal/Jimag dumps. The Gridxxx files are generated to make it easy visualizing the 2D current flows over the conductive planes, so they actually express the information in the local conductive plane coordinate system.

However for tracing back from the Jreal/Jimag files to the original segments may be tricky, also because the files contain the actual current information per filament, not per segment.
The easiest way to achieve that is in the end to modify the source files to dump also a reference to the segment. The file is fillM.c, in the makegrids() function.

Best Regards,
Enrico


Go to Top of Page

Roger

United Kingdom
12 Posts

Posted - Mar 19 2019 :  18:59:17  Show Profile  Reply with Quote
Hello Enrico,

Thanks for your help.

I'll have a look at the .c file you mention, though at present I cannot compile the code.

I'm using uniform planes to keep the current density files simpler. The plane is of high resistivity material skin depth ~4.5mm at the operating frequency and the plane is 27mmx36mm so I can make the plane nodes say 1mm apart and still be OK with skin effect I think - to be tested.

As for the coils in the system, I think what's important in finding eddy losses in the plane and coupling coeffs in the system are the mutual inductances. So I found I can simplify a coil from N turns to 1 turn and also ignore filamentizing and still get the coupling coeffs reasonably correct.This greatly simplifies the current density files as well of course which is good. The downside is the coil resistance is possibly not correct even when scaled back to the original N turns though I can get the coil losses some other way.

I found that with a long segment say in this case for example 36.2mm long and 1.5x1.5mm cross-section it will automatically split it into 10 shorter segments. This makes it harder to determine the power loss in each sub-segment. The manual says the -i switch if set to 0 does not split the segment, and in the FastModel Run Menu -i is set to 0 by default. How can I stop it splitting these segments? Is this a good idea?

Regards --- Roger
Go to Top of Page

Roger

United Kingdom
12 Posts

Posted - Mar 20 2019 :  21:44:51  Show Profile  Reply with Quote
Hi Enrico,

Have you successfully used the Grid or J type files to visualize plane currents?

Best Regards --- Roger
Go to Top of Page

Roger

United Kingdom
12 Posts

Posted - Mar 23 2019 :  10:00:16  Show Profile  Reply with Quote
Hi Enrico,

I got it running giving what looks like correct results using the Jreal and Jimag files.

At first I used Jmag files. But it looked like the current directions were incorrect in some cases. I looked at the code you mentioned, on line 636 in fillM.c it computes the magnitude of the complex valued current, but that loses the direction of the current I think, but I'm not sure what lenvect[XX] returns. I assumed the magnitude of the current together with its direction along the segment would be reported ???

Regards --- Roger
Go to Top of Page

Enrico

412 Posts

Posted - Apr 05 2019 :  01:39:39  Show Profile  Reply with Quote
Hi Roger,

quote:
I looked at the code you mentioned, on line 636 in fillM.c it computes the magnitude of the complex valued current, but that loses the direction of the current I think, but I'm not sure what lenvect[XX] returns.


No, using the magnitude does not loses the direction of the current. The real and imaginary parts are about the current phasors, as the simulations are in the AC regime, so they will tell you the relative phase of the current (the phase shift) but always along the segment (or filament) direction.

lenvect[] has the three components XX, YY, ZZ and is the array of the current 3D vectors pointing along the segments (filaments). They are then normalized (made unitary) dividing by the segment length, and multiplied by the current density (current divided by segment area).

quote:
I found that with a long segment say in this case for example 36.2mm long and 1.5x1.5mm cross-section it will automatically split it into 10 shorter segments. This makes it harder to determine the power loss in each sub-segment. The manual says the -i switch if set to 0 does not split the segment, and in the FastModel Run Menu -i is set to 0 by default. How can I stop it splitting these segments? Is this a good idea?


For what regards the segments automatic partitioning, this is done by the multipole refine, to fit the segments within the cells that are used (spatially) for the expansion in series of multipoles. You can prevent the split using the -a option. But this is not a good idea, unless you also select no multipole with -m, but direct solution. Otherwise you impact the accuracy of the multipole expansions, as the error is not bounded (depending on how long your segment is).

Best Regards,
Enrico






Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
FastFieldSolvers Forum © 2018 FastFieldSolvers S.R.L. Go To Top Of Page
Powered By: Snitz Forums 2000 Version 3.4.06