Search:

Type: Posts; User: Chris_1980

Page 1 of 4 1 2 3 4

Search: Search took 0.01 seconds.

  1. Thanks for the reply. Chris

    Thanks for the reply.

    Chris
  2. Lets say I have a structure: struct chromosome...

    Lets say I have a structure:
    struct chromosome { array[100]; fitness;}; struct chromosome old_chrome[100];
    And in a while loop the values of array are changed. In the loop in every iteration I...
  3. part of code that will not affect the rest of main()

    I am wondering if its possible to execute a part of code in main() that will not affect the rest of the execution. For example assign different values to variables that will be only valid inside a...
  4. Replies
    9
    Views
    1,771

    Again thanks to everybody. However I feel dummy...

    Again thanks to everybody. However I feel dummy because I cant understand this:
    After the for loop old_chrome[i] and new_chrome[i] point to the same place at the memory. Now (later in the code) if I...
  5. Replies
    9
    Views
    1,771

    Thanks for the quick reply. So after the "for...

    Thanks for the quick reply. So after the "for loop" copy the new and old will write at the same point. As a result, if lets say the new_chrome[i].genes[i] is changed by some process after the "for...
  6. Replies
    9
    Views
    1,771

    fastest copy of structure elements

    Dear all,

    I am wondering if I understand well. In the structure below



    struct chromosome{
    double genes[NUM_OF_GENES];
    };
    struct chromosome ...
  7. Replies
    6
    Views
    1,017

    question about stochastic optimization

    Dear All.

    Maybe this is a little bit irrelative question for this forum but maybe someone has experience on this. I would like to minimize a function of the form (A*x-b)^2 ( A matrix x vector b...
  8. Replies
    1
    Views
    819

    the */ after the ...

    the */ after the

    /*MPI_Send(&array2,0,MPI_INT,0,9,cowork_comm);*/
    }

    shouldnt be there but it's a typo; it's not the problem
  9. Replies
    1
    Views
    819

    Another MPI question

    in the code below. I use MPI_Comm_excl to exclude rank 0 of MPI_COMM_WORLD
    and then split the remaining ranks in "buckets" and correspond a communicator. I use Allreduce in order to sum the...
  10. Replies
    2
    Views
    782

    Dear codeplug, Many thanks for your reply. You...

    Dear codeplug,

    Many thanks for your reply. You helped me a lot. I couldnt spot this

    Best,
    Chris
  11. Replies
    0
    Views
    804

    Any forum for MPI?

    Hello,

    I would welcome any info about boards like the C Board but about MPI or general parallel programming

    Many thanks,
    Christos
  12. Replies
    2
    Views
    782

    For those Who know MPI

    In the code below. I splitt the comm WORLD_COMM in 6 subgroups and Allreduce the rank before splitting.



    #include "mpi.h"
    #include <stdio.h>
    int main(argc,argv)
    int argc;
    char *argv[];...
  13. Replies
    1
    Views
    730

    MPI question

    I am using derived datatypes to broadcast array of structures as below. But what is happens is that I send only the half of what I would like. rank1 should have values (0-9) until i=9 like rank0. But...
  14. Replies
    5
    Views
    2,051

    thank you. This is what I was thinking. No way to...

    thank you. This is what I was thinking. No way to avoid loading network
    many thanks
  15. Replies
    5
    Views
    2,051

    THanks for the reply codeplug. Is there any...

    THanks for the reply codeplug.
    Is there any other way to do this without changing these lines of code?

    Many thanks on behalf
  16. Replies
    5
    Views
    2,051

    MPI_Allreduce question

    In the code below. I use MPI_Allreduce in order to sum the old_chrome[x].fitness.



    #include <stdio.h>
    #include <mpi.h>
    #include <time.h>
    #include <stdlib.h>
  17. Replies
    3
    Views
    645

    thank you very match sprintf worked fine

    thank you very match sprintf worked fine
  18. Replies
    7
    Views
    2,206

    How its possible since the only thing that you...

    How its possible since the only thing that you said is to open the file and print if it is ok. You have to read the data and then print
  19. Replies
    3
    Views
    645

    fopen question

    In the code below I would like each time to open a file with name input_i where i could be a number that varies for example from 1 to 10. Could you help me on this.
    Many thanks




    if ((infileX...
  20. Thread: awk again

    by Chris_1980
    Replies
    3
    Views
    1,055

    my question could be is there any way of saying...

    my question could be is there any way of saying any character in awk like the "*" operator
    As far as i understand there is the "." operator which means any but only one character.
    for example A.U ...
  21. Thread: awk again

    by Chris_1980
    Replies
    3
    Views
    1,055

    awk again

    I have a list of records like below:

    N_p_hello[f]_lolo where p and f is a number from 0 to 1000 and i would like to substitute the hello[f] with the number f so it will be
    N_p_f_lolo

    I tried...
  22. Replies
    2
    Views
    925

    awk question

    Hello to All,

    I have a problem. I have a list like below:

    A_1_ccc_2_0 = 2
    A_3_ccc_4_1 = 1
    A_2_ccc_2_2 = 4
    .
    .
    .
  23. Replies
    2
    Views
    861

    thanks for the answer

    thanks for the answer
  24. Replies
    2
    Views
    861

    MPI_Scatter structuire's field

    Hello,

    I would welcome some help in the code below. I would like to Scatter from the node 0,the genes' field in different nodes in a chunk of 2.




    #include <stdio.h>
    #include <stdlib.h>...
  25. Replies
    0
    Views
    2,861

    MPI_Scatter structure elements

    Hi to all,

    In the example code below I was wondering how to Scatter




    struct chromosome{
    double fitness;
    double genes[NUM_OF_GENES];
Results 1 to 25 of 79
Page 1 of 4 1 2 3 4