jules

Hozzászólások

10 bejegyzés megtekintése - 71-80 / 269
  • Szerző
    Bejegyzés
  • Hozzászólás: file beolvasás c++ #2174365
    jules
    Felhasználó

      Es akkor hogyan kellene javitani?

      Azt szeretnem, hogy minden vegrehajtas utan a kovetkezo sort olvassa be, ergo menjen vegig a .dat file pl. 100 soran.

      Hozzászólás: file beolvasás c++ #2174366
      jules
      Felhasználó

        Es akkor hogyan kellene javitani?

        Azt szeretnem, hogy minden vegrehajtas utan a kovetkezo sort olvassa be, ergo menjen vegig a .dat file pl. 100 soran.

        Hozzászólás: file beolvasás c++ #2174357
        jules
        Felhasználó

          Rosszul irtam, az Y ertekekre kapok rossz eredmenyt. Valojaban csak egy X ertekre kapok egy Y erteket, ami nem jo.

          Azt kellene, hogy a .dat file-bol soronkent beolvasni az ertekeket. Minden beolvasasnal mas ertek irodjon az x-be, es igy mas Y-t kapjak.

          Az Y-t bele kell venni, ide:

          Code:

          for ( int b=0 ; b<hb ; b++ )
          {

          double X=hmi+(b+0.5)*(hma-hmi)/hb;

          double Y=h[b];

          }

          Hozzászólás: file beolvasás c++ #2174358
          jules
          Felhasználó

            Rosszul irtam, az Y ertekekre kapok rossz eredmenyt. Valojaban csak egy X ertekre kapok egy Y erteket, ami nem jo.

            Azt kellene, hogy a .dat file-bol soronkent beolvasni az ertekeket. Minden beolvasasnal mas ertek irodjon az x-be, es igy mas Y-t kapjak.

            Az Y-t bele kell venni, ide:

            Code:

            for ( int b=0 ; b<hb ; b++ )
            {

            double X=hmi+(b+0.5)*(hma-hmi)/hb;

            double Y=h[b];

            }

            Hozzászólás: file beolvasás c++ #2174353
            jules
            Felhasználó

              Atirtam, konkretabban erre gondoltam:

              Code:
              #include
              #include
              using namespace std;

              int main()
              {
              float x;
              double hmi=-2.0;
              double hma=2.0;
              int hb=400;
              double* h;
              h=new double[hb];
              for ( int b=0 ; b<hb ; b++ ) h[b]=0.0;

              for (int i=0;i> x; 

              int b=(int) ((x-hmi)/(hma-hmi)*hb);
              if ( bhb-1 ) b=hb-1;
              h[b]++;

              for ( int b=0 ; b<hb ; b++ )
              {
              double X=hmi+(b+0.5)*(hma-hmi)/hb;

              }

              }
              delete[] h;

              return 0;
              }

              Hozzászólás: file beolvasás c++ #2174354
              jules
              Felhasználó

                Atirtam, konkretabban erre gondoltam:

                Code:
                #include
                #include
                using namespace std;

                int main()
                {
                float x;
                double hmi=-2.0;
                double hma=2.0;
                int hb=400;
                double* h;
                h=new double[hb];
                for ( int b=0 ; b<hb ; b++ ) h[b]=0.0;

                for (int i=0;i> x; 

                int b=(int) ((x-hmi)/(hma-hmi)*hb);
                if ( bhb-1 ) b=hb-1;
                h[b]++;

                for ( int b=0 ; b<hb ; b++ )
                {
                double X=hmi+(b+0.5)*(hma-hmi)/hb;

                }

                }
                delete[] h;

                return 0;
                }

                Hozzászólás: ssh – rsa,dsa kulcsok #2161703
                jules
                Felhasználó

                  Valoszinu nincs man-in-the-middle attak… Csak megvaltoztak a kulcsok, ez tuti: tudom is az uj kulcsokat..Csak az nem vilagos, hogy most mit kell csinlani?

                  Az ugy nyilvan nem megy (vagy igen?..:s), hogy bemasolom az rsa kulcsot a ~/.ssh/known_hosts -ba…

                  Hozzászólás: ssh – rsa,dsa kulcsok #2161704
                  jules
                  Felhasználó

                    Valoszinu nincs man-in-the-middle attak… Csak megvaltoztak a kulcsok, ez tuti: tudom is az uj kulcsokat..Csak az nem vilagos, hogy most mit kell csinlani?

                    Az ugy nyilvan nem megy (vagy igen?..:s), hogy bemasolom az rsa kulcsot a ~/.ssh/known_hosts -ba…

                    Hozzászólás: C++ kerdes… #2155499
                    jules
                    Felhasználó

                      Szevasztok,

                      Valami gond van a programommal: van egy matrix.h es egy compex.h-m. Definialtam += operatort mindkettoben, mert ez kellene nekem a .cpp-mben.
                      Viszont valami nem jo a forditonak, csak nem tudom, hogy micsodahuh.gif

                      Ez a hibauzenet:

                      Code:
                      matrix.h: In member function ‘Matrix& Matrix::operator+=(const Matrix&) [with T = Complex]’:
                      example.cpp:85:  instantiated from here
                      matrix.h:246: error: invalid use of member (did you forget the ‘&’ ?)
                      matrix.h:246: error: invalid use of member (did you forget the ‘&’ ?)
                      example.cpp:85:  instantiated from here
                      matrix.h:246: error: invalid use of member (did you forget the ‘&’ ?)
                      matrix.h:246: error: invalid use of member (did you forget the ‘&’ ?)
                      example.cpp:85:  instantiated from here
                      matrix.h:247: error: invalid use of member (did you forget the ‘&’ ?)
                      example.cpp:85:  instantiated from here
                      matrix.h:248: error: invalid use of member (did you forget the ‘&’ ?)

                      Ez pont a += operator definicios sorai.. Azert csatolom .h fajlokat, hatha nektek van otletetek..remelem

                      Hozzászólás: C++ kerdes… #2155500
                      jules
                      Felhasználó

                        Szevasztok,

                        Valami gond van a programommal: van egy matrix.h es egy compex.h-m. Definialtam += operatort mindkettoben, mert ez kellene nekem a .cpp-mben.
                        Viszont valami nem jo a forditonak, csak nem tudom, hogy micsodahuh.gif

                        Ez a hibauzenet:

                        Code:
                        matrix.h: In member function ‘Matrix& Matrix::operator+=(const Matrix&) [with T = Complex]’:
                        example.cpp:85:  instantiated from here
                        matrix.h:246: error: invalid use of member (did you forget the ‘&’ ?)
                        matrix.h:246: error: invalid use of member (did you forget the ‘&’ ?)
                        example.cpp:85:  instantiated from here
                        matrix.h:246: error: invalid use of member (did you forget the ‘&’ ?)
                        matrix.h:246: error: invalid use of member (did you forget the ‘&’ ?)
                        example.cpp:85:  instantiated from here
                        matrix.h:247: error: invalid use of member (did you forget the ‘&’ ?)
                        example.cpp:85:  instantiated from here
                        matrix.h:248: error: invalid use of member (did you forget the ‘&’ ?)

                        Ez pont a += operator definicios sorai.. Azert csatolom .h fajlokat, hatha nektek van otletetek..remelem

                      10 bejegyzés megtekintése - 71-80 / 269