|
[Sponsors] |
[mesh manipulation] SplitMeshRegions deletes patches on stl file |
![]() |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
![]() |
![]() |
#1 |
Member
Owais Shabbir
Join Date: May 2019
Posts: 48
Rep Power: 7 ![]() |
Dear All,
I am trying to develop a chtmultiregionsimplefoam case and it consists of a battery and a casing in the fluid domain. After SnappyHexMesh in my constant/polyMesh/boundary file I have following boundaries: inletAfter I performed splitMeshRegions -cellZonesOnly -overwrite I am only left with inletand in the <region>/constant/polyMesh/boundary for lets say batteries, I have: batteries_to_casingI cant find batteries or casing boundary patch anymore which unables me to set a boundary condition on either battery or casing. I have tried topoSet to collect the faceZones and use createPatch for it but it doesn't work because createPatch is for external faces only. Is there a way (if possible a simpler one) to solve this problem? Any help will be appreciated Thanks OS |
|
![]() |
![]() |
![]() |
![]() |
#2 |
Senior Member
Yann
Join Date: Apr 2012
Location: France
Posts: 1,169
Rep Power: 27 ![]() |
Hello Owais,
When you run splitMeshRegions, coupled patches are created at the interfaces between the regions. In your case, it means your batteries and casing patches should be renamed according to the regions names sharing this interface. You said in batteries/constant/polyMesh/boundary, you have
You may have a constant/polyMesh directory left, but it is useless since you are going to work only with the regions and each one has its own directory containing its own mesh (regionName/constant/polyMesh) Cheers, Yann Last edited by Yann; August 12, 2019 at 03:24. Reason: clarification |
|
![]() |
![]() |
![]() |
![]() |
#3 |
Member
Owais Shabbir
Join Date: May 2019
Posts: 48
Rep Power: 7 ![]() |
Hi Yann,
you are quite right, I have just moved to chtMultiRegion and therefore, I was unaware of the dictionary fvOptions which is utilised to introduce heat in regions. Thanks Owais |
|
![]() |
![]() |
![]() |
![]() |
#4 |
Senior Member
Yann
Join Date: Apr 2012
Location: France
Posts: 1,169
Rep Power: 27 ![]() |
Hi Owais,
You're welcome, switching to chtMultRegion can be a bit confusing since every region has its own setup. Just to be clear: fvOptions is not related to chtMultiRegion. You can use it with any solver and it has a lot of different model to add source terms / constraints in your simulation such as porosity, heat exchanger, joule heating, rotor disk models, quantity source, limiting temperature or velocity etc... It is indeed a great way to add a heat source in a case. Yann |
|
![]() |
![]() |
![]() |
![]() |
#5 |
Member
Owais Shabbir
Join Date: May 2019
Posts: 48
Rep Power: 7 ![]() |
Hi Yann,
I noticed that there were multiple regions (region0,region1...,region31) after I ran the command Code:
checkMesh -region batteries Code:
<<Writing region information to "0/cellToRegion" <<Writing region 0 with 56586 cells to cellSet region0 <<Writing region 1 with 58973 cells to cellSet region1 <<Writing region 2 with 86854 cells to cellSet region2 <<Writing region 3 with 85248 cells to cellSet region3 <<Writing region 4 with 105712 cells to cellSet region4 <<Writing region 5 with 116805 cells to cellSet region5 <<Writing region 6 with 77349 cells to cellSet region6 <<Writing region 7 with 95958 cells to cellSet region7 <<Writing region 8 with 115034 cells to cellSet region8 <<Writing region 9 with 78722 cells to cellSet region9 <<Writing region 10 with 92825 cells to cellSet region10 <<Writing region 11 with 117140 cells to cellSet region11 <<Writing region 12 with 85406 cells to cellSet region12 <<Writing region 13 with 98944 cells to cellSet region13 <<Writing region 14 with 116975 cells to cellSet region14 <<Writing region 15 with 74450 cells to cellSet region15 <<Writing region 16 with 77726 cells to cellSet region16 <<Writing region 17 with 102233 cells to cellSet region17 <<Writing region 18 with 85248 cells to cellSet region18 <<Writing region 19 with 105712 cells to cellSet region19 <<Writing region 20 with 119880 cells to cellSet region20 <<Writing region 21 with 77349 cells to cellSet region21 <<Writing region 22 with 95958 cells to cellSet region22 <<Writing region 23 with 120105 cells to cellSet region23 <<Writing region 24 with 78575 cells to cellSet region24 <<Writing region 25 with 92608 cells to cellSet region25 <<Writing region 26 with 114226 cells to cellSet region26 <<Writing region 27 with 85469 cells to cellSet region27 <<Writing region 28 with 98685 cells to cellSet region28 <<Writing region 29 with 76841 cells to cellSet region29 <<Writing region 30 with 76376 cells to cellSet region30 <<Writing region 31 with 78162 cells to cellSet region31 I copied the fvOptions from coolingSphere tutorial since it talks about the fixedPower Now each of the yellow box is dissipating heat of power 1.25W. Code:
fixedPower { type scalarSemiImplicitSource; active yes; selectionMode all; volumeMode absolute; power 40; // Set power (W) injectionRateSuSp { e ($power 0); h ($power 0); } } 2) should the power be 1.25W instead of 40? 3) what is e and h? 4) I am running the simulation with the 40W but simulation is taking extremely long for the Temperature to change. Each step drops the T_batteries_max by 2e-5 C. Is there a way to speed it up? |
|
![]() |
![]() |
![]() |
![]() |
#6 |
Senior Member
Yann
Join Date: Apr 2012
Location: France
Posts: 1,169
Rep Power: 27 ![]() |
Hi Owais,
Well it depends on what you want to achieve with this simulation. If you're interested in the whole battery pack as one region, I don't think it's a problem if the batteries are not connected. If I understand it right, in your fvOptions your specified a 40W power for the batteries region. If you have 32 batteries in your pack, you are going to have 40/32=1.25W for each battery, this is exactly what you define in the fvOptions file. If you want to have 40W for each battery, you have to set 1280W for the whole pack. Another way of dealing with that is to use the specific volumeMode instead of absolute in order to define a power density (W/m3) Have a look at the semiImplicitSource.H header for details. (I don't know which version you're using, I've linked the OpenFoam-7 one) e is the internal energy and h is the enthalpy. Which one is solved depends on your region setup. Have a look at the thermophysicalProperties documentation. In your example, the fvOptions file is written in order to work with both internal energy and enthalpy. Lets say your case is set up to work with internal energy, you could just write : Code:
fixedPower { type scalarSemiImplicitSource; active yes; selectionMode all; volumeMode absolute; injectionRateSuSp { e (40 0); } } |
|
![]() |
![]() |
![]() |
Tags |
chtmultiregionsimplefoam, splitmeshregions, toposet |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
[swak4Foam] Installation Problem with OF 6 version | Aurel | OpenFOAM Community Contributions | 14 | November 18, 2020 16:18 |
OpenFoam "Permission denied" and "command not found" problems. | iyidaniel@yahoo.co.uk | OpenFOAM Running, Solving & CFD | 11 | January 2, 2018 06:47 |
[swak4Foam] swak4foam building problem | GGerber | OpenFOAM Community Contributions | 54 | April 24, 2015 16:02 |
[swak4Foam] Error bulding swak4Foam | sfigato | OpenFOAM Community Contributions | 18 | August 22, 2013 12:41 |
"parabolicVelocity" in OpenFoam 2.1.0 ? | sawyer86 | OpenFOAM Running, Solving & CFD | 21 | February 7, 2012 11:44 |