|
[Sponsors] |
May 22, 2014, 18:11 |
Meshing in cluster
|
#1 |
New Member
Erik
Join Date: May 2014
Posts: 23
Rep Power: 11 |
How can I run the surface and volume mesher in the cluster instead of running it with GUI in PC?
|
|
May 23, 2014, 03:02 |
|
#2 |
Member
kris
Join Date: May 2014
Posts: 73
Rep Power: 11 |
you need to use batch mode. There are commands given in starccm+ user guide. it goes something like
installation directory/starccm+ -batch <macro file> <.sim file> You can record a macro to do the meshing. |
|
May 23, 2014, 12:06 |
|
#3 |
New Member
Erik
Join Date: May 2014
Posts: 23
Rep Power: 11 |
Do you mind to tell me how to generate the macro file?
|
|
May 23, 2014, 14:16 |
|
#4 |
Senior Member
Join Date: Nov 2010
Location: USA
Posts: 1,232
Rep Power: 24 |
I use the attached macro often to do this.
It will execute all part operations, surface mesh, and volume mesh, saving in between each step. Code:
package macro; import java.util.*; import star.common.*; import star.meshing.*; public class meshAllTheThings extends StarMacro { public void execute () { Simulation sim = getActiveSimulation(); String simPath = sim.getSessionPath(); sim.get(MeshOperationManager.class).executeAll(); sim.saveState(simPath); MeshPipelineController MPC = sim.get(MeshPipelineController.class); MPC.generateSurfaceMesh(); sim.saveState(simPath); MPC.generateVolumeMesh(); sim.saveState(simPath); } } |
|
May 24, 2014, 10:00 |
|
#5 |
New Member
Erik
Join Date: May 2014
Posts: 23
Rep Power: 11 |
im new to this, could you tell me how i include the macro in my job script for cluster?
|
|
May 25, 2014, 02:26 |
|
#6 |
Member
kris
Join Date: May 2014
Posts: 73
Rep Power: 11 |
save the above script as "meshAllTheThings.java". It is necessary that the java file name and the public class in the java file are the same.
Save that file in the same location as your sim file (not necessary, but easier). Then in your command prompt (in windows) or command line (in linux) go to the directory where the above files are saved and type the following. <cd-adapco installation directory>/starccm+ -batch <meshAllTheThings.java> <yourfile.sim> change the commands in <> according to your settings. Hope this helps. |
|
May 27, 2014, 14:34 |
|
#7 |
New Member
Erik
Join Date: May 2014
Posts: 23
Rep Power: 11 |
hi, i tried the job and add the .java file you suggested. However, it didnt run any mesh.
Here is how I call my starccm job starccm+ -rsh ssh -batch <meshAllTheThings.java> -np $NSLOTS -machinefile $TMPDIR/machines starccm.sim Could you point out the problem? =========================================== i figured it out and now it can run in the cluster. thank you so much for your help Kris |
|
May 27, 2014, 14:53 |
|
#8 |
New Member
Erik
Join Date: May 2014
Posts: 23
Rep Power: 11 |
Hi Kris,
If I already set up the physics and termination time of the simulation, will it run after it meshed the part? or I need to include another commands in the macro? Regards |
|
May 27, 2014, 18:22 |
|
#9 |
Senior Member
Join Date: Nov 2010
Location: USA
Posts: 1,232
Rep Power: 24 |
Your original question was how can you mesh on a cluster. The macro I put here does just that and only that. If you want it to also include running, you can record yourself hitting the run button and add that code on to the macro.
|
|
May 28, 2014, 10:33 |
|
#10 |
New Member
Erik
Join Date: May 2014
Posts: 23
Rep Power: 11 |
okay, thank you so much for your help !
|
|
May 29, 2014, 13:47 |
|
#11 |
New Member
Erik
Join Date: May 2014
Posts: 23
Rep Power: 11 |
I tried to run after the meshing but couldn't run it.
is there any macro command to run the CFD simulation. i tried to run like this but it doesnt work. starccm+ -rsh ssh -batch -np $NSLOTS -machinefile $TMPDIR/machines starccmfile.sim |
|
May 29, 2014, 18:22 |
|
#12 |
Senior Member
Join Date: Nov 2010
Location: USA
Posts: 1,232
Rep Power: 24 |
If you want help you need to be more descriptive.
"I tried to run after the meshing but couldn't run it. " Why? What happened? Was there an error? Did the machine catch fire? We have no idea, you have to tell us. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[ANSYS Meshing] Migrating from GAMBIT to ANSYS Meshing | David-CFD | ANSYS Meshing & Geometry | 1 | April 1, 2011 05:22 |
meshing on a cluster | jopawipr | STAR-CCM+ | 4 | February 13, 2010 05:06 |
Singularity of grid?Volume meshing vs face meshing | Ken | Main CFD Forum | 0 | September 4, 2003 11:09 |
Volume Meshing & Face Meshing? singularity of grid | ken | FLUENT | 0 | September 4, 2003 11:08 |