數(shù)據(jù)預處理-link data and stack overflow

  1. 已有的數(shù)據(jù)用過沒有保存好,要用又要重新安裝,重新編程。非常麻煩。
  2. 下載源數(shù)據(jù)從這個網(wǎng)站:bstabler/TransportationNetworks
  3. net file已經(jīng)轉(zhuǎn)換好了。
  4. 下面是OD file
  5. 測試成功fopen_s and fscanf_s的用法
FILE *fp1, *WriteFile;
errno_t err,err2;//*difference
//difference is: err=fopen_s(&fp1....!=0
//critical: !=0
if ((err = fopen_s(&fp1,"C:\\net.txt", "r")) != 0) {
        printf("can not opennet.txt");
        getchar();
        return;
    }
int a = 0;
// fscanf_s....
fscanf_s(fp1, "%d", &a);
printf("%d\n",a);

C:\TEST\SourceNet\, put in the deeper folder, succeed
1 2 25900.20064 6 6 0.15 4 0 0 1 ;
input only one line, succeed
input two lines, succeed.
output is also succeed.
test the siouxfalls is also succeed.
test the whole 76 links, succeed.
so, the whole code is saved.

  1. SixousFalls completed, the next case is Anaheim
    we just need to set a parameter: how many links are there
    and change the file name
    succeed.
  2. the next case is Winnipeg, 2836 links
    succeed, also I see the memory, 1MB
  3. Chicago sketch 2950links
    succeed
    1 MB
  4. Austin 18961 links
    6000, 1.3MB
    10000,1.6MB
    12000,1.7
    14000, 1.9
    15000,stackoverflow
    stack 保留
    32768,1000,968kb
    2000,1mb
    3000,1.1mb
    5000, failed
    627680
    5000,1.3MB
    999999
    10000,1.6MB
    999999不是字節(jié),因為999999byte=976kb,小于1MB
    9999999
    15000,1.9mb
    18961,2.2mb
    succeed
    stack commit 嘗試999999沒用。
  5. next is Sydney net
    Sydney net has 75379 links
    9999999 7
    1000, 992kb
    5000,1.2MB
    10000,1.6MB
    15000,1.9mb
    18961,2.2mb, succeed
    20000,2.3mb
    25000,2.6mb
    30000,3.0mb
    35000,3.3mb
    40000,3.6mb
    45000,4.0mb
    50000,4.3mb
    55000,4.7mb
    60000,5.0mb
    65000,5.4mb
    70000,5.7mb
    75000,6.1mb
    75379,6.1mb,5500000
  6. Sydney net 完成輸入
    怎么調(diào)堆棧?屬性,連接器,系統(tǒng),保留大小。
  7. 75379 link,6.1mb,至少安排5500000的??臻g。
  8. Sydney(75379) txt file,3.4mb
最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時請結(jié)合常識與多方信息審慎甄別。
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點,簡書系信息發(fā)布平臺,僅提供信息存儲服務。

相關閱讀更多精彩內(nèi)容

友情鏈接更多精彩內(nèi)容