42 Topics

Member Avatar for
Member Avatar for tyrantbrian

Following is a matrix multiplication code written in MPI (Message Passing Interface) which could be run on CPU cluster for parallel processing. This has been successfully tested with two square matrices, each of the size 1500*1500.

Member Avatar for Gustavo_4
2
18K
Member Avatar for Von_1
Member Avatar for choboja621

I need to create a MULTIPLICATION TABLE with a Start Number and End Number and How many times it should be multiplied. Any tips for the looping? Thank you!

Member Avatar for diafol
0
127
Member Avatar for jsefraijeen

i'm a newbie in java and i got an assignment to do and i don't know how to start ... the problem is: Write a program that will compute for the product of two numbers without using the * operator.. Sample Output: Enter Num1 :___ Enter num2 :___ Product is …

Member Avatar for JamesCherrill
0
9K
Member Avatar for exoruel

Good Day guys, I wanted to make a multiplication table but it seems not that easy for a newbie like me. Mind taking your time and see what I am missing in my code? It would be a great help. Here's the code: #include<iostream> #include<conio.h> using namespace std; void initArray(int …

Member Avatar for rubberman
0
1K
Member Avatar for Bradoz

Hello below is my code for a program that reads in integers rom keyboard input and creates two polynomials from that input and then does some maths functions on them. I've got the addition working, having trouble with the multiplication though. Any help would be appreciated. thanks import java.util.*; import …

Member Avatar for JamesCherrill
0
3K
Member Avatar for Momerath

Optimizing Matrix Multiplication One time consuming task is multiplying large matrices. In this post we'll look at ways to improve the speed of this process. We'll be using a square matrix, but with simple modifications the code can be adapted to any type of matrix. The straight forward way to …

Member Avatar for fran2884
7
5K
Member Avatar for mstoltz1

Ok, so I just made this account because I'm super stuck. Basically I need to create a math quiz that takes a users input (1 through 12), have it spit out a question, i.e What is 5 x 12? however if the user enters 5, it must randomly generate a …

Member Avatar for JamesCherrill
0
2K
Member Avatar for ZJRG.1997

I'm quite new to programming and i'm trying to write a formula to work out the capacitance of capacitors - and is what I have below. I then want to convert the value I have (in pico farrads) into micro farrads. Here's what I have so far: while True: x=float(input("First …

Member Avatar for Gribouillis
0
211
Member Avatar for kenneth.leonida
Member Avatar for tessa.burkhalterblackmon

Below is my code so far that ask user for how many numbers they want to input. This program can calculate average based on the numbers that the user input but I also need it to find the product or multiplication of all the numbers entered. I know how to …

Member Avatar for tessa.burkhalterblackmon
0
377
Member Avatar for davidjennings

Hi All, I am trying to the following: The code is written in ASP, the output is from a database. I am trying to multiply the QTY and RATE#2 and display total with each order in the returned data. This relates to the last td's in the output. I also …

Member Avatar for davidjennings
0
307
Member Avatar for levesque123456

I am trying to make a calculator to calculate your age in dog years, the following is the code I have so far, minus the html portion of it <?php if (!isset($_POST['your_age']) ) { header("Location: dog_form.html"); exit; } if ($_POST['your_age'] == "your_age") { $result = ($_POST['your_age'] *7; if ($_POST['your_age'] >= …

Member Avatar for diafol
0
344
Member Avatar for sam.escott4

Hi, In an application im making, I need to square a decimal value in a text field to then use in other calculations later, but when the compiler squares the value it ignores the decimal points, treating 1.85^2 as 185^2 and returning 34225 rather than 3.4225. What am I doing …

Member Avatar for KenSquare
0
341
Member Avatar for cussel

hi all, how to do multiplication matrix with iteration and stop iteration if value >= 5? $data = array( array(1,-0.52836), array(-0.52836,1,), ); for ($i=0;$i<count($data);$i++) { for ($j=0;$j<count($data[$i]);$j++) { $R2[$i][$j] = (($data[$i][0]*$data[0][$j])+($data[$i][1]*$data[1][$j])); } } echo "<pre>"; print_r($R2); echo "</pre>"; result: 1.279164732 -1.056721269 -1.056721269 1.318545629 how to do nested loop from process …

Member Avatar for LastMitch
0
226
Member Avatar for Labdabeta

Hello, As may be apparent from my previous posts, I am in a "If its worth doing, its worth overdoing" sort of competition with a friend of mine. Our goal is arbitrary precision integer arithmetic. I think I am close to getting the data storage working, but now I want …

Member Avatar for Labdabeta
0
974
Member Avatar for DavidB

Here is a small--complete--program that includes a sub-routine that inputs two matrices and then multiplies them. Notes: * 1) I happen to like taking input from a text file. It eliminates the need to type input from the console, especially when debugging, it prevents the possibility of making typos. * …

Member Avatar for Shellback3
3
2K
Member Avatar for ebc3142

Hi, I'm using this SQL statement to retrieve Value and Date which will then be plotted on a graph: SELECT DISTINCT assets.SEDOL,assets.Quantity,stock_names.value,stock_names.Fileid,date_header.dateid FROM assets,stock_names,date_header WHERE assets.Client_ref = '$clientref' AND stock_names.SEDOL = assets.SEDOL AND date_header.fileid = stock_names.fileid I'm also selecting Quantity. Instead of having to multiply out the arrays, how can …

Member Avatar for AleMonteiro
0
229
Member Avatar for ziadkassam

Hello all... I want the multiplication of the same matrix but in third, forth, fifth... degree. I have made the C++ program and this is the code: #include <stdio.h> #include <stdlib.h> #include <iostream> using namespace std; #define WIDTH 3 #define HEIGHT 3 void main(){ int a[HEIGHT][WIDTH]; int b[HEIGHT][WIDTH]; int n; …

Member Avatar for ziadkassam
0
406
Member Avatar for satnav_8

Hey guys, I'm stuck. What I want to do for a school project is demonstrate how bacteria divides and multiplies on an exponential scale. What I want to do is have a TreeView, and when the user clicks the 'Populate' button, a tree will be generated. I want the tree …

Member Avatar for tinstaafl
0
165
Member Avatar for germainelol1

I am creating a method to multiply 2 polynomial expressions together such that: `3x^5 * 2x^3 = 6x^8` -> Where the coefficients are multiplied and the exponents are added together. My test case for this would look something like the following @Test public void times01() throws TError { assertEquals(Term.Zero, Term.Zero.times(Term.Zero)); …

Member Avatar for NormR1
0
328
Member Avatar for anoushka
Member Avatar for babi.meloo

I need to design and implement an application that produces a multiplication table, showing the results of import java.util.*; import java.text.*; public class MultTab7 { //---------------------------------------------------------------------------------------------- // Creates a multiplication table. //---------------------------------------------------------------------------------------------- public static void main (String[] args) { int MAX = 12; for (int r=1; r<=MAX; r++) { for …

Member Avatar for babi.meloo
0
2K
Member Avatar for hauda67

for (k=0; k<M; k++) for (i=0; i<N; i++){ c[i][k]=0.0; for(j=0;j<P;j++) c[i][k]+ =a[i][j]*b[j][k]; I have implemented the above sequential matrix-matrix multiplication algorithm, but i'm not sure about implementing a method to display the output to verify that the algorithm works as expected.

Member Avatar for NormR1
0
467
Member Avatar for vincent5487

This Is my Question : Using loop statement, write a VB .NET program that prompts an integer in the range of 1 to 10 (both inclusive) from the user in an input box, and prints a multiplication table of the integer entered. For example, when the user enters 8, your …

Member Avatar for hericles
0
737
Member Avatar for deval90

/***** The prompt i have is : use a class with 3 member functions named InputMatrix, Calculate, and OutMatrix. The program will prompt the user to (e)enter the matrix data, (c) to calculate the matrix multiplication, (d) to display the input and output matrices, and (q) to quit. no exit() …

Member Avatar for mike_2000_17
0
247
Member Avatar for MicrosoftMahmou

hi Am trying to write a C-code that multiply two matrices but i want the elemnets of every matrix is random number using time function main() { srand ( time(NULL) ); int m1[10][10]; m1[10][10] = rand() % 10; scanf("%d%d",&r1,&c1); scanf("%d%d",&r2,&c2); if(r2==c1) { . . . . } this is the …

Member Avatar for zeroliken
0
222
Member Avatar for Bradoz

Hello problem i am having is when trying to multiply polynomial 1 by polynomial 2 polynomial 1 gets mutliplied by the first term in polynomial 2 and not by each term in polynomial 2. Below is my code: ~~~~ /********************************************************************************************* * Multiplies Polynomial 1 to Polynomial 2 * The method …

Member Avatar for NormR1
0
308
Member Avatar for layneb131

So im trying to create a times table: Write a program to print a multiplication table (a times table). At the start, it should ask the user which table to print and how high the table should go. The output should look something like this: Which multiplication table would you …

Member Avatar for woooee
0
1K
Member Avatar for patk570

Trying to figure out why this SIMPLE math function will not work. If anyone can help me that would be great....Thanks [CODE] <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Calc Price</title> <SCRIPT LANGUAGE="JavaScript"> function doMath() { var one = eval(document.theForm.elements[0].value) var …

Member Avatar for Airshow
0
214

The End.