null

Message Boards

RE: Crash using "Attach to Land Boundary" in RGFGRID

HS
H Sandberg, modified 3 Months ago.

Crash using "Attach to Land Boundary" in RGFGRID

Youngling Posts: 3 Join Date: 3/12/19 Recent Posts

Hello!

I'm quite the beginner in Delft3D, and have encountered a problem when setting up grids in RGFGRID. Everytime I try to use the commando "Attach to Land Boundary", the program crashes, with no crash report whatsoever. More specifically, the crash occurs when I right-click to snap the spline to the boundary, after I've selected the spline by two points.

I've tried it with the grids supplied in the tutorials and my own grids, as well as using different computers. All with the same strange crash. Attached is one of the tutorial grids, which I've tried the operation on several times.

If anyone has any idea about this, please let me know!

Kind regards,

H Sandberg

Phil Shepperd, modified 3 Months ago.

RE: Crash using "Attach to Land Boundary" in RGFGRID

Padawan Posts: 44 Join Date: 12/4/18 Recent Posts

I can't reproduce your problem - works fine here.  So, as i can't solve it, I'll instead ask why you need to snap a spline to a land boundary? You could just place your spline nodes on the land boundary as you go?  The spline is just giving a rough shape for the grid to follow when you "change splines into grid", and if you need to you can then "line to landboundary" on the grid later on rather than the splines at this early stage.  (Just to be clear, the land boundary isn't doing anything other than serving as a visual guide). 

HS
H Sandberg, modified 3 Months ago.

RE: Crash using "Attach to Land Boundary" in RGFGRID

Youngling Posts: 3 Join Date: 3/12/19 Recent Posts

Thank you for the quick answer! 

You are correct in that the "Attach to Land Boundary" is not really neccesary for the model to work. As I said before, I'm a newbie regarding Delft3D. 

The problem is that similar crashes occur when I try to use "Grow grid from Splines" (with most tutorial grids as well as my own). 

One possible reason I've thought of may be the lack of Matlab on my computer. I've installed the Matlab Runtime, but I haven't got any Matlab license nor the main program installed. Could this affect the Delft3D performance?

 

 

Richard Measures, modified 3 Months ago.

RE: Crash using "Attach to Land Boundary" in RGFGRID

Jedi Knight Posts: 178 Join Date: 3/23/11 Recent Posts

Matlab (or the matlab runtime) is only needed for QuickPlot so that won't be causing problems with RGFGRID.

I've always found RGFGRID a little bit prone to unexpected crashes but generally it works ok if you give it good splines. For example, in your picture the 3 river parallel splines look good (smooth and parallel), but you only have 2 splines in the other direction, which will make it quite hard for RGF grid to interpolate a grid. I usually try and define enough splines across the river channel such that the aspect ratio of the resulting boxes is no more than 2 to 1, or at most maybe 5 to 1 for very skinny domains. Ideally you want to keep the aspect ratio consistent (assuming you want either square cells, or a constant aspect ratio in you final grid).

Another common problem I encounter is if I do not extend my splines far enough - the splines need to cross, and sometimes if I don't extend them far enough it causes problems (I think maybe RGFGRID tests for crossing points using straight lines between the nodes defining the splines, which means curved splines which only just cross may not if doing a calculation based on a straight-line assumption?). It doesn't look like you have this problem in the attached image but it is something to watch out for when you add more splines.

In summary: I would recommend adding quite a few cross-channel splines, which all extend well outside the line of river, to see if that helps.

Phil Shepperd, modified 3 Months ago.

RE: Crash using "Attach to Land Boundary" in RGFGRID

Padawan Posts: 44 Join Date: 12/4/18 Recent Posts

Richard's right, it's not a Matlab issue.  But, if you are still having problems once you've tried his suggestions then i wonder if it's an installation issue on your computer??  Try re-installing?  Sorry not to be more help!

HS
H Sandberg, modified 3 Months ago.

RE: Crash using "Attach to Land Boundary" in RGFGRID

Youngling Posts: 3 Join Date: 3/12/19 Recent Posts

Thank you both for the great advice!

I will keep it in mind when proceeding with RGFGRID and Delft3D. 

Regards,

H Sandberg