<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Problem mit Klassen bzw. Matrix-Multiplikation.]]></title><description><![CDATA[<p>Hallo, ich habe ein Problem bei einem Programm, welches ich für COmputerphysik schreiben soll. Der Dozent hat 3 Klassen definiert, und diese per Email angehangen: Eins für Matrizen, eins für Spalten und eins für Zeilenvektoren.<br />
Den Inhalt der Klassen werde ich noch weiter unten posten.<br />
Was ich möchte, ist einfach die Matrix-bzw. Vektormultiplikation ausführen, diese Operationen sind in den Files definiert.<br />
Jedoch kommt meistens folgende Fehlermeldung:</p>
<p>&quot;u2.cpp:41: error: invalid operands of types `svec ()(double, double)' and `zvec<br />
()(double, double)' to binary `operator*'&quot;</p>
<p>Matrix.h- Klasse: <a href="http://www.copypaste.at/1165" rel="nofollow">http://www.copypaste.at/1165</a><br />
svec.h : <a href="http://www.copypaste.at/1166" rel="nofollow">http://www.copypaste.at/1166</a><br />
zvec.h: <a href="http://www.copypaste.at/1167" rel="nofollow">http://www.copypaste.at/1167</a></p>
<p>Mein Programm Code: <a href="http://www.copypaste.at/1168" rel="nofollow">http://www.copypaste.at/1168</a></p>
<p>Ich habe wirklich schon alles mögliche ausprobiert, um die Multiplikation auszuführen.. ich glaub es liegt einfach nur an der Syntax.<br />
2.te Frage rein aus Interesse: Warum muss ich im Vektor, sagen wir Vector (x,y)-<br />
im Programmcode schreiben vector (double x, double y); ,wenn ich vorher doch x und y schon als double deklariert habe?</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/266396/problem-mit-klassen-bzw-matrix-multiplikation</link><generator>RSS for Node</generator><lastBuildDate>Thu, 03 Sep 2026 07:14:10 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/266396.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 08 May 2010 10:16:07 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Problem mit Klassen bzw. Matrix-Multiplikation. on Sat, 08 May 2010 10:22:58 GMT]]></title><description><![CDATA[<p>Hallo, ich habe ein Problem bei einem Programm, welches ich für COmputerphysik schreiben soll. Der Dozent hat 3 Klassen definiert, und diese per Email angehangen: Eins für Matrizen, eins für Spalten und eins für Zeilenvektoren.<br />
Den Inhalt der Klassen werde ich noch weiter unten posten.<br />
Was ich möchte, ist einfach die Matrix-bzw. Vektormultiplikation ausführen, diese Operationen sind in den Files definiert.<br />
Jedoch kommt meistens folgende Fehlermeldung:</p>
<p>&quot;u2.cpp:41: error: invalid operands of types `svec ()(double, double)' and `zvec<br />
()(double, double)' to binary `operator*'&quot;</p>
<p>Matrix.h- Klasse: <a href="http://www.copypaste.at/1165" rel="nofollow">http://www.copypaste.at/1165</a><br />
svec.h : <a href="http://www.copypaste.at/1166" rel="nofollow">http://www.copypaste.at/1166</a><br />
zvec.h: <a href="http://www.copypaste.at/1167" rel="nofollow">http://www.copypaste.at/1167</a></p>
<p>Mein Programm Code: <a href="http://www.copypaste.at/1168" rel="nofollow">http://www.copypaste.at/1168</a></p>
<p>Ich habe wirklich schon alles mögliche ausprobiert, um die Multiplikation auszuführen.. ich glaub es liegt einfach nur an der Syntax.<br />
2.te Frage rein aus Interesse: Warum muss ich im Vektor, sagen wir Vector (x,y)-<br />
im Programmcode schreiben vector (double x, double y); ,wenn ich vorher doch x und y schon als double deklariert habe?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1894175</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1894175</guid><dc:creator><![CDATA[beinando]]></dc:creator><pubDate>Sat, 08 May 2010 10:22:58 GMT</pubDate></item><item><title><![CDATA[Reply to Problem mit Klassen bzw. Matrix-Multiplikation. on Sat, 08 May 2010 10:30:34 GMT]]></title><description><![CDATA[<pre><code class="language-cpp">svec v( double x, double y );
    zvec w( double a, double b);
</code></pre>
<p>Bitte in deinem <strong>Buch</strong> nochmal nachschlagen, wie man Funktionen / Konstruktoren aufruft.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1894178</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1894178</guid><dc:creator><![CDATA[Janjan]]></dc:creator><pubDate>Sat, 08 May 2010 10:30:34 GMT</pubDate></item><item><title><![CDATA[Reply to Problem mit Klassen bzw. Matrix-Multiplikation. on Sat, 08 May 2010 13:37:22 GMT]]></title><description><![CDATA[<blockquote>
<p>2.te Frage rein aus Interesse: Warum muss ich im Vektor, sagen wir Vector (x,y)-<br />
im Programmcode schreiben vector (double x, double y); ,wenn ich vorher doch x und y schon als double deklariert habe?</p>
</blockquote>
<p>Wo genau meinst du das? Zeig am besten mal den Codeausschnitt.<br />
Ich befürchte, dass du das einiges durcheinander bringst..</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1894249</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1894249</guid><dc:creator><![CDATA[drakon]]></dc:creator><pubDate>Sat, 08 May 2010 13:37:22 GMT</pubDate></item><item><title><![CDATA[Reply to Problem mit Klassen bzw. Matrix-Multiplikation. on Sat, 08 May 2010 13:53:58 GMT]]></title><description><![CDATA[<p>zeile 12,13, und 20.. (in meinem programmcode, zum beispiel)<br />
da habe ich ja geschriebe<br />
double x;<br />
double y;<br />
wenn ich jetzt einfach nur schreibe svec r(x,y); bringt er mir nen fehler.</p>
<p>ich les mir gerade noch was zu klassen durch, ich bin da ziemlich blank um ehrlich zu sein. aber eigentlich ist das doch total trivial eine in einer funktion definierte rechenoperation auszuführen.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1894254</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1894254</guid><dc:creator><![CDATA[beinando]]></dc:creator><pubDate>Sat, 08 May 2010 13:53:58 GMT</pubDate></item><item><title><![CDATA[Reply to Problem mit Klassen bzw. Matrix-Multiplikation. on Sat, 08 May 2010 15:13:55 GMT]]></title><description><![CDATA[<p>Das gehört da ja auch nicht hin.. <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f644.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--face_with_rolling_eyes"
      title=":rolling_eyes:"
      alt="🙄"
    /></p>
<p>Befolg Janjan's rat und lies ein Buch über das Thema.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1894276</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1894276</guid><dc:creator><![CDATA[drakon]]></dc:creator><pubDate>Sat, 08 May 2010 15:13:55 GMT</pubDate></item></channel></rss>