SC4 Devotion Forum Archives

SimCity 4 Devotion Custom Content Showcase => Other Projects => Topic started by: sumwonyuno on September 13, 2009, 11:09:04 PM

Title: Query.txt
Post by: sumwonyuno on September 13, 2009, 11:09:04 PM
Author's Note:  I thought there was a game discovery topic in this forum.  Moderators, please move if this isn't an appropriate place.  I know this discovery isn't "custom content" (since Maxis made the extra cheats .dll) and I wouldn't consider this to be a project.

As background, I'm using SimCity through wine on Linux.  I found out how to enable detailed queries (SHIFT + CTRL + ALT and query tool w/ the SC4 Extra Cheats .dll) a few days ago.  Out of curiousity, I decided to click on a building while using detailed queries, to see if any further information would be in the building window.  Nothing.  But after I closed the game and looked in my user's /home folder, I found a Query.txt that had statistics about the building I clicked on.  RippleJet was very much fascinated by the information.  I decided to make this thread to show my collected data.  The Query.txt file is overwritten each time there is a click with detailed queries.  So, I had to rename the file so the data could be preserved.

To start off, I query-clicked a random palm tree at Ara Poana Beach Park:

(https://www.sc4devotion.com/forums/proxy.php?request=http%3A%2F%2Fimg143.imageshack.us%2Fimg143%2F9910%2Ftreen.jpg&hash=1dc3a15f6c89035b5297de120a3ac3cdfaca59da)


|-----------------------------------------------------------
| Query info for cell (208, 201) on 10/4/2768
|-----------------------------------------------------------
| Zoned: None
| Altitude: 270.0
| Land value, intrinsic: 40, total: 255 (High)
| Slope: 11.4
| Powered: yes
| Watered: no
| Traffic Volume: 0   Traffic Congestion: 0
| Edge Density Matrix for travel type 0 (total = 0):
| Edge Density Matrix for travel type 1 (total = 0):
| Edge Density Matrix for travel type 2 (total = 0):
| Edge Density Matrix for travel type 3 (total = 0):
| Edge Density Matrix for travel type 4 (total = 0):
| Edge Density Matrix for travel type 5 (total = 0):
| Edge Density Matrix for travel type 6 (total = 0):
| Edge Density Matrix for travel type 7 (total = 0):
| Edge Density Matrix for travel type 8 (total = 0):
| Edge Density Matrix for travel type 9 (total = 0):
|-----------------------------------------------------------


Then I tried query-clicking one of the highest elevations in the city tile, Juicebowl Crater:

(https://www.sc4devotion.com/forums/proxy.php?request=http%3A%2F%2Fimg19.imageshack.us%2Fimg19%2F5558%2Fjuicebowl.jpg&hash=aac9f25fa44881fbe42e8091e66b5edfbd649d45)


|-----------------------------------------------------------
| Query info for cell (101, 81) on 10/4/2768
|-----------------------------------------------------------
| Zoned: None
| Altitude: 420.5
| Land value, intrinsic: 31, total: 255 (High)
| Slope: 84.4
| Powered: yes
| Watered: no
| Traffic Volume: 0   Traffic Congestion: 0
| Edge Density Matrix for travel type 0 (total = 0):
| Edge Density Matrix for travel type 1 (total = 0):
| Edge Density Matrix for travel type 2 (total = 0):
| Edge Density Matrix for travel type 3 (total = 0):
| Edge Density Matrix for travel type 4 (total = 0):
| Edge Density Matrix for travel type 5 (total = 0):
| Edge Density Matrix for travel type 6 (total = 0):
| Edge Density Matrix for travel type 7 (total = 0):
| Edge Density Matrix for travel type 8 (total = 0):
| Edge Density Matrix for travel type 9 (total = 0):
|-----------------------------------------------------------


Analysis:  Both show the data for a single game cell (16m x 16m).  Data is mostly self-explanitory.  The date matches the date in game (offset by 2000 years).  I don't know how to intrepret the land value info.

Next are query-clicks of the transportation network:

(https://www.sc4devotion.com/forums/proxy.php?request=http%3A%2F%2Fimg223.imageshack.us%2Fimg223%2F5594%2Fjariinterchange.jpg&hash=82ead1fdaa5acb3cd8331f2f562c3f98d76175ee)

A road FLUP:

|-----------------------------------------------------------
| Query info for cell (61, 99) on 10/4/2768
|-----------------------------------------------------------
| Zoned: None
| Altitude: 270.0
| Land value, intrinsic: 10, total: 255 (High)
| Slope: 8.5
| Powered: yes
| Watered: yes
| Network: Road W E
| Network: Pipe W E
| Traffic Volume: 255   Traffic Congestion: 1
| Edge Density Matrix for travel type 0 (total = 0):
| Edge Density Matrix for travel type 1 (total = 0):
| Edge Density Matrix for travel type 2 (total = 0):
| Edge Density Matrix for travel type 3 (total = 0):
| Edge Density Matrix for travel type 4 (total = 0):
| Edge Density Matrix for travel type 5 (total = 0):
| Edge Density Matrix for travel type 6 (total = 0):
| Edge Density Matrix for travel type 7 (total = 0):
| Edge Density Matrix for travel type 8 (total = 0):
| Edge Density Matrix for travel type 9 (total = 0):
|-----------------------------------------------------------


Analysis:  Almost similar to the first two examples, but now with two extra items and values for traffic.  On this FLUP, there is no use in the morning, but 267 cars use it in the evening.  It is oriented west-east.  Curiously, the FLUP is on level ground, land next to it is on a slope.

A straight, elevated OWR NAM puzzle piece:


|-----------------------------------------------------------
| Query info for cell (56, 101) on 10/4/2768
|-----------------------------------------------------------
| Zoned: None
| Altitude: 270.0
| Land value, intrinsic: 10, total: 250 (High)
| Slope: 8.5
| Powered: yes
| Watered: yes
| Network:
| Traffic Volume: 255   Traffic Congestion: 1
| Edge Density Matrix for travel type 0 (total = 0):
| Edge Density Matrix for travel type 1 (total = 846):
|   0   0   0   0       0   0   0   0
|   0   0   0 846       0   0   0  15
|   0   0   0   0       0   0   0   0
|   0   0   0   0       0   0   0   0
| Edge Density Matrix for travel type 2 (total = 22):
|   0   0   0   0       0   0   0   0
|   0   0   0  22       0   0   0   0
|   0   0   0   0       0   0   0   0
|   0   0   0   0       0   0   0   0
| Edge Density Matrix for travel type 3 (total = 0):
...
|-----------------------------------------------------------


Analysis:  No orientation info this time, but it's a N-S piece.  More information now for the matrices.  There are 846 cars and 22 buses in the morning, and only 15 cars in the evening.  Travel type 1 seems to be car, type 2 seems to be buses.  Left matrix seems to be morning, right seems to be evening.  Total seems to only count morning traffic.

A regular road network tile:

|-----------------------------------------------------------
| Query info for cell (60, 98) on 10/4/2768
|-----------------------------------------------------------
| Zoned: None
| Altitude: 270.0
| Land value, intrinsic: 10, total: 255 (High)
| Slope: 8.5
| Powered: yes
| Watered: yes
| Network: Road W E
| Traffic Volume: 255   Traffic Congestion: 255
| Edge Density Matrix for travel type 0 (total = 0):
| Edge Density Matrix for travel type 1 (total = 3542):
|   0   0 108   0       0   0 2527   0
|   0   0   0   0       0   0   0   0
| 3434   0   0   0      61   0   0   0
|   0   0   0   0       0   0   0   0
| Edge Density Matrix for travel type 2 (total = 113):
|   0   0   0   0       0   0 201   0
|   0   0   0   0       0   0   0   0
| 113   0   0   0       0   0   0   0
|   0   0   0   0       0   0   0   0
...
|-----------------------------------------------------------


Analysis:  Totals match up, but more thinking is required.  3542/113 cars/buses in the morning, 2588/201 in the evening.  None of the info in the matrices now are in the same places as with the el-OWR.  The 113 corresponds to westbound morning buses, 201 with eastbound afternoon.  So column 1, row 3 is westbound through network traffic (not originating or ending), and column 3, row 1 is eastbound.

A nearby tiles with pedestrians shows similar patterns.  Travel type 0 seems to be pedestrians.  Westbound and eastbound through traffic are in the same places.  I looked for a tile where the pedestrian routes started. 


...
| Edge Density Matrix for travel type 0 (total = 8):
|   0   0   0   0       0   0   0   0
|   0   0   8   0       0   0   0   0
|   0   0   0   0       0   8   0   0
|   0   0   0   0       0   0   0   0
...


Analysis:  These pedestrians were from a house, going one tile south to the road tile, then going east in the morning.  So column 3 looks like eastbound traffic, row 3 looks like westbound traffic.  Might be a "mirror" property in the matricies.  Column 3, row 2 seems to indicate route start.  Column 2, row 3 seems to indicate route end.

(https://www.sc4devotion.com/forums/proxy.php?request=http%3A%2F%2Fimg30.imageshack.us%2Fimg30%2F8531%2Felhwy.jpg&hash=142be4bcca8d409ed0d48ec9e7884f0ebddf00ef)

Congested Highway tile, eastbound:

|-----------------------------------------------------------
| Query info for cell (176, 93) on 10/4/2768
|-----------------------------------------------------------
| Zoned: None
| Altitude: 270.0
| Land value, intrinsic: 10, total: 255 (High)
| Slope: 0.0
| Powered: yes
| Watered: yes
| Network: Highway W E
| Traffic Volume: 255   Traffic Congestion: 44
| Edge Density Matrix for travel type 0 (total = 0):
| Edge Density Matrix for travel type 1 (total = 10895):
|   0   0 10895   0       0   0 61128   0
|   0   0   0   0       0   0   0   0
|   0   0   0   0       0   0   0   0
|   0   0   0   0       0   0   0   0
| Edge Density Matrix for travel type 2 (total = 4132):
|   0   0 4132   0       0   0 5855   0
|   0   0   0   0       0   0   0   0
|   0   0   0   0       0   0   0   0
|   0   0   0   0       0   0   0   0
...


Analysis:  Data is in the places that we expected.  I have Simulator Z Ultra, and the congestion view shows orange.

Adjacent congested highway tile, westbound:

|-----------------------------------------------------------
| Query info for cell (177, 92) on 10/4/2768
|-----------------------------------------------------------
| Zoned: None
| Altitude: 270.0
| Land value, intrinsic: 10, total: 255 (High)
| Slope: 0.0
| Powered: yes
| Watered: yes
| Network: Highway W E
| Traffic Volume: 255   Traffic Congestion: 19
| Edge Density Matrix for travel type 0 (total = 0):
| Edge Density Matrix for travel type 1 (total = 63742):
|   0   0   0   0       0   0   0   0
|   0   0   0   0       0   0   0   0
| 63742   0   0   0       8   0   0   0
|   0   0   0   0       0   0   0   0
| Edge Density Matrix for travel type 2 (total = 5509):
|   0   0   0   0       0   0   0   0
|   0   0   0   0       0   0   0   0
| 5509   0   0   0       0   0   0   0
|   0   0   0   0       0   0   0   0
...


Analysis:  Data matches our analyses with regards to column 3/row 1 and column 1/row 3.  Congestion view is yellow.

That's it for now, I will post RCI buildings (plop and grow), other plopped buildings and more transportation networks next time.
Title: Re: Query.txt
Post by: Diggis on September 14, 2009, 01:08:38 AM
Wow, thats really interesting.  Great find!  :thumbsup:
Title: Re: Query.txt
Post by: RippleJet on September 14, 2009, 01:53:19 AM
The travel type would be the same as in the Traffic Simulator, and also as we've found out in the Lot Subfile of savegames:


Not sure what travel type 9 would be though... I don't think it's used at all...
Title: Re: Query.txt
Post by: sumwonyuno on September 14, 2009, 09:14:24 PM
Thanks Diggis, and thanks RippleJet, for saving me some time figure out the other travel types.  Could type 9 possibly be ferries?

For those using Windows, I have good news.  Query.txt is available to you too.  It was in my user's /home folder because I type the wine ".../SimCity 4.exe" command while the current directory for the terminal is my /home folder.  I tried query-clicking in Windows, and I found a Query.txt in the Apps folder of ...\Maxis\SimCity 4 Deluxe\ .  I suggest running the game in windowed mode, so you have access to the output file at the same time.

Let's go to the example I showed RippleJet in another thread:

Residential Grow:


|-----------------------------------------------------------
| Query info for cell (187, 170) on 10/4/2768
|-----------------------------------------------------------
| Lot: (189, 173) 6x4, east-facing, state: occupied new, configuration: R$$$9_6x4_ SeaView Tower 2_a40ad9a7
| Jobs $0.0 $$0.0 $$$0.0 - Travel Jobs $0 $$0 $$$0
| Building: R$$$ Stage 9 SeaView Tower 2, 4213 $$$
| Occupancy--building (tract): R$ 0% (0%), R$$ 0% (0%), R$$$ 94% (100%),
| Zoned: R###
| Altitude: 270.0
| Land value, intrinsic: 10, total: 255 (High)
| Slope: 0.0
| Powered: yes
| Watered: yes
| Traffic Volume: 255   Traffic Congestion: 0
| Edge Density Matrix for travel type 0 (total = 0):
...
|-----------------------------------------------------------
|
| Desirability equation for R$
|   desirability = base value: 25
|   + land value effect, f(value: 255): 0
|   + slope effect, f(value: 0.0): 0
|   + R$ proximity effect, f(0): 5
|   + R$$ proximity effect, f(0): -5
|   + R$$$ proximity effect, f(0): -5
|   + Co$$ proximity effect, f(0): 0
|   + Co$$$ proximity effect, f(0): 0
|   + park effect, f(1492): 10
|   + Air pollution effect, f(0): 25
|   + Water pollution effect, f(0): 0
|   + Garbage pollution effect, f(0): 25
|   + Radiation pollution effect, f(0): 0
|   + school effect, f(1.0): 10
|   + hospital effect, f(1.0): 5
|   + crime effect, f(0): 25
|   + traffic effect, f(255): -1
|   + trip length effect, f(1): 9
|   + landmark effect, f(602): 0
|   + transient effect, f(46): 36
|   = 164
|   
| As calculated last cycle for tract (46, 42)
|   Population:        0
|   Existing capacity: 0
|   Maximum capacity:  12424
|   Desirability:      128
|
|----------------------------------------
|
| Desirability equation for R$$
|   desirability = base value: -89
|   + land value effect, f(value: 255): 0
|   + slope effect, f(value: 0.0): 0
|   + R$ proximity effect, f(0): -5
|   + R$$ proximity effect, f(0): 5
|   + R$$$ proximity effect, f(0): -5
|   + Co$$ proximity effect, f(0): 0
|   + Co$$$ proximity effect, f(0): 0
|   + park effect, f(1492): 24
|   + Air pollution effect, f(0): 50
|   + Water pollution effect, f(0): 0
|   + Garbage pollution effect, f(0): 50
|   + Radiation pollution effect, f(0): 0
|   + school effect, f(1.0): 20
|   + hospital effect, f(1.0): 8
|   + crime effect, f(0): 50
|   + traffic effect, f(255): -4
|   + trip length effect, f(1): 9
|   + landmark effect, f(602): 0
|   + transient effect, f(46): 36
|   = 149
|   
| As calculated last cycle for tract (46, 42)
|   Population:        0
|   Existing capacity: 0
|   Maximum capacity:  7664
|   Desirability:      113
|
|----------------------------------------
|
| Desirability equation for R$$$
|   desirability = base value: -104
|   + land value effect, f(value: 255): 10
|   + slope effect, f(value: 0.0): 0
|   + R$ proximity effect, f(0): -5
|   + R$$ proximity effect, f(0): -5
|   + R$$$ proximity effect, f(0): 5
|   + Co$$ proximity effect, f(0): 0
|   + Co$$$ proximity effect, f(0): 0
|   + park effect, f(1492): 30
|   + Air pollution effect, f(0): 50
|   + Water pollution effect, f(0): 0
|   + Garbage pollution effect, f(0): 50
|   + Radiation pollution effect, f(0): 0
|   + school effect, f(1.0): 25
|   + hospital effect, f(1.0): 10
|   + crime effect, f(0): 50
|   + traffic effect, f(255): -9
|   + trip length effect, f(1): 9
|   + landmark effect, f(602): 0
|   + transient effect, f(46): 36
|   = 152
|   
| As calculated last cycle for tract (46, 42)
|   Population:        1400
|   Existing capacity: 1400
|   Maximum capacity:  3352
|   Desirability:      116
|
|-----------------------------------------------------------
|
| Last successful R build
|
|-----------------------------------------------------------
|
| Last failed R$ build
|
|----------------------------------------
|
| Last failed R$$ build
|
|----------------------------------------
|
| Last failed R$$$ build
|
|-----------------------------------------------------------


There is a lot of information, and I'm not sure how to interpret them.

Residential Plop:

|-----------------------------------------------------------
| Query info for cell (114, 163) on 10/4/2768
|-----------------------------------------------------------
| Lot: (116, 161) 6x6, north-facing, state: occupied new, configuration: R$$_6x6 TaiYuen Phase2a TE (CAM)_b3defe85
| Jobs $0.0 $$0.0 $$$0.0 - Travel Jobs $0 $$0 $$$0
| Building: R$$ TaiYuenPhase2 (CAM), 9411 $$
| Occupancy--building (tract): R$ 0% (0%), R$$ 93% (100%),
| Zoned: Plopped Bldg
| Altitude: 270.0
| Land value, intrinsic: 10, total: 255 (High)
| Slope: 0.0
| Powered: yes
| Watered: yes
| Network:
| Traffic Volume: 255   Traffic Congestion: 0
| Edge Density Matrix for travel type 0 (total = 0):
...
|-----------------------------------------------------------


Analysis:  There's much less information for a plopped building than one that is grown by the game.  This pattern between plopped and grown is apparent for C and I as well.

Commercial Grow:

|-----------------------------------------------------------
| Query info for cell (56, 177) on 10/4/2768
|-----------------------------------------------------------
| Lot: (56, 178) 2x3, east-facing, state: occupied new, configuration: CS$$$2_2x3_60004180
| Jobs $21.1 $$10.2 $$$2.7 - Travel Jobs $21 $$10 $$$3
| Building: CS$$$24x30_1ChiDinnerTheater_050F, 37 $$$
| Occupancy--building (tract): Cs$ 0% (0%), Cs$$ 0% (0%), Cs$$$ 92% (100%),
| Zoned: C#
| Altitude: 270.0
| Land value, intrinsic: 45, total: 255 (High)
| Slope: 0.0
| Powered: yes
| Watered: yes
| Traffic Volume: 169   Traffic Congestion: 0
| Edge Density Matrix for travel type 0 (total = 0):
...
|-----------------------------------------------------------
|
| Desirability equation for Cs$
|   desirability = base value: 68
|   + land value effect, f(value: 255): 0
|   + slope effect, f(value: 9.4): 0
|   + R$ proximity effect, f(0): 0
|   + R$$ proximity effect, f(0): 0
|   + R$$$ proximity effect, f(0): 0
|   + Co$$ proximity effect, f(0): 0
|   + Co$$$ proximity effect, f(0): 0
|   + park effect, f(1077): 0
|   + Air pollution effect, f(0): 12
|   + Water pollution effect, f(0): 0
|   + Garbage pollution effect, f(0): 25
|   + Radiation pollution effect, f(0): 0
|   + school effect, f(1.0): 0
|   + hospital effect, f(1.0): 0
|   + crime effect, f(0): 25
|   + traffic effect, f(169): 12
|   + trip length effect, f(255): 0
|   + landmark effect, f(939): 10
|   + transient effect, f(27): 21
|   = 173
|   
| As calculated last cycle for tract (14, 44)
|   Population:        0
|   Existing capacity: 0
|   Maximum capacity:  78
|   Desirability:      152
|
|----------------------------------------
|
| Desirability equation for Cs$$
|   desirability = base value: -3
|   + land value effect, f(value: 255): 0
|   + slope effect, f(value: 9.4): 0
|   + R$ proximity effect, f(0): 0
|   + R$$ proximity effect, f(0): 0
|   + R$$$ proximity effect, f(0): 0
|   + Co$$ proximity effect, f(0): 0
|   + Co$$$ proximity effect, f(0): 0
|   + park effect, f(1077): 0
|   + Air pollution effect, f(0): 25
|   + Water pollution effect, f(0): 0
|   + Garbage pollution effect, f(0): 50
|   + Radiation pollution effect, f(0): 0
|   + school effect, f(1.0): 0
|   + hospital effect, f(1.0): 0
|   + crime effect, f(0): 50
|   + traffic effect, f(169): 7
|   + trip length effect, f(255): 0
|   + landmark effect, f(939): 20
|   + transient effect, f(27): 21
|   = 170
|   
| As calculated last cycle for tract (14, 44)
|   Population:        0
|   Existing capacity: 0
|   Maximum capacity:  75
|   Desirability:      149
|
|----------------------------------------
|
| Desirability equation for Cs$$$
|   desirability = base value: 1
|   + land value effect, f(value: 255): 10
|   + slope effect, f(value: 9.4): 0
|   + R$ proximity effect, f(0): 0
|   + R$$ proximity effect, f(0): 0
|   + R$$$ proximity effect, f(0): 0
|   + Co$$ proximity effect, f(0): 0
|   + Co$$$ proximity effect, f(0): 0
|   + park effect, f(1077): 0
|   + Air pollution effect, f(0): 40
|   + Water pollution effect, f(0): 0
|   + Garbage pollution effect, f(0): 50
|   + Radiation pollution effect, f(0): 0
|   + school effect, f(1.0): 0
|   + hospital effect, f(1.0): 0
|   + crime effect, f(0): 50
|   + traffic effect, f(169): -5
|   + trip length effect, f(255): 0
|   + landmark effect, f(939): 30
|   + transient effect, f(27): 21
|   = 197
|   
| As calculated last cycle for tract (14, 44)
|   Population:        19
|   Existing capacity: 19
|   Maximum capacity:  18
|   Desirability:      176
|
|----------------------------------------
|
| Desirability equation for Co$$
|   desirability = base value: -27
|   + land value effect, f(value: 255): 0
|   + slope effect, f(value: 9.4): 0
|   + R$ proximity effect, f(0): 0
|   + R$$ proximity effect, f(0): 0
|   + R$$$ proximity effect, f(0): 0
|   + Co$$ proximity effect, f(0): 0
|   + Co$$$ proximity effect, f(0): 0
|   + park effect, f(1077): 0
|   + Air pollution effect, f(0): 25
|   + Water pollution effect, f(0): 0
|   + Garbage pollution effect, f(0): 50
|   + Radiation pollution effect, f(0): 0
|   + school effect, f(1.0): 0
|   + hospital effect, f(1.0): 0
|   + crime effect, f(0): 50
|   + traffic effect, f(169): 6
|   + trip length effect, f(255): 0
|   + landmark effect, f(939): 20
|   + transient effect, f(27): 21
|   = 145
|   
| As calculated last cycle for tract (14, 44)
|   Population:        0
|   Existing capacity: 0
|   Maximum capacity:  69
|   Desirability:      124
|
|----------------------------------------
|
| Desirability equation for Co$$$
|   desirability = base value: -65
|   + land value effect, f(value: 255): 10
|   + slope effect, f(value: 9.4): 0
|   + R$ proximity effect, f(0): 0
|   + R$$ proximity effect, f(0): 0
|   + R$$$ proximity effect, f(0): 0
|   + Co$$ proximity effect, f(0): 0
|   + Co$$$ proximity effect, f(0): 0
|   + park effect, f(1077): 0
|   + Air pollution effect, f(0): 40
|   + Water pollution effect, f(0): 0
|   + Garbage pollution effect, f(0): 50
|   + Radiation pollution effect, f(0): 0
|   + school effect, f(1.0): 0
|   + hospital effect, f(1.0): 0
|   + crime effect, f(0): 50
|   + traffic effect, f(169): -2
|   + trip length effect, f(255): 0
|   + landmark effect, f(939): 30
|   + transient effect, f(27): 21
|   = 134
|   
| As calculated last cycle for tract (14, 44)
|   Population:        0
|   Existing capacity: 0
|   Maximum capacity:  33
|   Desirability:      113
|
|-----------------------------------------------------------
|
| Last successful C build
|
|-----------------------------------------------------------
|
| Last failed Cs$ build
|
|----------------------------------------
|
| Last failed Cs$$ build
|
|----------------------------------------
|
| Last failed Cs$$$ build
|
|----------------------------------------
|
| Last failed Co$$ build
|
|----------------------------------------
|
| Last failed Co$$$ build
|
|-----------------------------------------------------------


Commericial Plop:

|-----------------------------------------------------------
| Query info for cell (139, 132) on 10/4/2768
|-----------------------------------------------------------
| Lot: (140, 130) 4x4, north-facing, state: occupied new, configuration: CO$$$11_4x4_Shiner Tower_b3f583e3
| Jobs $1087.2 $$3533.4 $$$815.4 - Travel Jobs $1087 $$3533 $$$815
| Building: CO$$$ Stage 11 Shiner Tower, 5993 $$$
| Occupancy--building (tract): Co$$ 0% (0%), Co$$$ 91% (100%),
| Zoned: Plopped Bldg
| Altitude: 270.0
| Land value, intrinsic: 10, total: 252 (High)
| Slope: 0.0
| Powered: yes
| Watered: yes
| Traffic Volume: 255   Traffic Congestion: 0
| Edge Density Matrix for travel type 0 (total = 0):
...
|-----------------------------------------------------------


Industrial Grow:

|-----------------------------------------------------------
| Query info for cell (90, 207) on 10/4/2768
|-----------------------------------------------------------
| Lot: (91, 208) 2x3, east-facing, state: occupied new, configuration: IHT$$$7_2x3_PharmaLab_661de05e
| Jobs $34.0 $$272.0 $$$34.0 -> (89, 200)
| Building: PharmaLab, 364 $$$
| Occupancy--building (tract): Ih 93% (100%),
| Zoned: Ih
| Altitude: 270.0
| Land value, intrinsic: 45, total: 255 (High)
| Slope: 0.0
| Powered: yes
| Watered: yes
| Traffic Volume: 14   Traffic Congestion: 0
| Edge Density Matrix for travel type 0 (total = 0):
...
|-----------------------------------------------------------
|
| Desirability equation for I resource
|   desirability = base value: -81
|   + land value effect, f(value: 255): 0
|   + slope effect, f(value: 0.0): 0
|   + R$ proximity effect, f(0): 0
|   + R$$ proximity effect, f(0): 0
|   + R$$$ proximity effect, f(0): 0
|   + Co$$ proximity effect, f(0): 0
|   + Co$$$ proximity effect, f(0): 0
|   + park effect, f(109): 0
|   + Air pollution effect, f(0): 50
|   + Water pollution effect, f(0): 0
|   + Garbage pollution effect, f(0): 50
|   + Radiation pollution effect, f(0): 0
|   + school effect, f(1.0): 0
|   + hospital effect, f(1.0): 0
|   + crime effect, f(0): 10
|   + traffic effect, f(14): 39
|   + trip length effect, f(2): 15
|   + landmark effect, f(314): 0
|   + transient effect, f(0): 0
|   = 83
|   
| As calculated last cycle for tract (22, 51)
|   Population:        0
|   Existing capacity: 0
|   Maximum capacity:  0
|   Desirability:      83
|
|----------------------------------------
|
| Desirability equation for I dirty
|   desirability = base value: 69
|   + land value effect, f(value: 255): 0
|   + slope effect, f(value: 0.0): 0
|   + R$ proximity effect, f(0): 0
|   + R$$ proximity effect, f(0): 0
|   + R$$$ proximity effect, f(0): 0
|   + Co$$ proximity effect, f(0): 0
|   + Co$$$ proximity effect, f(0): 0
|   + park effect, f(109): 0
|   + Air pollution effect, f(0): 0
|   + Water pollution effect, f(0): 0
|   + Garbage pollution effect, f(0): 5
|   + Radiation pollution effect, f(0): 0
|   + school effect, f(1.0): 0
|   + hospital effect, f(1.0): 0
|   + crime effect, f(0): 10
|   + traffic effect, f(14): 0
|   + trip length effect, f(2): 15
|   + landmark effect, f(314): 0
|   + transient effect, f(0): 0
|   = 99
|   
| As calculated last cycle for tract (22, 51)
|   Population:        14
|   Existing capacity: 14
|   Maximum capacity:  1776
|   Desirability:      99
|
|----------------------------------------
|
| Desirability equation for I manufacturing
|   desirability = base value: 47
|   + land value effect, f(value: 255): 0
|   + slope effect, f(value: 0.0): 0
|   + R$ proximity effect, f(0): 0
|   + R$$ proximity effect, f(0): 0
|   + R$$$ proximity effect, f(0): 0
|   + Co$$ proximity effect, f(0): 0
|   + Co$$$ proximity effect, f(0): 0
|   + park effect, f(109): 0
|   + Air pollution effect, f(0): 5
|   + Water pollution effect, f(0): 0
|   + Garbage pollution effect, f(0): 5
|   + Radiation pollution effect, f(0): 0
|   + school effect, f(1.0): 0
|   + hospital effect, f(1.0): 0
|   + crime effect, f(0): 25
|   + traffic effect, f(14): 0
|   + trip length effect, f(2): 15
|   + landmark effect, f(314): 0
|   + transient effect, f(0): 0
|   = 97
|   
| As calculated last cycle for tract (22, 51)
|   Population:        66
|   Existing capacity: 68
|   Maximum capacity:  576
|   Desirability:      97
|
|----------------------------------------
|
| Desirability equation for I high tech
|   desirability = base value: -94
|   + land value effect, f(value: 255): 10
|   + slope effect, f(value: 0.0): 0
|   + R$ proximity effect, f(0): 0
|   + R$$ proximity effect, f(0): 0
|   + R$$$ proximity effect, f(0): 0
|   + Co$$ proximity effect, f(0): 0
|   + Co$$$ proximity effect, f(0): 0
|   + park effect, f(109): 30
|   + Air pollution effect, f(0): 50
|   + Water pollution effect, f(0): 0
|   + Garbage pollution effect, f(0): 50
|   + Radiation pollution effect, f(0): 0
|   + school effect, f(1.0): 0
|   + hospital effect, f(1.0): 0
|   + crime effect, f(0): 50
|   + traffic effect, f(14): 0
|   + trip length effect, f(2): 15
|   + landmark effect, f(314): 0
|   + transient effect, f(0): 0
|   = 111
|   
| As calculated last cycle for tract (22, 51)
|   Population:        508
|   Existing capacity: 508
|   Maximum capacity:  744
|   Desirability:      111
|
|-----------------------------------------------------------
|
| Last successful I build
|
|-----------------------------------------------------------
|
| Last failed Ir build
|
|----------------------------------------
|
| Last failed Id build
|
|----------------------------------------
|
| Last failed Im build
|
|----------------------------------------
|
| Last failed Iht build
|
|-----------------------------------------------------------



Industrial Plop:

|-----------------------------------------------------------
| Query info for cell (43, 169) on 10/4/2768
|-----------------------------------------------------------
| Lot: (44, 167) 3x6, north-facing, state: occupied new, configuration: I-m7_3x6_90001230
| Jobs $174.0 $$156.6 $$$17.4 - Travel Jobs $174 $$161 $$$17
| Building: IM38x88_3ManuOut15_082A, 504 $$
| Occupancy--building (tract): Im 69% (68%),
| Zoned: Plopped Bldg
| Altitude: 270.0
| Land value, intrinsic: 45, total: 255 (High)
| Slope: 0.0
| Powered: yes
| Watered: yes
| Traffic Volume: 90   Traffic Congestion: 0
| Edge Density Matrix for travel type 0 (total = 0):
...
|-----------------------------------------------------------


As for other plopped buildings in the game, there doesn't seem to be any further special information.

Natural Gas Power Plant:

|-----------------------------------------------------------
| Query info for cell (66, 179) on 10/4/2768
|-----------------------------------------------------------
| Lot: (67, 177) 4x4, north-facing, state: occupied new, configuration: Up4x4_NaturalGasPowerPlant_0a32dbff
| Jobs $28.0 $$15.0 $$$5.0 - Travel Jobs $28 $$15 $$$5
| Building: Up64x64_NaturalGasPowerPlant_1F43 $$
| Occupancy--building (tract):
| Zoned: Plopped Bldg
| Altitude: 270.0
| Land value, intrinsic: 45, total: 255 (High)
| Slope: 0.0
| Powered: yes
| Watered: yes
| Traffic Volume: 225   Traffic Congestion: 0
| Edge Density Matrix for travel type 0 (total = 0):
...
|-----------------------------------------------------------


Seaport, at capacity:

|-----------------------------------------------------------
| Query info for cell (16, 234) on 10/4/2768
|-----------------------------------------------------------
| Lot: (15, 229) 11x5, west-facing, state: occupied distressed1, configuration: PZ12x6_SeaportP1_4a52917d
| Jobs $95.0 $$5.0 $$$0.0 - Travel Jobs $95 $$5 $$$0
| Building: Ut10x28_SeaportWarehouse1_1F53 $$
| Occupancy--building (tract):
| Zoned: Seaport
| Altitude: 230.0
| Land value, intrinsic: 0, total: 105 (Medium)
| Slope: 20.0
| Powered: yes
| Watered: yes
| Traffic Volume: 0   Traffic Congestion: 0
| Edge Density Matrix for travel type 0 (total = 0):
...
|-----------------------------------------------------------


The following is a RTMT OWR bus stop piece, westbound:

|-----------------------------------------------------------
| Query info for cell (91, 135) on 10/4/2768
|-----------------------------------------------------------
| Lot: (91, 135) 1x1, west-facing, state: occupied new, configuration: Utils_RT_OneWay_Bus_0c9db034
| Jobs $2.0 $$0.0 $$$0.0 - Travel Jobs $2 $$0 $$$0
| Building: Ut_RT_OneWay_Bus
| Occupancy--building (tract):
| Zoned: Plopped Bldg
| Altitude: 270.0
| Land value, intrinsic: 10, total: 250 (High)
| Slope: 0.0
| Powered: yes
| Watered: yes
| Network:
| Traffic Volume: 255   Traffic Congestion: 1
| Edge Density Matrix for travel type 0 (total = 10):
|   0   0   0   0       0   0   3   0
|   0   0   0   0       0   0   0   0
|   3   0   7   0      69   0   0   0
|   0   0   0   0       0   0   0   0
| Edge Density Matrix for travel type 1 (total = 8625):
|   0   0   0   0       0   0   0   0
|   0   0   0   0       0   0   0   0
| 8625   0   0   0     543   0   0   0
|   0   0   0   0       0   0   0   0
| Edge Density Matrix for travel type 2 (total = 0):
...
|-----------------------------------------------------------


Analysis:  No bus riders at this stop.

That's it for now.  I'll be figuring out what those cells in the matrices mean.  Why is it important?  When you route query a network tile, it only shows the cummulative totals of that tile for that time period (morning or evening).  For network tiles where one travel type is going one direction through the tile, it's easy to figure out the usage.  However, if the tile is bi-directional, has multiple travel types, allows route starts/destinations or is an intersection, sorting out network information isn't possible through the tools available through the game's UI.  This might be a boon to those that want detailed transportation network info.
Title: Re: Query.txt
Post by: z on September 15, 2009, 02:25:11 AM
Fascinating!  For those who were wondering exactly what an edge density matrix is, here's a concise definition taken from the paper Likelihood-based Clustering of Directed Graphs (http://home.mit.bme.hu/~nepusz/files/nepusz_isciii07.pdf):

(https://www.sc4devotion.com/forums/proxy.php?request=http%3A%2F%2Fimg182.imageshack.us%2Fimg182%2F6518%2Fedm1.jpg&hash=da83070946a37566ec676080c71458af204bace4)

OK, now that that's been made perfectly clear, could someone please explain that to me?  ()what()

Quote from: sumwonyuno on September 14, 2009, 09:14:24 PM
Thanks Diggis, and thanks RippleJet, for saving me some time figure out the other travel types.  Could type 9 possibly be ferries?

I would be pretty sure that it is.  Ferries are in a class by themselves, and are treated differently in different places.
Title: Re: Query.txt
Post by: RippleJet on September 15, 2009, 02:45:42 AM
Quote from: sumwonyuno on September 14, 2009, 09:14:24 PM
There is a lot of information, and I'm not sure how to interpret them.


Lot:
The numbers within brackets are the tile coordinates. (0,0) is in the NW corner of the city.
The state interests me... since we've also found this flag in the Lot subfile of savegames.
What other values could be found, except "new" and "distressed1" (as for the seaport)?
configuration is the lot exemplar's name.


Building:
The name of the building exemplar, followed by the maximum capacity for RCI buildings.
The maximum capacity is the value given in the property "Capacity Satisfied".


Occupancy:
Due to desirability factors, the maximum capacity is reduced by this percentage.
When doing a normal query in the game, you get two numbers for "occupancy".
The first one is this actual capacity, the second one (within brackets) is the maximum capacity.

I am not sure how to interpret the values for the tract (those within brackets).
A "tract" in the game is 4×4 tiles.


Jobs:
This is the actual job count for the building. These numbers are decimal numbers.
For residential buildings, landmarks, etc. there are no jobs.
For civic buildings these numbers are as given by the property "Demand Created".

For commercial and industrial buildings these numbers are based on the actual capacity.
That capacity is distributed between §, §§ and §§§ in accordance with the Census Drives (http://sc4devotion.com/forums/index.php?topic=963.0).


Travel Jobs:
These are the actual number of commuters coming to this lot.
It is rounded down from the corresponding Jobs (above) to a whole integer value.
Industrial anchor buildings also include the commuters to "filler lots" (mechanic and out) surrounding it.


Zoned:
The type of zone, which can be (derived from the Zone Manager in SimCity_1.dat):
   None
   R Low Density - R#
   R Medium Density - R##
   R High Density - R###
   C Low Density - C#
   C Medium Density - C##
   C High Density - C###
   I Low Density (agriculture) - Il
   I Medium Density - Im
   I High Density - Ih
   Military
   Airport
   Seaport
   Spaceport (unused in the game)
   Landfill
   Plopped


Land Value:
The intrinsic value isn't currently used in the game.
Each RCI developer exemplar has the property "Land Value Use Intrinsic" set to False.
The total land value is scaled between 0 and 255.


Desirability:
Desirability is calculated per tract (4×4 tiles).
All factors are given by properties in the appropriate developer exemplars.
There's one developer exemplar for every RCI type, each having these properties:
   Baseline Desirability
   Land Value Effect
   Slope Effect
   R$ Proximity Effect
   R$$ Proximity Effect
   R$$$ Proximity Effect
   Co$$ Proximity Effect
   Co$$$ Proximity Effect
   Park Effect
   Pollution Effect Air
   Pollution Effect Water
   Pollution Effect Garbage
   Pollution Effect Radiation
   School Effect
   Hospital Effect
   Crime Effect
   Traffic Effect
   Trip Length Effect
   Landmark Effect
   Transient Aura Effect



Quote from: z on September 15, 2009, 02:25:11 AM
OK, now that that's been made perfectly clear, could someone please explain that to me?  ()what()

And I was hoping you would be doing that... :D
Title: Re: Query.txt
Post by: BarbyW on September 15, 2009, 02:48:26 AM
I always wanted to know what an edge density matrix was. That explains it all perfectly ::) $%Grinno$% $%Grinno$%
Title: Re: Query.txt
Post by: dedgren on September 15, 2009, 10:33:41 AM
Works like a charm for me.  I'll note that, if you are a windows user and don't want to do your testing in windowed mode, simply press [ alt ] and [ tab ] at the same time to minimize the game while working with your apps folder.

Unfortunately, the hope that I had that query.txt would tell us something about tunnels does not pan out.

(https://www.sc4devotion.com/forums/proxy.php?request=http%3A%2F%2Fimg21.imageshack.us%2Fimg21%2F4992%2Fpic090915a.jpg&hash=6f4b6daa9cd534cfbaef361a78a90d98101ad63f)

The road surfaces and tunnel entrances are exactly the same and unremarkable.  The gridsquares over the tunnel path are no different from adjacent undeveloped gridsquares.

Oh, well...


David
Title: Re: Query.txt
Post by: Korot on September 15, 2009, 11:00:12 AM
Why don't you have a tunnel entrance there, dedgren?

Regards,
Korot
Title: Proposal on Edge Density Matrix
Post by: sumwonyuno on September 15, 2009, 07:16:19 PM
RippleJet your knowledge is very helpful and you've pretty much explained all of those data entries.

dedgren, I guess that's another way as well.  Also, I wasn't expecting tunnels, bridges, neighbor connections to provide further data entries.

RippleJet, z, BarbyW, and everyone else interested in edge matrices, I think I've figured it out.

[long explanation about to happen and it's about math &smrt]

As background, the graph from z's explanation is from graph theory.  For the function G(V, E), V is the set of vertices of graph G, and E is the set of edges among the graph G that connects two different vertices or loop back onto a vertex.  V1 and V2 are two sets of vertices that are subsets of V.  Cardinality is just the amount of elements in a set.

The edge density function, d(V1, V2), is in z's post.  It can be translated to:
the edge density of two sets of vertices = (the number of edges between the two sets) / ((number of elements in first set)*(number of elements in second set))

So how does this fit in the game?  What do the vertices and edges represent?

I've come to believe that an edge is one unit of traffic on a network (e.g. a single bus rider, a single car).  The set of vertices are directions:  west, north, east, south.  That particular ordering of the cardinal directions will make sense in a bit.  West corresponds to v1, the first element of V1 and V2.  North is the second element, east is the third, south is the fourth.  These directions are for a single 16m x 16m game tile.

V1 is the first input in the edge density function and it corresponds to the horizontal columns of the matrix.  V2 corresponds to the vertical rows.  So it forms this matrix:

   W N E S
W _ _ _ _
N _ _ _ _
E _ _ _ _
S _ _ _ _

I'm predicting that V1 signifies ending direction (a.k.a. "to").  V2 signifies starting direction ("from")  So something in column 3, row 1 corresponds to the east side of the tile, from the west side.  This matches what I was suspecting earlier ([3,1] is eastbound through traffic).  So for [1,3] it's to west, from east, a.k.a. westbound through traffic.  The edge density function d(V1, V2) is then read as to V1, from V2.  The way of saying it is similar to assembly language (i.e. mov ax, bx means move to ax from bx).

I am predicting that there won't be a value other than 0 for when the directions of V1 and V2 are the same (the diagonal from top left to bottom right), because that would imply traffic can go back to the side that it came from.  So, there are no looping edges.

To answer how this fits in the game, I believe it's tied in with the route query.  The route query tool is not just reporting numbers, it's shows visual arrows as well.  It would be very difficult to implement a city-tile-wide route marking system.  It's easier to show the route paths for a single game tile, then apply that algorithm across all game tiles.  So the route query algorithm takes the information from the edge density matrix to draw the edges (single units of network traffic).




[Edit wording to standardize notations and continued]

For values in the matrix, only a single pair of vertices (v1, v2) is considered.  The edge density function will still work for single elements of the subset:

For example, a single road with 3000 cars (to east, from west) should have 3000 edges at [3, 1]:

d([v1, v2]) = num. of edges btwn. the two vertices/((num. of elements in v1) * (num of elements in v2))
d([3, 1]) = 3000/((1) * (1))
d([3, 1]) = 3000
Title: Re: Query.txt
Post by: z on September 15, 2009, 09:19:54 PM
Thanks for a great explanation, sumwonyuno.  It's very clearly written, and it really does make a lot of sense.  :thumbsup:
Title: Re: Query.txt
Post by: RippleJet on September 16, 2009, 01:48:29 AM
Quote from: z on September 15, 2009, 09:19:54 PM
Thanks for a great explanation, sumwonyuno.  It's very clearly written, and it really does make a lot of sense.  :thumbsup:

I concur! :)
Title: Re: Query.txt
Post by: daeley on September 16, 2009, 06:02:03 AM
Quote from: Korot on September 15, 2009, 11:00:12 AM
Why don't you have a tunnel entrance there, dedgren?

Regards,
Korot

he does ;)
Title: Re: Query.txt
Post by: Korot on September 16, 2009, 06:41:17 AM
Quote from: daeley on September 16, 2009, 06:02:03 AM
he does ;)

No visible ones. I'm willing to believe that there is a tunnel, but the standard entrance isn't there, just the water bug texture. BTW: I see that the Real-Road uses the standard road to tunnel, without a conversion, so it has been decided that the real road will use the road network?

Regards,
Korot

Edit: 200th post.
Title: Re: Query.txt
Post by: sumwonyuno on September 17, 2009, 10:52:21 PM
Thanks very much, I'm glad that my explanation was clear and understandable enough for you all.  From testing in the Capitalis region, the results of query-clicking arbitrary transportation network tiles are matching my predictions, so far.  Though, there mods that I simply haven't implemented in my region, and anyone's welcome to confirm/disprove my research with Query.txt.

Now, what's this "Real-Road"?  I noticed the lack of tunnel lots in dedgren's post, and the road texture is much more detailed than the Maxis ones.
Title: Re: Query.txt
Post by: HeinBloed4711 on October 30, 2009, 08:19:56 AM
I'm glad I found this thread, I've always been interested in more detailed information regarding lots. :)

Unfortunately, this also allowed me to discover a bug that I wasn't aware of yet. But being a newbie to SC4 (relatively speaking), it may be well known already by the community.

Here's an example of a Medical Clinic Query.txt:


|-----------------------------------------------------------
| Query info for cell (177, 176) on 12/17/2123
|-----------------------------------------------------------
| Lot: (177, 176) 1x2, east-facing, state: occupied new, configuration: CV1x2_UrgentCareClinic_0311_2a2735a0
| Jobs $1,0 $$6,0 $$$1,0 - Travel Jobs $1 $$6 $$$0
| Building: CV12x14_urgentcareclinic_0311 $$
| Occupancy--building (tract):
| Zoned: Plopped Bldg
| Altitude: 275,8
| Land value, intrinsic: 13, total: 255 (High)
| Slope: 0,4
| Powered: yes
| Watered: yes
| Traffic Volume: 0   Traffic Congestion: 0
| Edge Density Matrix for travel type 0 (total = 0):
| Edge Density Matrix for travel type 1 (total = 0):
| Edge Density Matrix for travel type 2 (total = 0):
| Edge Density Matrix for travel type 3 (total = 0):
| Edge Density Matrix for travel type 4 (total = 0):
| Edge Density Matrix for travel type 5 (total = 0):
| Edge Density Matrix for travel type 6 (total = 0):
| Edge Density Matrix for travel type 7 (total = 0):
| Edge Density Matrix for travel type 8 (total = 0):
| Edge Density Matrix for travel type 9 (total = 0):
|-----------------------------------------------------------

Notice the difference of R$$$ jobs between the reported, fractional-number capacity and the jobs actually offered. That single chief medic just isn't there.

Now an IH (mega) lot:

|-----------------------------------------------------------
| Query info for cell (132, 123) on 10/21/2007
|-----------------------------------------------------------
| Lot: (134, 124) 4x4, east-facing, state: occupied new, configuration: I-ht3_4x4_90000880
| Jobs $28,1 $$224,8 $$$28,1 - Travel Jobs $64 $$524 $$$0
| Building: IH54x42_3HTAnchor11_0835, 284 $$$
| Occupancy--building (tract): Ih 99% (100%),
| Zoned: Il
| Altitude: 280,1
| Land value, intrinsic: 13, total: 255 (High)
| Slope: 5,6
| Powered: yes
| Watered: yes
| Traffic Volume: 48   Traffic Congestion: 0
| Edge Density Matrix for travel type 0 (total = 0):
| Edge Density Matrix for travel type 1 (total = 0):
| Edge Density Matrix for travel type 2 (total = 0):
| Edge Density Matrix for travel type 3 (total = 0):
| Edge Density Matrix for travel type 4 (total = 0):
| Edge Density Matrix for travel type 5 (total = 0):
| Edge Density Matrix for travel type 6 (total = 0):
| Edge Density Matrix for travel type 7 (total = 0):
| Edge Density Matrix for travel type 8 (total = 0):
| Edge Density Matrix for travel type 9 (total = 0):
|-----------------------------------------------------------

The "Travel Jobs" are a lot higher here because they include all the jobs of the industry mega lot. But, again, no R$$$ jobs!

One more example, this time a single IH zone:

|-----------------------------------------------------------
| Query info for cell (135, 208) on 2/16/2123
|-----------------------------------------------------------
| Lot: (136, 209) 3x3, east-facing, state: occupied new, configuration: I-ht2_3x3_90000820
| Jobs $14,8 $$118,4 $$$14,8 - Travel Jobs $15 $$118 $$$0
| Building: IH28x40_2HTAnchor6_0867, 156 $$$
| Occupancy--building (tract): Ih 95% (100%),
| Zoned: Ih
| Altitude: 289,7
| Land value, intrinsic: 22, total: 255 (High)
| Slope: 3,2
| Powered: yes
| Watered: yes
| Traffic Volume: 255   Traffic Congestion: 0
| Edge Density Matrix for travel type 0 (total = 0):
| Edge Density Matrix for travel type 1 (total = 0):
| Edge Density Matrix for travel type 2 (total = 0):
| Edge Density Matrix for travel type 3 (total = 0):
| Edge Density Matrix for travel type 4 (total = 0):
| Edge Density Matrix for travel type 5 (total = 0):
| Edge Density Matrix for travel type 6 (total = 0):
| Edge Density Matrix for travel type 7 (total = 0):
| Edge Density Matrix for travel type 8 (total = 0):
| Edge Density Matrix for travel type 9 (total = 0):
|-----------------------------------------------------------

See the pattern...?

I continued the research and found that most of my IH mega lots offered no R$$$ jobs. Not all of them however, here's an example for one that does offer them:

|-----------------------------------------------------------
| Query info for cell (55, 199) on 4/23/2123
|-----------------------------------------------------------
| Lot: (56, 200) 4x5, east-facing, state: occupied new, configuration: I-ht3_4x5_90000860
| Jobs $26,7 $$213,6 $$$26,7 - Travel Jobs $78 $$626 $$$48
| Building: IH54x42_3HTAnchor11_0835, 284 $$$
| Occupancy--building (tract): Ih 94% (100%),
| Zoned: Ih
| Altitude: 268,8
| Land value, intrinsic: 10, total: 255 (High)
| Slope: 1,3
| Powered: yes
| Watered: yes
| Network: Pipe W E
| Traffic Volume: 156   Traffic Congestion: 0
| Edge Density Matrix for travel type 0 (total = 0):
| Edge Density Matrix for travel type 1 (total = 0):
| Edge Density Matrix for travel type 2 (total = 0):
| Edge Density Matrix for travel type 3 (total = 0):
| Edge Density Matrix for travel type 4 (total = 0):
| Edge Density Matrix for travel type 5 (total = 0):
| Edge Density Matrix for travel type 6 (total = 0):
| Edge Density Matrix for travel type 7 (total = 0):
| Edge Density Matrix for travel type 8 (total = 0):
| Edge Density Matrix for travel type 9 (total = 0):
|-----------------------------------------------------------

However, even here something must be wrong because the number of R$ jobs should equal the number of R$$$ jobs.

Maybe this is an explanation for the oh-so-many no job zots on our beloved R$$$ zones...? I haven't examined this any further yet because I'm worried I've only rediscovered something that was already well known, or that I overlooked another variable. Otherwise, it should be tested if this could be due to a rounding error, see what happens when you change the jobs offered by IH to 0/80%/20% (R$/R$$/R$$$) etc. etc.

Oh, and it's not just an error with the detailed queries, when I cut off the regional network access of a small settlement with a single R$$$ zone so there was only access to (lots of) IH zones, it didn't take long before the R$$$ zone was abandoned after finding no jobs (whereas all the R$$ residents happily worked at the IHs).
Title: Re: Query.txt
Post by: sumwonyuno on October 30, 2009, 01:49:20 PM
I can't really infer much about the rest of your city tile/region from the information that you've given.  Filling those "high-level positions" isn't actually necessary in my experience, but they are required to have if you want your R$$$ Sims employed (and not abandon their homes).

QuoteHowever, even here something must be wrong because the number of R$ jobs should equal the number of R$$$ jobs.

Maybe this is an explanation for the oh-so-many no job zots on our beloved R$$$ zones...? I haven't examined this any further yet because I'm worried I've only rediscovered something that was already well known, or that I overlooked another variable. Otherwise, it should be tested if this could be due to a rounding error, see what happens when you change the jobs offered by IH to 0/80%/20% (R$/R$$/R$$$) etc. etc.

Oh, and it's not just an error with the detailed queries, when I cut off the regional network access of a small settlement with a single R$$$ zone so there was only access to (lots of) IH zones, it didn't take long before the R$$$ zone was abandoned after finding no jobs (whereas all the R$$ residents happily worked at the IHs).

Actually, no, the number of R$ jobs should always be much greater than the number of R$$$ jobs.  That's how all lots' jobs are worked out to be.

I think I've had an epiphany for my region by answering your question, HeinBloed4711.   :)

Someone correct me if I'm wrong, but I understand the game finds what is the closest available job to a residential building and sees if a path exists between those two.  So, for your layout, that industrial area that you want the R$$$ to go to isn't the closest job available.  That path that you've demolished leads to the closest job, so the game can't find a path, and the R$$$ house abandons.
Title: Re: Query.txt
Post by: HeinBloed4711 on October 30, 2009, 03:05:08 PM
Quote from: sumwonyuno on October 30, 2009, 01:49:20 PM
I can't really infer much about the rest of your city tile/region from the information that you've given.  Filling those "high-level positions" isn't actually necessary in my experience, but they are required to have if you want your R$$$ Sims employed (and not abandon their homes).

Actually, no, the number of R$ jobs should always be much greater than the number of R$$$ jobs.  That's how all lots' jobs are worked out to be.

I think I've had an epiphany for my region by answering your question, HeinBloed4711.   :)

Someone correct me if I'm wrong, but I understand the game finds what is the closest available job to a residential building and sees if a path exists between those two.  So, for your layout, that industrial area that you want the R$$$ to go to isn't the closest job available.  That path that you've demolished leads to the closest job, so the game can't find a path, and the R$$$ house abandons.

I beg to differ. ;)

I think you're wrong here (I'm pretty sure actually): While it's true that overall the game is balanced so that the number of R$$$ jobs is inferior to that of R$ jobs (more or less), the relevant variable for determining the share of each job category in a given lot is the census drive, as explained here: http://sc4devotion.com/forums/index.php?topic=963.0. I've also checked it with C buildings by the way, and the given proportion of jobs holds perfectly there, for every category from C$ to CO$$$. And not just that, for IH the number of R$ and R$$ jobs is correct according to the 10/80 share too, it's just that most of the time, the R$$$ jobs are completely missing. And this is true for the medical clinic as well. As I said, I haven't tested any further yet, but my prime candidates would be IM and other civic buildings.

Regarding my example; of course you couldn't know my layout, but I assure you that the (non-existant) R$$$ jobs at the IH zone would have been much closer to go. Here's a screenshot that should give you the idea: (red the R$$$ lot, green the IH, and yellow where the R$$$ inhabitants commute to)

(https://www.sc4devotion.com/forums/proxy.php?request=http%3A%2F%2Fimg21.imageshack.us%2Fimg21%2F2259%2Frhighjob.jpg&hash=ed1b10b5fbaef0e408fa07f1e4bdcf280d2caae2) (http://img21.imageshack.us/i/rhighjob.jpg/)

(https://www.sc4devotion.com/forums/proxy.php?request=http%3A%2F%2Fimg5.imageshack.us%2Fimg5%2F963%2Frmedjob.jpg&hash=60f36a8b46fe2c8c493d2cd555bcd5b0aa13f162) (http://img5.imageshack.us/i/rmedjob.jpg/)

(https://www.sc4devotion.com/forums/proxy.php?request=http%3A%2F%2Fimg20.imageshack.us%2Fimg20%2F6618%2Fjobgone.jpg&hash=f21a4098eea26e30c3e685f982393f820b448070) (http://img20.imageshack.us/i/jobgone.jpg/)

Just to be 100% sure that the higher speed of the highway doesn't make it so the required time to the upper lot is actually shorter, I completely erased the upper commerce region. The result didn't change, quickly the no job zot appeared. I should also add that the query.txt always seems to accurately reflect the number of offered jobs for every lot, regardless if those are filled by commuters or not - therefore I'm convinced those R$$$ jobs in the IH lot simply aren't there. Please go ahead and test for yourself. I'm afraid this has to be a game bug. :(
Title: Re: Query.txt
Post by: z on October 30, 2009, 03:13:06 PM
Quote from: HeinBloed4711 on October 30, 2009, 08:19:56 AM
Maybe this is an explanation for the oh-so-many no job zots on our beloved R$$$ zones...?

Although it's possible that this is part of the problem, I have recently discovered a much more general cause, which affects users of all traffic simulators other than the latest beta version (v1.2) of Simulator Z.  You can read about it in this post (http://sc4devotion.com/forums/index.php?topic=5382.msg283986#msg283986).

Quote from: sumwonyuno on October 30, 2009, 01:49:20 PM
Someone correct me if I'm wrong, but I understand the game finds what is the closest available job to a residential building and sees if a path exists between those two.  So, for your layout, that industrial area that you want the R$$$ to go to isn't the closest job available.  That path that you've demolished leads to the closest job, so the game can't find a path, and the R$$$ house abandons.

That's not quite how it works.  The simulator looks for a suitable job with the same wealth level as the residential Sim, and then attempts to find the shortest path between them.  If it can't find any within a certain time limit, then it gives up, and the R$$$ house abandons.  It doesn't always look for a path to the closest available job, as that job may have already been filled earlier in the pathfinder's current run.  And the pathfinder can't really define "closest" completely accurately until it's constructed a path.  At that point, if it's a valid path, the pathfinder takes it, and the Sim has a job.  Otherwise, the pathfinder keeps looking until it either runs out of time or available jobs.

There may very well be an extra step in here where the pathfinder decides which jobs to check out by estimating their closeness; I would actually think this likely.  For example, it could do a quick calculation of the Euclidean distance and use that as an estimate.  And it probably also does some caching of distances between residences and jobs, as this would save it a lot of time.  But there's no way for us to know either of these things for sure without seeing the source code.
Title: Re: Query.txt
Post by: SC4BOY on October 30, 2009, 04:32:05 PM
Without any supporting evidence other than years of observation, I'm pretty sure the simulator completely ignors "path distances" I believe all it's measures are strictly "as the crow flies". That, for example, is one reason it so frequently sends workers to other city tiles instead of just using the jobs in the city its in.. AFTER it decides on the "work destination" as you hint of above, THEN it tries to get there.. and it can go a VERY CIRCUITOUS ROUTE to get there..

Edit: By this I'm referring to the "closest" job.. of course I realize the simulator DOES measure distance (time actually or ticks or steps.. whatever you want to call them..) on the trip itself.. although it is well documented that it makes some VERY ODD decisions in some cases.. :)
Title: Re: Query.txt
Post by: HeinBloed4711 on October 30, 2009, 04:45:19 PM
Ok, here's a little update:

I tested IM first, which created even more confusion. In contrast to IH, the number of R$$$ jobs is correct according to the census drive much more often, almost always. BUT I found a few mega lots that seemed to offer some more than the expected 5%, only a handful like 5-10 jobs though. This is true only if the number of R$ was still right for those (I only checked if R$=10*R$$$, since the proportion should be 50/45/5%) - however this seems more likely to me than not, because the relation of 50/45 between R$ and R$$ was still correct for those lots.

Then I went through all civic buildings. Apart from the medical clinic, I found the solar power plant to completely lack the 10 R$$$ jobs. And to make my confusion complete, the nuclear power plant has the right number of R$$$ jobs, BUT it lacks the 20 R$$ jobs. &sly

I also tried to find a pattern behind the affected IM/IH mega lots, but couldn't find one. :(

I'd be very grateful for someone else testing and confirming my findings.

Update: just made a quick run with a new city and all my plugins (except the SimCity 4 Extra Cheats Plugin.dll) removed - same result
Title: Re: Query.txt
Post by: sumwonyuno on October 30, 2009, 06:36:58 PM
Well, my assumptions have been corrected.  I know less about demand and census drives compared to the traffic simulator. 

HeinBloed4711, I agree industry lots are buggy and I've basically just avoided industry as much as possible to provide jobs in my region.  So now that I've seen your city layout, I understand.  The game does not follow what's logical to us.  For whatever reason, many jobs in large industrial areas are not taken.  There are also the quirks where there are more commuters going to a job building than there are jobs available in that building (as seen in your query.txt examples).  I've had your issues happen to me as well, but I really haven't bothered with it (other issues are more important to me).  I hope that both of us will get answers.

z, I lacked the specificity in my post; I did mean appropriate jobs.  So now my understanding is commuters go to the closest, available and appropriate job that is within the maximum commute time.
Title: Re: Query.txt
Post by: HeinBloed4711 on October 30, 2009, 07:11:14 PM
Quote from: sumwonyuno on October 30, 2009, 06:36:58 PM
For whatever reason, many jobs in large industrial areas are not taken.

Excuse my hairsplitting, but I think we need to be precise here in order not to leave any misunderstandings ;): those jobs you mention don't just not get taken, from the game engine's view they're simply not there to be taken (talking about the R$$$ jobs in IH zones). I'll keep stating that at least as long as someone proves the opposite. ;) And if you want to verify this: Make sure not to test just one lot, but do it for a few ones, since, as I said, one of my many IH mega lots did have those R$$$ jobs.

In the meantime, I modded the large medical center to offer 1/6/1 (R$/R$$/R$$$) jobs, just like the small medical clinic. And guess what, it came up as 1/6/0 jobs, too. Then I went on to mod it to 1/6/2 jobs, result: 1/6/2 ! Final test was 2/6/1, result 2/6/1 ! This makes me quite confident there's some sort of rounding error going on, at least for the civic buildings (haven't tested with solar and nuclear power plant yet). I'm worried the same is true for the industry mega lots. Once again, none of the C$-CO$$$ lots are affected.

Maybe I can do more testing tomorrow, bedtime now.
Title: Re: Query.txt
Post by: sumwonyuno on October 30, 2009, 07:58:59 PM
All right, I don't have evidence to refute what you're getting at.  I demolished part of my industrial district and then the mega high tech lots came in.


...
| Jobs $1385.2 $$11081.6 $$$1385.2 - Travel Jobs $1385 $$11136 $$$0
| Building: I-HT 10 N.Ass.T.I.  Nanotech, 14854 $$$
...



...
| Jobs $556.5 $$4452.0 $$$556.5 - Travel Jobs $556 $$4502 $$$0
| Building: I-HT 10 Integriculture HiRise Farm, 6146 $$$
...


Well, I can understanding rounding errors, for one R$$$ job (the game might be using a floor function), but it makes no sense for hundreds of possible R$$$ jobs.

On another note, I found a lot that's different with all the other queries I've done.  It probably has to do with the types of industrial buildings (anchor, mech, out).


|-----------------------------------------------------------
| Query info for cell (147, 143) on 9/25/2822
|-----------------------------------------------------------
| Lot: (149, 145) 5x5, east-facing, state: occupied new, configuration: IHT$$$9_5x5_gc_KelvinColdStorage_04052954
| Jobs $172.0 $$1376.0 $$$172.0 -> (142, 145)
| Building: I-HT 9 Kelvin Cold Storage, 1746 $$$
| Occupancy--building (tract): Ih 99% (100%),
| Zoned: Ih
| Altitude: 270.0
...
Title: Re: Query.txt
Post by: HeinBloed4711 on October 31, 2009, 06:25:58 AM
Quote from: sumwonyuno on October 30, 2009, 07:58:59 PM
On another note, I found a lot that's different with all the other queries I've done.  It probably has to do with the types of industrial buildings (anchor, mech, out).


|-----------------------------------------------------------
| Query info for cell (147, 143) on 9/25/2822
|-----------------------------------------------------------
| Lot: (149, 145) 5x5, east-facing, state: occupied new, configuration: IHT$$$9_5x5_gc_KelvinColdStorage_04052954
| Jobs $172.0 $$1376.0 $$$172.0 -> (142, 145)
| Building: I-HT 9 Kelvin Cold Storage, 1746 $$$
| Occupancy--building (tract): Ih 99% (100%),
| Zoned: Ih
| Altitude: 270.0
...


Yes, I saw those too. When I was talking about mega lots, what I meant are those clumped together industry lots that act as a single lot to the outside, aggregating their incoming and outgoing traffic on a single "anchor" lot. I used that term in this context because I thought I had read it once, but I could be way off. Anyway, the lot you pasted there is part of such a mega lot, imho, since all the lots I saw with that output were. In the line "| Jobs $172.0 $$1376.0 $$$172.0 -> (142, 145)" the coordinates in the parentheses are those of the "anchor" lot (i.e. where this lot sends its jobs so they're available for commuting sims).




Important update: Ok, I've got some relatively good news. After I had tried adjusting various parameters in different exemplars, I arrived at the IH Census exemplar. Here's the original property that sets the number of jobs to 10/80/10%:

Drives 0x47BB3F30 Uint32 10 0x00002010,0x0000000A,0x00002020,0x00000050,0x00002030,0x0000000A,0x00004C00,0x00000064,0x00004900,0x00000064


Since I still thought that there might be some sort of rounding error at work here, I tried to vary the job proportions, leaving the total at 100. 10/79/11 was much better already insofar as I did finally get those R$$$ jobs, however not as many as I expected but often still only ~2/3 of the number of R$ jobs. So basically, the calculated numbers were still way off. Then I tried with 10/78/12, and what can I say - this seems to do the trick. In all my testing so far, the relation between $/$$/$$$ holds perfectly, the total number of jobs seems to match the total number of jobs reported by the normal query, and, as a result of all that, I quickly convinced my R$$$ citizens to work at those newly created jobs much closer to them, without having to force them by cutting off the connection first ;)

(https://www.sc4devotion.com/forums/proxy.php?request=http%3A%2F%2Fimg265.imageshack.us%2Fimg265%2F7936%2Fnewjobs1.jpg&hash=cbf1ca7200644042100848ace5247cea9c4fb057) (http://img265.imageshack.us/i/newjobs1.jpg/)

(https://www.sc4devotion.com/forums/proxy.php?request=http%3A%2F%2Fimg256.imageshack.us%2Fimg256%2F7418%2Ffinallyrhighjobs.jpg&hash=36d5afad2f599c020528cf7fe2f6b7103dbc8bd8) (http://img256.imageshack.us/i/finallyrhighjobs.jpg/)


Basically, for me the case is clear now that there's a (rounding/arithmetic) bug in the engine that leads to a wrong number of jobs in certain constellations (like that 10/80/10 default drive for IH). Seeing the chance of an official bugfix as non-existant, the best one can do to deal with this is to use a modified IH census that stays true to the game as much as possible - hence only the smallest modification possible. I rather have 20% more R$$$ jobs in my IH and 2.5% less R$$ jobs compared to how the game was originally designed than not have any R$$$ jobs at all.

You may be thinking "so what, it's only 10% of the IH jobs missing anyway", but think about this example: I have one city that now has about 45,000 IH jobs. So, this city lacked a total of ~4,500 R$$$ jobs, which equals a R$$$ population of about 8,000-9,000 (depending on the life expectancy). This is quite a large number, and I don't even have IH maxed out at all. Not having those jobs also means that the R$$$ population, which was STILL created by the IH census drive needs to look for those missing jobs elsewhere, which leads to all sorts of problems (traffic...). I didn't fully think through this yet, but I reckon that ultimately this lack of jobs led to an inherent imbalance in the game, because you can only satisfy the need for R$$$ jobs with CS$$-CO$$$ until a certain level before you definitely need some IH jobs. This is a complicated subject though with several influencing variables (workforce EQ, life expectancy...) Until now, I dealt with this problem by raising R$$$ tax in order to cut down demand.

What I'll do now is some more testing with the 10/78/12 census drive, possibly a few other ratios, then test IM and iron the (much smaller) observed error out there too. Then I can post a small .dat file containing the adapted census drives as a fix.
Title: Re: Query.txt
Post by: SC4BOY on October 31, 2009, 09:12:17 AM
Very good work there.. thanks for checking it out.. In terms of "breaking the model" it won't do that as each residential class $ $$ $$$ adds to over 100.. but nontheless your point is excellent and helps explain why Industry become such a weak factor as you try to grow very large cities.. you have to do it almost totally on Commercail which you shouldn't have to do..

The rounding is very odd.. wonder if its in decimal? (the display and entries I mean) I only say this because 12 is 1/8 of 100 rounded almost like octal.. but I guess that's kind of disproved by your other numbers.. I dunno...just seems really odd.. perhaps it is just a bug, but you'd think they would have noted that.. hehe

Will continue to follow your investigations!
Title: Re: Query.txt
Post by: HeinBloed4711 on October 31, 2009, 10:41:24 AM
Ok, I left it at 10/78/12 for now. Apart from the inevitable rounding between "Jobs" and "Travel Jobs" (e.g. | Jobs $26,6 $$204,8 $$$31,9 - Travel Jobs $27 $$205 $$$32), the numbers seem to match the census drive now. As for IM, I decided to leave it alone because the few errors I observed with the default 50/45/5 drive only concerned R$$$, too, and were in the order of no more than 5 additional jobs, regardless of the lot size.

While I was at it, I tried to tweak the three ploppable buildings that I had found, i.e. the Medical Clinic, the Solar Power Plant, and the Nuclear Power Plant. I continuously added more jobs until the error was gone, here's a table that lists the changes (jobs $/$$/$$$):

BuildingProperty beforeerroneously created jobsProperty after (=created jobs)
Medical Clinic1/6/11/6/01/6/2
Solar Power Plant10/12/1010/12/010/12/12
Nuclear Power Plant20/20/820/0/820/23/8

I attached four single files (one for the IH census and one for each ploppable building) to this post, feel free to test and report your observations. ;)

(had uploaded them previously to http://www.mediafire.com/?sharekey=59d030429a5f92f00c814df2efeadc5039e94841451ff5c24ad239450a8c1cf1, in case there's a problem)

Quote from: SC4BOY on October 31, 2009, 09:12:17 AMIn terms of "breaking the model" it won't do that as each residential class $ $$ $$$ adds to over 100..
Yes that's true, and I've been wondering about that design decision for some time. Because what that effectively does is that it allows for unlimited expansion of basic demand (i.e. not the effective demand that is derived from that by applying demand caps, taxes...), if you make sure you have the right ratio of the various RCI types. I wonder if they introduced it after having tested the game and realizing this was necessary in order to overcome the flaws like the limited original traffic simulator (and the probably lesser effect of the missing IH R$$$ jobs). However, the simulation does need some slack to deal with the effects of EQ and life expectation.

It should be noted that using my IH census patch file, the game will effectively become "easier" because you will have more jobs available. But I don't feel this is some kind of cheat, because those jobs were meant to be there anyway, and they already created a certain demand for R$$$ zones, fully fulfilling which would probably have caused a lack of jobs, followed by abandonment. A city with IH that worked without this will get a sudden batch of additional available R$$$ jobs (which will NOT affect the existing demand in any way), which will lead to changes in traffic. Cities that didn't quite work out yet should (hopefully) experience less abandonment in R$$$ zones.

What this also means though, I'm afraid, is that theoretically every plobbable building can be concerned by this bug. I've checked all the default Maxis buildings already (I think, hopefully didn't forget any), but every user-made custom building should be verified really to be sure. :( The only true solution would be to fix it in the source code.


Update: Attached the files to this post after RippleJet kindly gave me the right to do so.
Update 2: LunarMongoose brought an error to my attention that slipped into the IH census; I had actually saved the exemplar with a 10/77/12 job ratio instead of 10/78/12, so 1% $$ jobs were missing. Please re-download the IH census file and overwrite the previous version with the contained dat file. Sorry for this.
Title: Re: Query.txt
Post by: SC4BOY on October 31, 2009, 04:04:36 PM
Aye.. no, I'd hardly see this as a "cheat".. Also I'd hope that as CAM 2.0 is IMMINENT *cough cough* that they will factor this into the "CAM" mod's.. its great that you're delving into this.. well worth the exploration
Title: Re: Query.txt
Post by: RippleJet on November 01, 2009, 10:43:21 AM
After coming home from a two-day business trip, I've now read through all this, HeinBloed, and I'm impressed at how much effort you've put on this so far.

What strikes me so far, is that your zeroes appear whenever two of the wealth categories are identical...


Especially the last case was the one catching my eyes here...


Quote from: HeinBloed4711 on October 31, 2009, 10:41:24 AM
Since I can't post attachements

You can now! :thumbsup:


Quote from: SC4BOY on October 31, 2009, 04:04:36 PM
Also I'd hope that as CAM 2.0 is IMMINENT *cough cough* that they will factor this into the "CAM" mod's..

*cough cough* ::)
Since almost all census exemplars are included and modded in the CAM, I will most certainly have to take this into consideration...
Title: Re: Query.txt
Post by: HeinBloed4711 on November 01, 2009, 11:08:19 AM
Quote from: RippleJet on November 01, 2009, 10:43:21 AM
What strikes me so far, is that your zeroes appear whenever two of the wealth categories are identical...


  • 10/80/10 becomes 10/80/0
  • 1/6/1 becomes 1/6/0
  • 10/12/10 becomes 10/12/0
  • 20/20/8 becomes 20/0/8

Especially the last case was the one catching my eyes here...

You're right, that's an interesting observation. I think I'll investigate into this one of the next days, atm I'm busy. If someone else wants to do it right now, please go ahead. :)
Title: Re: Query.txt
Post by: sumwonyuno on November 01, 2009, 01:11:00 PM
I've been following what you've been finding, and good investigating.   :thumbsup:  I've noticed that relation too (missing jobs for those equal percentages).  Though, it doesn't seem to be a purely on-off bug (when you change it by one percentage point, jobs are still missing).  You had to adjust two percentage points for the missing jobs to be fully available to the game.  I'm trying to think of what kind of programming error would lead to this canceling out (float arithmetic?).

I don't consider the modifications a cheat (rather we've been cheated), as these jobs were intended to be there in the first place.
Title: Re: Query.txt
Post by: z on November 01, 2009, 01:32:05 PM
Quote from: sumwonyuno on November 01, 2009, 01:11:00 PM
I don't consider the modifications a cheat (rather we've been cheated), as these jobs were intended to be there in the first place.

I agree completely - creating a workaround for a bug is not a cheat.
Title: Re: Query.txt
Post by: LunarMongoose on November 02, 2009, 01:47:32 AM
Speaking of bugs no one else noticed... The IH Census file you posted here and on Simtropolis *actually* reads 10-77-12 in the exemplar data... I assume you typo'd the hex value; 4D is 77. Should be 4E right? ;)
Title: Re: Query.txt
Post by: HeinBloed4711 on November 02, 2009, 05:09:18 AM
Quote from: LunarMongoose on November 02, 2009, 01:47:32 AM
Speaking of bugs no one else noticed... The IH Census file you posted here and on Simtropolis *actually* reads 10-77-12 in the exemplar data... I assume you typo'd the hex value; 4D is 77. Should be 4E right? ;)

You're so right, thanks a lot for this notification! Must have overlooked this while varying the values. &mmm I'll change it immediately and upload the fixed file.

The fixed, correct file is at http://sc4devotion.com/forums/index.php?topic=8870.msg284277#msg284277 now.
Title: Re: Query.txt
Post by: HeinBloed4711 on November 02, 2009, 06:42:25 AM
I've taken the time to run the outstanding tests now, here are the results:

First I modded the CO$$ census (to test a different RCI type than IH at the same time), like this:

job ratio set ($/$$/$$$)job ratio in game ($/$$/$$$)
40/50/10 (original Maxis values)40/50/10
40/40/2040/0/20
40/20/4040/20/0*
33/33/3333/0/0
20/40/4020/40/40
40/30/3040/30/30
*(actually, I got a mixture of 0(%) and an absolute value of 5-10 jobs, regardless of the lot capacity here, e.g. 5 $$$ jobs for a 1600 capacity tower, 0 $$$ jobs for a 20 capacity building etc.)


Then I tested ploppable buildings, this time for the same reasons as above the Large Medical Center:

jobs set ($/$$/$$$)jobs in game ($/$$/$$$)
35/53/11 (original Maxis values)35/53/11
35/35/1135/0/11
35/53/3535/53/0
35/35/3535/0/0
11/35/3511/35/35
----------------------------------------------------------------------------------------------------------
50/35/550/35/5
35/55/1035/55/10
50/45/550/0/5
45/50/545/0/5
100/90/10100/0/10
90/100/1090/0/10

The last batch of ratios was tested because I had observed that marginal absolute error of 5-10 jobs with a few IM lots - IM has a census drive of 50/45/5.

My conclusions: As RippleJet has guessed, any two or three identical numbers seem to cause the error reproducibly, however only when the $ jobs are part of this. This is the case for the RCI census drives (growables) AND ploppable buildings. There must be more "magical" ratios though, as at least 50/45/5 resp. 45/50/5 (and multiples of that) have shown to be faulty, too. This has to be some weird arithmetic calculation error in the code indeed. Since it doesn't happen when $ is different from $$ and $$$, maybe there's some rest of an arithmetic operation carried over to the following ones. &Thk/( Cries for an official patch anyway. BATers (and LOTers) should be aware of this bug and ideally test their ploppable buildings against it.
Title: Re: Query.txt
Post by: niloluiz on November 02, 2009, 11:14:45 AM
Hi folks,

I was just notified by HeinBloed that he "re-discovered" the "IHT bug" that I originally mentioned on the release of the RCImulti mod about 20 months ago (Mar-11-2008) on this simtropolis forum topic: http://www.simtropolis.com/forum/messageview.cfm?catid=41&threadid=97952&forumid=1 (http://www.simtropolis.com/forum/messageview.cfm?catid=41&threadid=97952&forumid=1).

The RCImulti also deals with job rebalancing among other things including "homejobs" (sims work at home). Please take a look at the above link as it contains the detailed description of all the mod features and the mod concepts involved in it's creation (most of it was already documented by RippleJet here on SC4dev before RCImulti release, which I wasn't aware at the time). Sorry for not properly posting this findings here on SC4dev at the time and kudos for HeinBloed for documenting the Jobs bug here and releasing a proper stand-alone mod for this issue.

Since Cities XL wasn't what many of us was expecting, modding of SC4 will probably continue for yet a long time and it's interesting to have all informations documented on the main SC4 forums.  :)

Also I received many requests to make RCImod "CAMpatible" which would require some changes to the CAM mod itself  but I would like to have the Cam's team approval/guidelines to eventually make this modification.
Title: Re: Query.txt
Post by: RippleJet on November 02, 2009, 11:34:36 AM
Hi Nilo, and welcome to Devotion! :)
Let me first tell you I'm sorry nobody at first said anything in your thread where you first introduced your RCImulti mod.

I must confess that I myself didn't see your mentioning about the "IHT bug" either...
I had to go back and reread your thread over there...

Quote from: niloluiz at http://www.simtropolis.com/forum/messageview.cfm?catid=41&threadid=97952&forumid=1
BUG: The game engine have a BUG that prevents the JOBS$$$ and JOBS$ for Industry Hi-tech for being created. If you ever wonder why wealth sims ($$$) NEVER work on IHT building, now you know why. This bug occours when you try to use(when modding the game)  similar % for each JOB type. Since the default game specs dictate 10% for BOTH JOBS$ and JOBS$$$ on IHT industry, the game engine will truncate theses values and will generate noone.

Kudos to you for finding this already back then! :thumbsup:

Regarding RCImulti and CAM... maybe you'd want to take part in the development of CAM 2.0? :)
Title: Re: Query.txt
Post by: RippleJet on November 02, 2009, 03:36:32 PM
Double-posting as this is not directly related to my previous post (I hope Steve comes and reads this...)

Quote from: HeinBloed4711 on November 02, 2009, 06:42:25 AM
BATers (and LOTers) should be aware of this bug and ideally test their ploppable buildings against it.

I needed to recheck the formulas for civic jobs as set by the "X Tool",
and luckily I have never given the same formulas for jobs$ as for jobs$$ and jobs$$$.

E.g. medical clinics and hospitals are given jobs by these (XML) formulas:

<eval name="CivicJobs" value="int(ceil(Patients/30.))"/>
<eval name="Jobs1" value="5+int(CivicJobs*1./5.)"/>
<eval name="Jobs2" value="2+int(CivicJobs*3./5.)"/>
<eval name="Jobs3" value="0+int(CivicJobs*1./5.)"/>

The rare case when Jobs1 = Jobs2 = 6 ( when CivicJobs are 7 or 8 ) can probably be looked over,
as that would correspond to a patient capacity of only 181...240.

Ingame civic buildings should be recalculated with the "X Tool" for CAM 2.0 though... ::)
Title: Re: Query.txt
Post by: wouanagaine on November 02, 2009, 11:52:51 PM
Ha, your last post is a relief Ripplejet, I was thinking I'll need to create a special case, but hopefully you already did it right from the first time :)

Very nice and detailled information in this thread

Title: Re: Query.txt
Post by: niloluiz on November 03, 2009, 06:19:21 AM
Quote from: RippleJet on November 02, 2009, 11:34:36 AM
Hi Nilo, and welcome to Devotion! :)

Thanks man  :)

Quote
Let me first tell you I'm sorry nobody at first said anything in your thread where you first introduced your RCImulti mod.

I must confess that I myself didn't see your mentioning about the "IHT bug" either...
I had to go back and reread your thread over there...

Yeah I should've made a better job of making that info available.The simtrop mod forum was already "quiet" at the time I made that post so there wasn't any followup to the info posted there. I was also "switching off" from SC4 and so didn't finish the divulgation process.

QuoteRegarding RCImulti and CAM... maybe you'd want to take part in the development of CAM 2.0? :)

That would be interesting and I would be glad to partcipate in any way I can  :)
Title: Re: Query.txt
Post by: RippleJet on November 04, 2009, 11:09:17 AM
Quote from: niloluiz on November 03, 2009, 06:19:21 AM
That would be interesting and I would be glad to partcipate in any way I can  :)

I've sent you a PM :)
Title: Re: Query.txt
Post by: SC4BOY on December 22, 2009, 04:45:43 AM
I puzzled over where to post this question, and this seems the best place. Is there a method to determine for each property type what the "equation" is for desirability?

The issue that caused this to come up was a person who had indicated he was having problems with his C growth being stymied and wanting to know how to get back growing. I advised him on some options, but he reported back that he made it go by putting hospitals and schools covering his C zones. I was a bit taken back by his statement. I was under the impression that those had zero effect on commer and industry.

How can I evaluate that without just making a test city? Are those "equations" known? I see the query text uses the "function" symbols as      f(x) or F(x.y) or f(x,y) etc. Is there mathmatical differentiation among those symbols? I assume there is. My guess was that "f()" is the mapping of the LOT DESIRE FACTORS (ie Co$, R$$ etc) to the TRACT DESIRE FACTORS, but I don't know.

edit: Hmm .. I found THIS POST (http://sc4devotion.com/forums/index.php?topic=8695.msg270854#msg270854) by RJ to show this for Industry. I assume your "source" is also known for each RCI lot type?
Title: Re: Query.txt
Post by: RippleJet on December 22, 2009, 05:22:05 AM
Quote from: SC4BOY on December 22, 2009, 04:45:43 AM
edit: Hmm .. I found THIS POST (http://sc4devotion.com/forums/index.php?topic=8695.msg270854#msg270854) by RJ to show this for Industry. I assume your "source" is also known for each RCI lot type?

Yes, the same information is available for all types of RCI in their corresponding developer exemplars in SimCity_1.dat,
through the following properties that map the factor into desirability:




Quote from: SC4BOY on December 22, 2009, 04:45:43 AM
The issue that caused this to come up was a person who had indicated he was having problems with his C growth being stymied and wanting to know how to get back growing. I advised him on some options, but he reported back that he made it go by putting hospitals and schools covering his C zones. I was a bit taken back by his statement. I was under the impression that those had zero effect on commer and industry.

Plopping a civic building provides transient aura effect (http://sc4devotion.com/forums/index.php?topic=5282.msg171031#msg171031) in the area.


Title: Re: Query.txt
Post by: SC4BOY on December 22, 2009, 02:45:11 PM
hmm, and I assume that even though the factors are constant for every type, that the effects of those factors will vary as you look at each RCI type. Do all RCI types map to the same 0-255 value? or do they all map the same, but the levels just change for each lot type? By that I mean that if a given tract will have an absolute number for desirability, but the decision will be compared to different criteria when the game decides to see which type lot actions to take. Or does the desirability for each type actually change as you look at each RCI type?
Title: Re: Query.txt
Post by: cogeo on November 22, 2012, 02:59:59 AM
Hi all,

I have a question: How do you open Query.txt?

If opened in Notepad it doesn't look right, text lines are joined, obviously due to Query.txt using LFs to end lines, instead of CR-LF required by Windows. The only way to display the file correctly (using a commonly available program) is open IE and drag-and-drop it on its client area. However this is extremely inconvenient, as you have to open Windows Explorer, move to the Pragrams\Simcity folder, open IE (which alone may take a lot of time, if the system is loaded, eg if Simcity is running) and perform the drag-and-drop operation. Any alternative please?
Title: Re: Query.txt
Post by: jondor on November 22, 2012, 03:29:14 AM
I use something competent and capable of handing different styles of line endings.

Either Textpad (http://www.textpad.com/) or Notepad++ (http://notepad-plus-plus.org/) are excellent choices.
Title: Re: Query.txt
Post by: cogeo on November 22, 2012, 07:35:06 AM
Thanks for the reply.
Those programs are fine, however they are full-blown editors. I wanted some more basic, with a minimal memory req. footprint (so that it loads immediately), so I'm rather going to make something of my own.
Title: Re: Query.txt
Post by: Lowkee33 on November 22, 2012, 07:51:15 AM
Faster than notepad++?  Perhaps command prompt  > type query.txt
Title: Re: Query.txt
Post by: Swordmaster on November 22, 2012, 08:53:58 AM
I have no idea what Query.txt is, but I use ConTEXT for text editing.

Cheers
Willy
Title: Re: Query.txt
Post by: catty on November 22, 2012, 09:04:14 AM
I use wordpad which comes standard on any Windows computer and you can have your computer default to opening a txt file using wordpad

in wordpad it looks like this

Quote
|-----------------------------------------------------------
| Query info for cell (41, 63) on 8/11/2282
|-----------------------------------------------------------
| Lot: (41, 63) 1x1, north-facing, state: occupied new, configuration: Utils_RT_FL_Road_BusSub_0c9dd026
| Jobs $8.0 $$0.0 $$$0.0 - Travel Jobs $8 $$0 $$$0
| Building: Ut_RT_FL_Road_BusSub
| Occupancy--building (tract):
| Zoned: Plopped Bldg
| Altitude: 270.0
| Land value, intrinsic: 12, total: 255 (High)
| Slope: 0.0
| Powered: yes
| Watered: yes
| Network: Road N S
| Network: Subway W
| Network: Pipe N S
| Traffic Volume: 255   Traffic Congestion: 1
| Edge Density Matrix for travel type 0 (total = 941):
|   0   0   0   0       0   0   0   0
|   0   0   0 941       0   0   0   0
|   0   0   0   0       0   0   0   0
|   0   0   0   0       0 941   0   0
| Edge Density Matrix for travel type 1 (total = 0):
| Edge Density Matrix for travel type 2 (total = 0):
| Edge Density Matrix for travel type 3 (total = 0):
| Edge Density Matrix for travel type 4 (total = 0):
| Edge Density Matrix for travel type 5 (total = 0):
| Edge Density Matrix for travel type 6 (total = 410):
|   0   0   0  39       0   0   0   0
|   0   0 129 230       0   0   0   0
|   0   0   0   0       0 129   0  12
|   0   0  12   0      39 230   0   0
| Edge Density Matrix for travel type 7 (total = 0):
| Edge Density Matrix for travel type 8 (total = 794):
|   0   0   0   0       0   0   0   0
|   0   0   0 794       0   0   0   0
|   0   0   0   0       0   0   0   0
|   0   0   0   0       0 794   0   0
| Edge Density Matrix for travel type 9 (total = 0):
|-----------------------------------------------------------
Title: Re: Query.txt
Post by: toja on November 22, 2012, 10:07:10 AM
Quote from: cogeo on November 22, 2012, 07:35:06 AM
I wanted some more basic, with a minimal memory req. footprint (so that it loads immediately).

Notepad2 (http://www.flos-freeware.ch/notepad2.html) works fine for me.
Title: Re: Query.txt
Post by: cogeo on November 22, 2012, 11:04:04 AM
Thank you all for your replies and links!  :thumbsup:

@Swordmaster: You're in the right thread!  ;)

As mentioned above, I'm writing a small and lean view-only utility, with minimal resource requirements.
It should be ready by tomorrow.
Title: Re: Query.txt
Post by: cogeo on November 23, 2012, 02:16:34 PM
Hi again,

As said above, I finally made a small utility to display the Query.txt contents properly. It's a very lean program with minimal resource requirements, loading almost immediately, even when Simcity is running. It's stripped of any feature other than displaying a LF-terminated textfile. It's written in simple C and WinAPI, and has no dependencies like the MFC runtime, .NET or Java. You can download it from the attachment at the end of this post - it's too small in size (just 32KB) so it can be placed in an attachment.   ;)

Here is a screenshot:

(https://www.sc4devotion.com/forums/proxy.php?request=http%3A%2F%2Fimageshack.us%2Fa%2Fimg824%2F2672%2Fqueryvw.jpg&hash=f7facff54074b2e7bf07655c90b1a53573c27cc6)

Installation: Sorry, no installer, so you have to install it yourself. Take the following steps:
- Unzip the attachment and copy the file somewhere under your Programs folder, eg under C:\Program Files\Maxis\SimCity 4\Apps.
- The program has no menus (File->Open command), neither it supports drag-and-drop, instead it opens the file specified in the command-line. Therefore you have to create a shortcut, as described in the next steps.
- Right-click on the executable, select "Copy", and then go to your Desktop, right-click and select "Paste Shortcut".
- Rigth-click on the shortcut, select "Properties", go to the "Target" box and add Query.txt (full path) after the executable name, eg "C:\Program Files\Maxis\SimCity 4\Apps\QueryVw.exe" C:\Program Files\Maxis\SimCity 4\Query.txt
- Alternatively, you can omit the full path, eg "C:\Program Files\Maxis\SimCity 4\Apps\QueryVw.exe" Query.txt, but in this case you must put the path in the "Start in" box, eg "C:\Program Files\Maxis\SimCity 4"
- You can copy or move the shortcut to any other place, eg under the Programs Menu, if you want.

Uninstallation: The program doesn't write anything in the Registry or your Application Data folder, so if you want to uninstall it, all you need to do is delete the executable and the shortcut(s) you have created.

Enjoy!
Title: Re: Query.txt
Post by: BloodCat on March 25, 2013, 10:40:08 AM
Hi everyone!
There was a bug mentioned in this thread, the one making Medical Clinic demand less workers than it should. Is there a fix to make this right?
Title: Re: Query.txt
Post by: catty on March 25, 2013, 04:27:37 PM

Quote from: BloodCat on March 25, 2013, 10:40:08 AM
Hi everyone!
There was a bug mentioned in this thread, the one making Medical Clinic demand less workers than it should. Is there a fix to make this right?

Not as far as I'm aware and it affects more than the Medical Clinic, see this last post from RippleJet on the subject.

Quote from: RippleJet on November 02, 2009, 03:36:32 PM
Double-posting as this is not directly related to my previous post (I hope Steve comes and reads this...)

Quote from: HeinBloed4711 on November 02, 2009, 06:42:25 AM
BATers (and LOTers) should be aware of this bug and ideally test their ploppable buildings against it.

I needed to recheck the formulas for civic jobs as set by the "X Tool",
and luckily I have never given the same formulas for jobs$ as for jobs$$ and jobs$$$.

E.g. medical clinics and hospitals are given jobs by these (XML) formulas:

<eval name="CivicJobs" value="int(ceil(Patients/30.))"/>
<eval name="Jobs1" value="5+int(CivicJobs*1./5.)"/>
<eval name="Jobs2" value="2+int(CivicJobs*3./5.)"/>
<eval name="Jobs3" value="0+int(CivicJobs*1./5.)"/>

The rare case when Jobs1 = Jobs2 = 6 ( when CivicJobs are 7 or 8 ) can probably be looked over,
as that would correspond to a patient capacity of only 181...240.

Ingame civic buildings should be recalculated with the "X Tool" for CAM 2.0 though... ::)

-catty