Qual2K for multiple tributaries

1,018 views
Skip to first unread message

Marcelo

unread,
Sep 10, 2012, 11:11:48 AM9/10/12
to qual2...@googlegroups.com
Hello group. Does anyone have a Qual2K sample file for multiple tributaries? Apparently I am not entering the topology correctly. The macro stops at:

        MsgBox "last reach should be a mainstem reach!", vbExclamation, _
            "QUAL2K Error: Reach " & topo(curElemID).RchID  'hua01

Appreciate your help,

Marcelo


Kyle Flynn

unread,
Sep 16, 2012, 12:13:00 PM9/16/12
to qual2...@googlegroups.com
Hi Marcelo -
 
If you still haven't figured this out please send me your .q2k input file at kyle....@tufts.edu.
 
Thanks,
 
Kyle
Message has been deleted
Message has been deleted

Kris Baker

unread,
Nov 25, 2013, 11:12:58 AM11/25/13
to qual2...@googlegroups.com
Hi Marcelo- Did you ever receive a response to this? I am having the same issue. There are no examples available online. Thanks, Kris

SWSFox

unread,
Nov 25, 2013, 5:01:01 PM11/25/13
to qual2...@googlegroups.com
Hi Kris,
 
I agree, the documentation for this is completely absent. Here is an example of the system that worked for me. Start from the upstream reach of your mainstem to create the reaches. When you reach a confluence ("junction"), the next reach will be your tributary headwater reach (#4 in the example below). The locations are your river mileage (in km). The 0 in the "Location downstream" column seems to signify to the code that the next reach will be on the mainstem (or, a level-up tributary for more complex systems). The headwaters than need to be specified in the Headwater tab -- enter the reach numbers there in the order of reach numbers (in the example, #1 and #4). Verify all numbers if you're still getting errors, I wasted a lot of time at the beginning because my headwater reach number was mistyped in the Headwater tab.
 
I had problems executing the code when I had more than one element specified for the "junction" reach (#7 in the example). I had also issues for reaches with dams, those required only one element in my case also.
 
Hope this works,
Alena
 
 
Example below: headwater reaches are in bold, tributary reaches are highligted in orange, the junction reach in green.
Stream Reach number Location upstream Location downstream
Mainstem 1 50 40
Mainstem 2 40 30
Mainstem 3 30 25
Tributary 1 4 35 20
Tributary 1 5 20 5
Tributary 1 6 5 0
Mainstem 7 25 15
Mainstem 8 15

0

SWSFox

unread,
Nov 25, 2013, 5:02:27 PM11/25/13
to qual2...@googlegroups.com
Example reposted, didn't notice the formatting got messed up.
 
Stream Reach number Location upstream Location downstream
Mainstem 1 50 40
Mainstem 2 40 30
Mainstem 3 30 25
Tributary 1 4 15 10
Tributary 1 5 10 5

Marianni Nogare

unread,
Oct 20, 2016, 5:35:20 PM10/20/16
to QUAL2K-user
Hello!

I created my reaches exactly like this last example, but it keeps warning me: "upstream location should equal downstream of previous reach". 

I have tributaries and they have their own upstream location (different from the main course), but I don't how to tell the model that. 

Any ideas on how to fix that? 

Thanks!

SWSFox

unread,
Oct 21, 2016, 5:15:43 PM10/21/16
to QUAL2K-user
Hi, can you post a table with your reach data so I can see what exactly you have there?

Marianni Nogare

unread,
Oct 24, 2016, 8:47:10 AM10/24/16
to QUAL2K-user
The warning appears for reach nº 46, the fourth section of my mainstem. 



  Reach Headwater Location
Reach Number Reach Upstream Downstream
Label     (km) (km)
Mainstem headwater 1 Yes 184.07 183.97
Emp 175278  2 183.97 177.97
3 177.97 177.77
4 177.77 171.47
5 171.47 167.07
6 167.07 161.07
7 161.07 156.07
8 156.07 151.07
9 151.07 140.07
10 140.07 134.07
11 134.07 125.14
APU-AP-08 12 Yes 50.87 50.77
13 50.77 45.87
14 45.87 40.87
15 40.87 36.06
16 36.06 30.87
17 30.87 12
18 12 5.87
19 5.87 3.87
20 3.87 0
APU-07 21 125.14 125.04
22 125.04 115.14
23 115.14 107.14
24 107.14 103.14
25 103.14 95.14
26 95.14 89.14
27 89.14 79.14
APU-AP-06 28 Yes 54.23 54.13
29 54.13 50.23
30 50.23 40.23
31 40.23 29.23
32 29.23 19.23
33 19.23 9.23
34 9.23 0
APU-AP-05 35 79.14 79.04
36 79.04 77.14
37 77.14 72.28
APU-AP-04 38 Yes 95.01 94.91
39 94.91 84.01
40 84.01 75.01
41 75.01 63.01
42 63.01 54.01
43 54.01 36.01
44 36.01 31.01
45 31.01 14.01
APU-AP-03 46 72.28 72.18
47 72.18 67.28
48 67.28 58.17
49 58.17 53.17
50 53.17 45.17
51 45.17 34.17
52 34.17 22.16
53 22.16 17.06
APU-AP-02a 54 Yes 75.55 75.45
55 75.45 65.55
56 65.55 56.77
APU-AP-02 57 56.77 56.67
58 56.67 46.77
59 46.77 30.77
60 30.77 18.77
61 18.77 6.77
62 6.77 0
APU-AP-01 63 17.06 16.96
64 16.96 9.06
65 9.06 0
 


SWSFox

unread,
Oct 25, 2016, 2:35:58 AM10/25/16
to QUAL2K-user
You need another reach before reach 45. The last tributary does not go to 0 river km. you need one or more reaches from 14.01 to 0. The 0 then signifies to the program that the following reach is back to mainstem (or a level up tributary).

Zhuo Chen

unread,
Nov 21, 2017, 9:49:45 PM11/21/17
to QUAL2K-user
Hi SWSFOx,

I had the same problem, when trying to enter a tributary, as following. I thought I did it correctly, but it keeps telling me that upstream location not matching the previous downstream location. 
Reach Headwater Reach Location
Number Reach length Upstream Downstream
    (km) (km) (km)
1 Yes 5.00 50.000 45.000
2   4.00 45.000 41.000
3   1.00 41.000 40.000
4   2.50 10.000 7.500
5   2.50 7.500 5.000
6   2.50 5.000 2.500
7   2.50 2.500 0.000
8   5.00 40.000 35.000
9   5.00 35.000 30.000
10   5.00 30.000 25.000
11   5.00 25.000 20.000
12   5.00 20.000 15.000
13   5.00 15.000 10.000
14   5.00 10.000 5.000
15   5.00 5.000 0.000

Hoàng Bùi Huy

unread,
Nov 28, 2017, 9:05:19 PM11/28/17
to QUAL2K-user
i think u did not add " yes" in the new tributary at reach 4

4 yes2.5010.0007.500

Zhuo Chen

unread,
Dec 17, 2017, 5:17:44 PM12/17/17
to QUAL2K-user
HI Hoàng Bùi Huy,

Thanks a lot for helping out!
But this still doesn't solve the issue. It gave me the same error message once I hit "run", and automatically remove the "yes" at reach 4. 

Hoàng Bùi Huy

unread,
Dec 25, 2017, 2:24:26 AM12/25/17
to QUAL2K-user
could u send me your q2k file?

Hoàng Bùi Huy

unread,
Dec 25, 2017, 2:26:29 AM12/25/17
to QUAL2K-user
do u add 1 more headwater for the reach 4 in the headwater worksheet?

DUYEN NGUYEN CHAU MY

unread,
Jun 14, 2023, 5:52:51 AM6/14/23
to QUAL2K-user
I have the same situation. I make sure that i entered "yes" in the second tributary. Can you help me?
1.jpg2.jpg
Reply all
Reply to author
Forward
0 new messages