Hello,
I need to solve the elliptic equation for alpha in k-wSST model and the method I follow and the errors produced are as follows.
1. Since a user defined field cannot be used to call the resalp.f90 subroutine, I have added a field for alpha in the fldvar.f90 file as it is done for ebrsm and blv2k.
2. I added the boundary conditions for alpha in clptur.f90.
3 Finally I call the subroutine in turbkw.f90.
When run, the code produces the error below:
---
Field "alpha"
does not have associated BC coefficients.
Call stack:
1: 0x7f270abd9053 <bft_error+0xae> (libsaturne.so.5)
2: 0x7f2709f42a9e <cs_f_field_bc_coeffs_ptr_by_id+0xf2> (libsaturne.so.5)
3: 0x7f270ab70fb7 <__field_MOD_field_get_coefa_s+0x42> (libsaturne.so.5)
4: 0x48b448 <clptur_+0x1e7a> (cs_solver)
5: 0x7f2709e8e110 <condli_+0x7c68> (libsaturne.so.5)
6: 0x7f270a0dd75f <tridim_+0x8eef> (libsaturne.so.5)
7: 0x7f2709e190a5 <caltri_+0x3afd> (libsaturne.so.5)
8: 0x7f2709ddb83a <cs_run+0x4b0> (libsaturne.so.5)
9: 0x7f2709ddbad7 <main+0x15b> (libsaturne.so.5)
10: 0x7f27040693d5 <__libc_start_main+0xf5> (libc.so.6)
11: 0x4650b9 <> (cs_solver)
End of stack
---
Tracking the error leads to the line 422 in the file clptur.f90, where the "BC coefficient for gradients" are called.
--- line 420 to 430
if (ial.gt.0) then
call field_get_coefa_s(ivarfl(ial), coefa_al)<---
call field_get_coefb_s(ivarfl(ial), coefb_al)
call field_get_coefaf_s(ivarfl(ial), coefaf_al)
call field_get_coefbf_s(ivarfl(ial), coefbf_al)
else
coefa_al => null()
coefb_al => null()
coefaf_al => null()
coefbf_al => null()
endif
---
My question is, Is there another subroutine I need to modify in order to successfully define the "BC coefficients"?
Thanks in advance for your help.
Puneeth
PS: The relevant edits in the src files (attached) are tagged as "PRMODS" for ease of searching.
(CS v5.1.6) Usage of resalp.f90 in turbulence models other than EBRSM or BLv2k
Forum rules
Please read the forum usage recommendations before posting.
Please read the forum usage recommendations before posting.
-
- Posts: 4152
- Joined: Mon Feb 20, 2012 3:25 pm
Re: (CS v5.1.6) Usage of resalp.f90 in turbulence models other than EBRSM or BLv2k
Hello,
If the field you added is a "variable" type field, I would expect it to have boundary condition arrays.
You may need to call "field_allocate_bc_coeffs" in tridim.f90.
I also recommend upgrading to a newer version, as 5.1 is an intermediate version and is not maintained anymore.
v5.0 will be maintained until May 2021, v6.0 until May 2023, etc.
There have been some additions to the k-w model in v6.0.
Best regards,
Yvan
If the field you added is a "variable" type field, I would expect it to have boundary condition arrays.
You may need to call "field_allocate_bc_coeffs" in tridim.f90.
I also recommend upgrading to a newer version, as 5.1 is an intermediate version and is not maintained anymore.
v5.0 will be maintained until May 2021, v6.0 until May 2023, etc.
There have been some additions to the k-w model in v6.0.
Best regards,
Yvan
Re: (CS v5.1.6) Usage of resalp.f90 in turbulence models other than EBRSM or BLv2k
Hello,
Thank you very much! I followed the subroutine "field_allocate_bc_coeffs" to fldtri.f90 and added a an additional field (nfld += 1 and ifvar(nfld) = ial) for the kwsst model and this works well.
Thanks for guiding me and your recommendations.
Puneeth
Thank you very much! I followed the subroutine "field_allocate_bc_coeffs" to fldtri.f90 and added a an additional field (nfld += 1 and ifvar(nfld) = ial) for the kwsst model and this works well.
Thanks for guiding me and your recommendations.
Puneeth