Overunity.com Archives is Temporarily on Read Mode Only!



Free Energy will change the World - Free Energy will stop Climate Change - Free Energy will give us hope
and we will not surrender until free energy will be enabled all over the world, to power planes, cars, ships and trains.
Free energy will help the poor to become independent of needing expensive fuels.
So all in all Free energy will bring far more peace to the world than any other invention has already brought to the world.
Those beautiful words were written by Stefan Hartmann/Owner/Admin at overunity.com
Unfortunately now, Stefan Hartmann is very ill and He needs our help
Stefan wanted that I have all these massive data to get it back online
even being as ill as Stefan is, he transferred all databases and folders
that without his help, this Forum Archives would have never been published here
so, please, as the Webmaster and Creator of this Forum, I am asking that you help him
by making a donation on the Paypal Button above
Thanks to ALL for your help!!


FEMM simulation showing COP 3 and 7

Started by broli, February 01, 2011, 06:12:48 PM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

broli

I attached the sim and script. The scale is in mm, the script is set to a distance of 50mm, which you can adjust. Results are stored in the text file that is created.

Low-Q

Quote from: broli on February 14, 2011, 04:08:30 AM
I attached the sim and script. The scale is in mm, the script is set to a distance of 50mm, which you can adjust. Results are stored in the text file that is created.
This is GREAT! Thanks for your help :) :)

Vidar

Low-Q

Do you know where to modify to move a group sideways?

Here is the original script:
mydir="./"
outforcefile = mydir .. "ForceResults.txt"
open(mydir .. "Forcetest.fem")

mi_saveas(mydir .. "temp.fem") --make a temp file for the processing

-- the step size
increment = 1

-- determines the total distance to move up
distance = 50

-- calculates the amount of steps
steps = distance/increment

-- this part empties an already exsting file.
handle = openfile(outforcefile,"w")
write(handle, "")
closefile(handle)
   
   -- The main loop
   for n=0,steps do
      mi_clearselected()
      mi_selectgroup(1) --select the TT shape
      mi_movetranslate(0, increment) --move up

      mi_analyze()
      mi_loadsolution()
      mo_groupselectblock(1)
      
      forceY = mo_blockintegral(19)
      position = n
      
      handle = openfile(outforcefile,"a")
      write(handle, position, "\t", forceY, "\n")
      closefile(handle)
   end

        mi_clearselected()
        mi_selectgroup(1) --select the TT shape

Vidar

broli

Depends when you want to move it. If it's after you moved the TT's up then just copy and paste the entire for loop so you have two for loops. Then adjust the content of it appropriately. I can do it quickly if you give me the needed info.

http://pastebin.com/tpB4xdSG

Low-Q

Quote from: broli on February 14, 2011, 07:42:55 AM
Depends when you want to move it. If it's after you moved the TT's up then just copy and paste the entire for loop so you have two for loops. Then adjust the content of it appropriately. I can do it quickly if you give me the needed info.
Basicly I want group 1 (not necesserely the TT shape) to move to the right 50mm with 1mm steps. Well, basicly the same as the "upwards" script, but I want it to move to the right - not up.

Hope this information helps - I am too rookie with scripts to ask the right questions I guess :)

Vidar