MATLAB BUILDER JA 2 Podręcznik Użytkownika Strona 229

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 292
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów
Przeglądanie stron 228
Using Class Methods
Example Determining the Complexity of an Array
Determine whether matrix A is real or complex. The complexity method of
MWNumericArray returns an enumeration of type MWComplexity.
double AReal = 24;
double AImag = 5;
MWNumericArray A = new MWNumericArray(AReal, AImag);
System.out.println("A is a " + A.complexity() + " matrix");
When run, the example displays this output:
A is a complex matrix
Methods of MWCom plex ity
toString. This m ethod returns a string representation of the property. The
toString method of MWComplexity overrides the toString method of class
java.lang.Object.
The prototype for the
toString method is as follows:
public java.lang.String toString()
4-153
Przeglądanie stron 228
1 2 ... 224 225 226 227 228 229 230 231 232 233 234 ... 291 292

Komentarze do niniejszej Instrukcji

Brak uwag