%run hydraulic simulation and save in output file
calllib(‘epanet2′,’ENsolveH’);
%run quality simulations and save in output file (after ENsolveH)
calllib(‘epanet2′,’ENsolveQ’);
%for methods with pointers (returning values in arguments)
%setup a pointer with this command, see matlab ref for more information.
%the pointer reference is initiated with zero in this case
nnodes = libpointer(‘int32Ptr’,0);
%calls the method
calllib(‘epanet2′,’ENgetcount’, 0 , nnodes);
%returns the values stored in the pointer
get(nnodes,’Value’);
%write a formated text report in output file
calllib(‘epanet2′,’ENreport’);
%close toolkit
calllib(‘epanet2′, ‘ENclose’);
%unload library
unloadlibrary epanet2
———————————-
Hello
at what time after time 0 we can find the real chlorine quantity ?
how can I determine global balk coefficent ?
how can I show and run an inline chlorinator in EPANET ?
this means how I can modelling chlorine injection in a junction?
abot this programs:
My main quastion is to find new point to inject chlorine in order to solve the problem of dead points,I think the solution is to inject chlorine in some junctions
and this junctions should be fond via genetic algorithm method, there for I should link EPANET with MATLAB for this purpose.
this program work correctly !
but I dont know that’ outputs !!!
Plaese help me.
thanks in advance
I am unable to post any new threads in the EPANET forum. I cant find any link for posting new threads. Can you help.
Please try again.
%MATLAB CODE
%load epanet2.dll and .h
loadlibrary(‘epanet2′, ‘epanet2′)
%display library’s functions
libfunctions epanet2 -full
%open network file, set output file eg. net1.inp
calllib(‘epanet2′, ‘ENopen’, ‘net1.inp’,'net1.txt’,”);
%run hydraulic simulation and save in output file
calllib(‘epanet2′,’ENsolveH’);
%run quality simulations and save in output file (after ENsolveH)
calllib(‘epanet2′,’ENsolveQ’);
%for methods with pointers (returning values in arguments)
%setup a pointer with this command, see matlab ref for more information.
%the pointer reference is initiated with zero in this case
nnodes = libpointer(‘int32Ptr’,0);
%calls the method
calllib(‘epanet2′,’ENgetcount’, 0 , nnodes);
%returns the values stored in the pointer
get(nnodes,’Value’);
%write a formated text report in output file
calllib(‘epanet2′,’ENreport’);
%close toolkit
calllib(‘epanet2′, ‘ENclose’);
%unload library
unloadlibrary epanet2
———————————-
Hello
at what time after time 0 we can find the real chlorine quantity ?
how can I determine global balk coefficent ?
how can I show and run an inline chlorinator in EPANET ?
this means how I can modelling chlorine injection in a junction?
abot this programs:
My main quastion is to find new point to inject chlorine in order to solve the problem of dead points,I think the solution is to inject chlorine in some junctions
and this junctions should be fond via genetic algorithm method, there for I should link EPANET with MATLAB for this purpose.
this program work correctly !
but I dont know that’ outputs !!!
Plaese help me.
thanks in advance