User Forum of Software BASEMENT

BASEMENT
Basic Simulation Environment for computation of environmental flow and natural hazard simulation
Laboratory of Hydraulics, Hydrology and Glaciology (VAW)
ETH Zurich
Basement_Logo

You are not logged in.

#1 2020-07-15 15:29:49

chri_and
User
Registered: 2017-07-27
Posts: 34

Invalid vector subscript

Hi there

I have been unsuccessful to get a simulation to run on the v3.0.2. I get the following error durimng the configuration of the model.json

Console Output

BASEMENT v3.0.2
BASEplane setup binary
v3.0.2
Copyright: (C) 2020 ETH Zurich / Laboratory of hydraulics, hydrology and glaciology (VAW)

 -> composing the model from the input file
 -> found aggregate <hydraulics_aggr>
 -> found aggregate <hyd_boundary_aggr>
 -> found aggregate <hyd_friction_aggr>
 -> running on 1 threads
 -> generating the content from the model components ...
 -> model component <EdgesAll/FluxesHy> is internal -> no content defined!
 -> model component <CellsAll/IsWetted> is internal -> no content defined!
 -> model component <CellsAll/ChezyCoe> is internal -> no content defined!
 -> model component <NodeStrg/StateVar> is internal -> no content defined!
 -> model component <EdModDat/LocalDat> is internal -> no content defined!
 -> model component <Parameters/InvGravity> is internal -> no content defined!
 -> check consistency of generated content...
 -> go through the tree!
 -> succesfully validated the input file <G:/Basement/2D_Bauwerk_Bv3/model.json>
 -> creating the hdf5 file <G:/Basement/2D_Bauwerk_Bv3/setup.h5>...
 -> generating the content from the model components ...
 -> model component <EdgesAll/FluxesHy> is internal -> no content defined!
 -> model component <CellsAll/IsWetted> is internal -> no content defined!
 -> model component <CellsAll/ChezyCoe> is internal -> no content defined!
 -> model component <NodeStrg/StateVar> is internal -> no content defined!
 -> model component <EdModDat/LocalDat> is internal -> no content defined!
 -> model component <Parameters/InvGravity> is internal -> no content defined!
 -> check consistency of generated content...
 -> go through the tree!
 -> reading the mesh file <G:/Basement/2D_Bauwerk_Bv3/Basemesh/Mesh.2dm> ...

Error Output

 -> unhandled exception (actually, this should never happen)
 -> invalid vector subscript
 -> ... unfortunately BASEMENT is killed!

I have used and adapted the mesh from an old projekt with Basement 2.8. Is there a problem with the mesh?
Below the first and last lines of the Mesh.2dm

MESH2D
NUM_MATERIALS_PER_ELEM 1
E3T       1    3325    4172    4484       3
E3T       2     794     816     913       2
E3T       3    4171    4483    4664       3
E3T       4    1790     965    1023       2
...
...
...
ND    7006 2623458.597778 1129749.611858 646.129517
ND    7007 2623443.849274 1129730.459678 646.286560
ND    7008 2623464.744762 1129734.028248 646.062317
ND    7009 2623446.942528 1129743.332432 646.328674
NS 31 653 654 655 30 656 657 29 658 659 28 660 661 27 662 663 26 664 665 25 666 667 24 668 669 23 670 671 22 672 673 21 674 675 20 676 677 19 678 679 inflow
NS 134 752 135 753 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 754 755 outflow

best wishes

Offline

#2 2020-07-20 08:41:03

Matthias
Advanced_User
Registered: 2014-12-16
Posts: 29

Re: Invalid vector subscript

You should add a minus (-) to the last node in your nodestring, e.g. ....... 678 -679 inflow and ...... 754 -755 outflow

hope this helps!
matt

Offline

#3 2020-08-11 14:52:16

chri_and
User
Registered: 2017-07-27
Posts: 34

Re: Invalid vector subscript

Hi Matthias

Thanks for the reply. I have tried what you suggested. The Mesh file looks like this:

.......
ND    7006 2623458.597778 1129749.611858 646.129517
ND    7007 2623443.849274 1129730.459678 646.286560
ND    7008 2623464.744762 1129734.028248 646.062317
ND    7009 2623446.942528 1129743.332432 646.328674
NS 31 653 654 655 30 656 657 29 658 659 28 660 661 27 662 663 26 664 665 25 666 667 24 668 669 23 670 671 22 672 673 21 674 675 20 676 677 19 678 -679 inflow
NS 134 752 135 753 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 754 -755 outflow

However I'm getting the same error. In the Tutorial of the river Flaz, the Mesh does not have the minus (-). Why is the minus needed?
How can I get the Mesh to run in Basement 3?

Regards

Offline

#4 2020-08-12 15:50:10

Matteo Facchini
Developer
From: Trento
Registered: 2014-09-05
Posts: 281

Re: Invalid vector subscript

I don't know if it plays any role, but try to put two spaces (instead of one) between NS and the following number

Offline

#5 2020-08-24 10:37:36

chri_and
User
Registered: 2017-07-27
Posts: 34

Re: Invalid vector subscript

Hi

I have tried the double space but it didn't help. I have redone the mesh from sctrach, but now I get another error output:

-> unhandled exception (actually, this should never happen)
-> invalid stod argument
-> ... unfortunately BASEMENT is killed!

What is the problem now?

Offline

#6 2020-08-24 11:44:18

Matteo Facchini
Developer
From: Trento
Registered: 2014-09-05
Posts: 281

Re: Invalid vector subscript

Matthias wrote:

You should add a minus (-) to the last node in your nodestring, e.g. ....... 678 -679 inflow and ...... 754 -755 outflow

hope this helps!
matt

Did you check this after generating your new mesh?

Offline

#7 2020-08-24 14:04:40

chri_and
User
Registered: 2017-07-27
Posts: 34

Re: Invalid vector subscript

Hi

I did check the mesh.

I have tried to change the name (inflow to Inflow), add the 2 spaces between NS an frist node, add the minus but I get always the same problem.

The mesh looks like this:


MESH2D
NUM_MATERIALS_PER_ELEM 1
E3T       1    3218    2144    2360       3
E3T       2     775     797     894       2
E3T       3     213    6086    6023       3
.....
NS  31 30 653 29 654 28 655 27 656 26 657 25 658 24 659 23 660 22 661 21 662 20 663 19 664 -18 Inflow
NS  134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 -170 Outflow

I get this console output:


BASEMENT v3.0.2
BASEplane setup binary
v3.0.2
Copyright: (C) 2020 ETH Zurich / Laboratory of hydraulics, hydrology and glaciology (VAW)

-> composing the model from the input file
-> found aggregate <hydraulics_aggr>
-> found aggregate <hyd_boundary_aggr>
-> found aggregate <hyd_friction_aggr>
-> running on 1 threads
-> generating the content from the model components ...
-> model component <EdgesAll/FluxesHy> is internal -> no content defined!
-> model component <CellsAll/IsWetted> is internal -> no content defined!
-> model component <CellsAll/ChezyCoe> is internal -> no content defined!
-> model component <NodeStrg/StateVar> is internal -> no content defined!
-> model component <EdModDat/LocalDat> is internal -> no content defined!
-> model component <Parameters/InvGravity> is internal -> no content defined!
-> check consistency of generated content...
-> go through the tree!
-> succesfully validated the input file <C:/test/model.json>
-> creating the hdf5 file <C:/test/setup.h5>...
-> generating the content from the model components ...
-> model component <EdgesAll/FluxesHy> is internal -> no content defined!
-> model component <CellsAll/IsWetted> is internal -> no content defined!
-> model component <CellsAll/ChezyCoe> is internal -> no content defined!
-> model component <NodeStrg/StateVar> is internal -> no content defined!
-> model component <EdModDat/LocalDat> is internal -> no content defined!
-> model component <Parameters/InvGravity> is internal -> no content defined!
-> check consistency of generated content...
-> go through the tree!
-> reading the mesh file <C:/test/LonzaBV3.2dm> ...
-> time for mesh file parsing: 0.068s
-> Number of Nodes: 6929
-> writing (1/1) data of type '1' to NodesAll/set
-> writing (6929/3) data of type '2' to NodesAll/Coordnts
-> writing (13106/3) data of type '1' to CellsAll/Topology
-> Number of cells: 13106
-> writing (1/1) data of type '1' to CellsAll/set
-> writing (13106/1) data of type '2' to CellsAll/GeomArea
-> writing (13106/3) data of type '1' to CellsAll/EdgesAll
-> Number of edges: 20036
-> writing (1/1) data of type '1' to EdgesAll/set
-> writing (20036/1) data of type '2' to EdgesAll/GeomLeng
-> writing (20036/2) data of type '2' to EdgesAll/NormVect
-> writing (20036/2) data of type '2' to EdgesAll/CharSize
-> writing (20036/2) data of type '1' to EdgesAll/CellsAll
-> found NodeString: Inflow
-> found NodeString: Outflow
-> writing (2/1) data of type '4' to NodeStrg/StrNames
-> writing (2/1) data of type '1' to NodeStrg/ListSize
-> writing (2/40) data of type '1' to NodeStrg/EdgesAll
-> writing (2/40) data of type '1' to NodeStrg/EdgeSign
-> writing (2/40) data of type '1' to NodeStrg/CellsAll
-> found region: one
-> found region: two
-> found region: three
-> Number of Series files: 1
-> writing (1/1) data of type '1' to InSeries/set

and this eroro output:


-> unhandled exception (actually, this should never happen)
-> invalid stod argument
-> ... unfortunately BASEMENT is killed!

I'm not sure what I'm doing wrong, is it possible to debug basement?

Offline

#8 2020-08-24 14:12:36

Matthias
Advanced_User
Registered: 2014-12-16
Posts: 29

Re: Invalid vector subscript

Check out the files (hydrographs, hqrelations etc.) that you relate to in the model.json:
- are they all comma separated files without any other characters or text-data? (correct column separator is ", ")
- is the naming correct and without äöü?

Offline

#9 2020-08-24 14:41:56

chri_and
User
Registered: 2017-07-27
Posts: 34

Re: Invalid vector subscript

Hi

I deleted the header (commented with double forward slash) from the hydrograph file and works. Is it somewhere written that headers are not allowed?

Sorry for any incovinients and many thanks

Cheers

Offline

#10 2020-08-24 14:44:01

Matthias
Advanced_User
Registered: 2014-12-16
Posts: 29

Re: Invalid vector subscript

Probably not documented (yet) wink

This should be marked as a feature request to add a header e.g. with # in front to add some information to the provided values below.

Offline

Board footer

Powered by FluxBB