Recent content by tawi
-
T
C/C++ Rewriting C/ C++ code in Pascal
It should do this: http://d1gjlxt8vb0knt.cloudfront.net//wp-content/uploads/NewPermutation.gif But for some reason the string suddenly starts to elongale, shorten...- tawi
- Post #6
- Forum: Programming and Computer Science
-
T
C/C++ Rewriting C/ C++ code in Pascal
Yes, I am an idiot. So far I have done this but the swap function is not working properly.. Not sure why. permu(output); function swap(str: String; firstIndex: Integer; secondIndex: Integer): String; var tmp : Char; begin tmp:=str[firstIndex]; str[firstIndex]:=str[secondIndex]...- tawi
- Post #3
- Forum: Programming and Computer Science
-
T
C/C++ Rewriting C/ C++ code in Pascal
Hello, I have a code in C/ C++and I have just learned I am going to need it in a version compatible with Free Pascal. I would never bother anyone with it but as I need it pretty quickly and my knowledge of Pascal is very poor I would spend ages rewriting this and it probably woudn't even work at...- tawi
- Thread
- C++ Code Pascal
- Replies: 5
- Forum: Programming and Computer Science
-
T
Linear algebra - vector spaces, bases
You mean writing ##ax^3 + bx^2 + cx + d = p## which will give us system of four equations with the same LHS and RHS will always be the result for the individual elements of the basis? So the first equation would be ##ax^3 + bx^2 + cx + d = c##, second ##ax^3 + bx^2 + cx + d = d##, third ##ax^3...- tawi
- Post #7
- Forum: Calculus and Beyond Homework Help
-
T
Linear algebra - vector spaces, bases
Yes, the last one should in fact be p(1).- tawi
- Post #5
- Forum: Calculus and Beyond Homework Help
-
T
Linear algebra - vector spaces, bases
so for ##p'(0)## we'll have ##c##, for ##p'(1)## we will have ##3a^2+2b+c##, for ##p(0) d## and for ##p(1) a^3+b^2+c+d##... How will the final solution look like then? Just a vector with these elements?- tawi
- Post #3
- Forum: Calculus and Beyond Homework Help
-
T
Linear algebra - vector spaces, bases
Homework Statement 1) In a vector space V of all real polynomials of third degree or less find basis B such that for arbitrary polynomial p \in V the following applies: [p]_B = \begin{pmatrix} p'(0)\\p'(1)\\p(0)\\p(1)\end{pmatrix} where p' is the derivative of the polynomial p. Homework...- tawi
- Thread
- Algebra Bases Linear Linear algebra Vector Vector spaces
- Replies: 8
- Forum: Calculus and Beyond Homework Help
-
T
Pascal Permutation Matrix: Find Number of Columns
Is there an easy way to sort the columns? Can't think of any. I feel like if I wanted to do that the code would be just as long as the one I have already written.- tawi
- Post #3
- Forum: Engineering and Comp Sci Homework Help
-
T
Pascal Permutation Matrix: Find Number of Columns
Homework Statement I should write a program that determines how many columns of a given matrix are a permutation. The user will input some number N <=20 which will be the size of our matrix NxN. Then he will input the individual elements of the matrix by rows. I need to find out how many...- tawi
- Thread
- Pascal Permutation
- Replies: 2
- Forum: Engineering and Comp Sci Homework Help
-
T
Discrete Math: Poset Characteristics and Minimum Element Count
Well "poset" as partially ordered set. What kind of ordering am I assuming? That is up to me, my task is to find out whether such a set exists and if so, what is the least amount of elements it can have.- tawi
- Post #3
- Forum: Precalculus Mathematics Homework Help
-
T
Discrete Math: Poset Characteristics and Minimum Element Count
Homework Statement My task is to find out what is the lowest # of elements a poset can have with the following characteristics. If such a set exists I should show it and if it doesn't I must prove it. 1) has infimum of all its subsets, but there is a subset with no supremum 2) has two maximal...- tawi
- Thread
- Discrete Discrete math Discrete mathematics Relations
- Replies: 4
- Forum: Precalculus Mathematics Homework Help
-
T
Question about sequences in Pascal
Hmmm.. it also would put spaces in between the results. I don´t know.. This probably also isn´t the way it is supposed to be done.- tawi
- Post #16
- Forum: Engineering and Comp Sci Homework Help
-
T
Question about sequences in Pascal
Maybe some sort of recursion?- tawi
- Post #14
- Forum: Engineering and Comp Sci Homework Help
-
T
Question about sequences in Pascal
I am almost 100% sure this can be done with some basic stuff, without using anything external. Defining a function or a procedure would probably make no difference here, right?- tawi
- Post #13
- Forum: Engineering and Comp Sci Homework Help
-
T
Question about sequences in Pascal
What do you mean? There are no more restrictions than what I have written there.- tawi
- Post #11
- Forum: Engineering and Comp Sci Homework Help