Error while executing Hydrus 2D from Matlab

A discussion forum for users of the new HYDRUS 2D/3D. HYDRUS is a software package for simulating water, heat and solute movement in two- and three-dimensional variably saturated media. Happy Posting!
Post Reply
Posts: 15
Joined: Wed Dec 07, 2016 4:33 pm
Location: United Kingdom

Error while executing Hydrus 2D from Matlab

Post by LucileV » Thu Mar 29, 2018 8:25 am

hi all

I am executing Hydrus 2D from Matlab 2014a, on a windows 10, 64 bits, Intel Core i5-6500.

While most of the days of the simulation (executed individually) run ok, I get that error at some point:

Code: Select all

forrtl: severe (172): Program Exception - exception code = 0x2b4 (692)

Image              PC        Routine            Line        Source             
H2D_Calc.exe       00402338  Unknown               Unknown  Unknown
H2D_Calc.exe       00471D13  Unknown               Unknown  Unknown
H2D_Calc.exe       005096F3  Unknown               Unknown  Unknown
H2D_Calc.exe       004EB38F  Unknown               Unknown  Unknown
kernel32.dll       7669343D  Unknown               Unknown  Unknown
ntdll.dll          77969832  Unknown               Unknown  Unknown
ntdll.dll          77969805  Unknown               Unknown  Unknown
here are the input files I have: ... BEmsa?dl=0
you can also see in that folder in the Cum_Q.out file that the simulation stops after a couple of steps

The error is displayed in matlab only: it does not generate an error.msg file like when the solution does not converge.

The code I wrote to execute Hydrus 2D from Matlab is

Code: Select all

fileID_level01 = fopen('C:\Program Files (x86)\PC-Progress\HYDRUS 2.xx\LEVEL_01.dir','w');
            fprintf(fileID_level01,'%s \r\n',current_step_folder);
            % run hydrus
            cd('C:\Program Files (x86)\PC-Progress\HYDRUS 2.xx')
            [~,cmdout] = system('"C:\Program Files (x86)\PC-Progress\HYDRUS 2.xx\H2D_Calc.EXE"');
Anyone has any idea what is going on with this error message?

thanks a lot!


Edit: after a bit of fiddling around, it seems the problem comes from the head pressure at node 32 in Domain.dat. but I cannot figure out why (I tried changing the length of the string of the head pressure value.. doesn't work. but changing the values from node 32 does work.. mystery....)

Edit#2: I managed to run the simulation in Hydrus itself (not from Matlab), and I obtain the same result. The time step box actually disappears (even though I checked the box "press enter at the end" and it seems to me that the calculation quickly reaches conditions where the soil water content would be below theta_r.

Post Reply