Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Error about Turbine Leaving the Domain #39

Open
xiaomi4356 opened this issue Feb 10, 2025 · 5 comments
Open

Error about Turbine Leaving the Domain #39

xiaomi4356 opened this issue Feb 10, 2025 · 5 comments
Labels
question Further information is requested

Comments

@xiaomi4356
Copy link

Hello,

I'm encountering an error during my simulation, as shown below:

Image

I referred to the guide at FAST.Farm Model Guidance, and the section 4.18.6.6. Commonly Encountered Errors mentions that this error might be caused by an incorrect setting of the high-resolution domain.

However, my high-resolution domain is configured as follows:

X: [-76, 74]
Y: [-76, 74]
Z: [15, 165]
I have also followed the guidelines in 4.18.6.4.1.2. High-Resolution Domain. Could someone help me understand why this error is occurring?

Image

The parameter of my turbine is: the diameter of rotor D=125m, hub height=90m
Thank you in advance for your assistance!

@jjonkman jjonkman added the question Further information is requested label Feb 10, 2025
@jjonkman
Copy link
Collaborator

Dear @xiaomi4356,

The error is reporting that an aerodynamic analysis node is located at Z=9.9945 m, but your high-resolution domain starts at 15 m. All aerodynamic analysis must remain within the high-resolution domain for the entire simulation, including all structural deflections. Given the low elevation of this node, I suspect this error arises from an aerodynamic analysis node in the tower (rather than a blade). To solve the issue, either start the high-resolution domain lower or raise the lowest aerodynamic analysis node on the tower.

Are you using the OpenFAST Toolbox to set up the FAST.Farm model? If not, we'd recommend that.

Best regards,

@xiaomi4356
Copy link
Author

xiaomi4356 commented Feb 11, 2025

@jjonkman Thanks for your help!

I initially tried using the OpenFAST Toolbox, but since I want to perform turbine wake analysis, I need to explicitly define a clear low-resolution domain. However, when I looked at the provided Python example, I didn't find any settings for specifying the extent of the low-resolution domain.

Image

Could you please provide an example that demonstrates how to set the exact extent of the low-resolution domain using the OpenFAST Toolbox? It seems that I must instead adjust the parameters directly in the fstf file.

Another question relates to the tower points defined in my AeroDyn15.dat file—the lowest tower point is set at 10 m:

Image

If I set Z0_Low in the fstf file to 10.0, I encounter the following error:

Image

If I instead set Z0_Low to 15.0, a different error is reported:

Image

Any guidance on how to properly configure the low-resolution domain and resolve these errors would be greatly appreciated. Thank you!

@rthedin
Copy link
Collaborator

rthedin commented Feb 11, 2025

@xiaomi4356,

The toolbox helps you with the setup and does the writing of the fstf file based on your inputs. We recommend against manually changing parameters on the fstf file. The third example, Ex3_FFarmCompleteSetup.py shows a complete example on how to use it.

To your question, the low-resolution extent is calculated based on your farm layout and on the buffer layer you request. The overall size is determined internally. The extent is given here:

extent_low = [3, 8, 3, 3, 2] # extent in xmin, xmax, ymin, ymax, zmax, in D

If extent values are not passed to the toolbox, defaults are set:
# Set domain extents defaults if needed
default_extent_low = [3,6,3,3,2]
default_extent_high = 1.2 # total extent, half of that to each side.
if self.extent_low is None:
self.extent_low = default_extent_low
if self.extent_high is None:
self.extent_high = default_extent_high

If you change the starting location of the grid directly on the input file without changing the underlying turbulent boxes as inputs, the boxes will simply be shifted and you might run into a situation where the top of the turbines are not covered by the boxes.

@xiaomi4356
Copy link
Author

xiaomi4356 commented Feb 11, 2025

@jjonkman

Thank you very much for your prompt response. I am new to the field of wake research and have many questions, so I really appreciate your help.

Here is my code:

Image

I encountered the following error:

PS D:\ZXJ\Code> & D:/ZXJ/Software/annconda/envs/zxj_cuda/python.exe d:/ZXJ/Code/fastfarm/code4run/Ex3_FFarmCompleteSetup.py
Checking inputs... Done.
Setting rotor parameters... Done.
Creating auxiliary arrays for all conditions and cases...
Creating 1 conditions
Creating auxiliary arrays for all conditions and cases... Done.
Creating directory structure and copying files... Done.
[WARN] fastfarm\5MW_OC4Semi_WSt_WavesWN\NRELOffshrBsline5MW_OC4DeepCwindSemi_HydroDyn.dat: Line 225: number of data different from number of column names. ColumnNames: ['FillNumM', 'FillMList', 'FillFSLoc', 'FillDens']
!!!!!! WARNING !!!!!!!!!
The new method for computing all the high-box cases is not producing the same set of cases as the old algorithm.
This should only happen if you have complex sweeps that you modified manually after the code creates the initial arrays
Check the variable .allHighBoxCases_old to see the cases using the old algorithm
Check the variable .allHighBoxCases to see the cases using the new algorithm
You should check which xr.dataset has the correct, unique inflow_deg values. The correct array will only have unique values

The new method appears to be correct here! Trust but verify

!!!!!!!!!!!!!!!!!!!!!!!!

The y offset between the turbine ref frame and turbsim is -0.0
The x offset between the turbine ref frame and turbsim is -375.0

get domain parameter
Processing condition Cond00_v10.0_PL0.2_TI10
No controller given through libdiscon/DLL. Using VSContrl 5 from the template files.
Done processing condition Cond00_v10.0_PL0.2_TI10
Passed check: all files were copied successfully.
Organize file structure
File Cond00_v10.0_PL0.2_TI10\Case0_wdirp00\Seed_0\TurbSim\Low.bts already exists. Skipping symlink.
File Cond00_v10.0_PL0.2_TI10\Case0_wdirp00\Seed_1\TurbSim\Low.bts already exists. Skipping symlink.
Traceback (most recent call last):
File "d:\ZXJ\Code\fastfarm\code4run\Ex3_FFarmCompleteSetup.py", line 100, in
case.TS_high_setup()
File "d:\zxj\code\openfast_toolbox\openfast_toolbox\fastfarm\FASTFarmCaseCreation.py", line 1544, in TS_high_setup
self.TS_high_get_time_series()
File "d:\zxj\code\openfast_toolbox\openfast_toolbox\fastfarm\FASTFarmCaseCreation.py", line 1465, in TS_high_get_time_series
bts = TurbSimFile(os.path.join(condSeedPath, 'Low.bts'))
File "d:\zxj\code\openfast_toolbox\openfast_toolbox\io\turbsim_file.py", line 59, in init
self.read(filename, **kwargs)
File "d:\zxj\code\openfast_toolbox\openfast_toolbox\io\turbsim_file.py", line 71, in read
raise OSError(2,'File not found:',self.filename)
FileNotFoundError: [Errno 2] File not found:: 'fastfarm/case\Cond00_v10.0_PL0.2_TI10\Seed_0\Low.bts'
PS D:\ZXJ\Code>
However, when I click on the file Cond00_v10.0_PL0.2_TI10\Case0_wdirp00\Seed_0\TurbSim\Low.bts in my file explorer, I receive the message:

"Unable to open 'Low.bts'.
The file cannot be found, so the editor cannot be opened."

This suggests that the Low.bts file was not created correctly.

Could you please advise how I should modify the code to correctly generate the Low.bts file?

Thank you very much for your assistance.

@rthedin
Copy link
Collaborator

rthedin commented Feb 11, 2025

The bts files are output of TurbSim. You have selected to run FAST.Farm driven by TurbSim. Have you actually generated the TurbSim turbulence boxes? You need that step. These lines prepare and submit a SLURM-based job to run on an HPC system:

case.TS_low_slurm_prepare(slurm_TS_low)
#case.TS_low_slurm_submit()

If you are not running it on an HPC, you need to open the file and see what is being done. Ultimately, there is a TurbSim call for each seed:

srun -n1 -N1 --exclusive --nodelist=$currNode --mem-per-cpu=25000M $turbsimbin $dir/Low.inp > $dir/log.low.seed$seed.txt 2>&1 &

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants