Recent content by swartzism
-
S
Fortran Rules for Fixed Format Fortran: A Comprehensive Guide
Yes, but isn't that just for .f77? Do .f and .for have different rules?- swartzism
- Post #3
- Forum: AI and Computer Science
-
S
Fortran Rules for Fixed Format Fortran: A Comprehensive Guide
Are there any rule guides on fixed format Fortran such as in .f77, .f, .for files? For example, http://www.physics.nau.edu/~bowman/PHY520/F77tutor/03_basics.html has a few snippets of rules for Fortran 77 such as Col. 1 : Blank, or a "c" or "*" for comments Col. 1-5 : Statement label...- swartzism
- Thread
- Format Fortran Rules
- Replies: 5
- Forum: AI and Computer Science
-
S
Multiple patterns in SED delete
I would like to delete all lines starting with the following - \t (tab) - \n (newline) - / - (single space) - = I've tried `sed -n '/^\(\t\|\n\|/\| \|=\)$/d' OUTPUT.txt > test.txt` and combos of that to no avail. What am I doing wrong?- swartzism
- Thread
- Delete Multiple Patterns
- Replies: 2
- Forum: AI and Computer Science
-
S
Fortran Simplifying a 80-subroutine Fortran Makefile
Very cool.- swartzism
- Post #5
- Forum: AI and Computer Science
-
S
Fortran Simplifying a 80-subroutine Fortran Makefile
Learn something new every day! This makes my life a lot simpler.- swartzism
- Post #3
- Forum: AI and Computer Science
-
S
Fortran Simplifying a 80-subroutine Fortran Makefile
I've always made my own makefiles and it hasn't been an issue because it's usually a small number of subroutines. However, I am working on modernizing and optimizing a Latin Hypercube sampling code in Fortran which has close to 80 functions/subroutines that I am splitting up into different files...- swartzism
- Thread
- Code Fortran
- Replies: 4
- Forum: AI and Computer Science
-
S
Using MKL to Switch Between Single and Double Precision
What does NDEBUG do? I just read that it preprocesses asserts, but I don't use any.- swartzism
- Post #20
- Forum: AI and Computer Science
-
S
Using MKL to Switch Between Single and Double Precision
The current compiler options I am using are icc -c -std=c99 -O3 -opt-streaming-stores auto -qopt-report=3 -opt-multi-version-aggressive -opt-assume-safe-padding -mkl Do you have any examples of the compiler options you saw increase performance?- swartzism
- Post #17
- Forum: AI and Computer Science
-
S
Using MKL to Switch Between Single and Double Precision
I agree. I was just interested in the experiment.- swartzism
- Post #15
- Forum: AI and Computer Science
-
S
Using MKL to Switch Between Single and Double Precision
Turns out that double versus single precision in this case does not make much of a difference. Double: Single: Total run time: 12.210 (s) Total run time: 11.240 (s) Number of Monte Carlo iterations: 1 Number of Monte Carlo...- swartzism
- Post #13
- Forum: AI and Computer Science
-
S
Using MKL to Switch Between Single and Double Precision
Carno, I've modified it to something along the lines of Ben Alpert's answer here http://stackoverflow.com/questions/459691/best-timing-method-in-c It now works with both single and double precision.- swartzism
- Post #12
- Forum: AI and Computer Science
-
S
Using MKL to Switch Between Single and Double Precision
wle, Making the modifications you suggested ended up working. Thanks for the help! Now, I'd like to compare the runtimes, but my timing is just printing out zeros for the float case. My timer is #include <time.h> #include <sys/time.h> #include <assert.h> #include <sys/mman.h> #include...- swartzism
- Post #10
- Forum: AI and Computer Science
-
S
Rank Array of Numbers in Ascending Order in C
wle, I'm running into an issue that I either missed or is new. Matching sort is crapping out after sorting the second row: R rank data: 15.0000 3.0000 5.0000 13.0000 14.0000 9.0000 2.0000 8.0000 10.0000 6.0000 1.0000 7.0000 11.0000 12.0000...- swartzism
- Post #22
- Forum: AI and Computer Science
-
S
Rank Array of Numbers in Ascending Order in C
Absolutely. This is more of a learning process than anything. Plus, it's fun to see something go 7000x faster than an alternate version! I have removed the rank_* matrices (thought I needed them when I didn't). I initially zero out all arrays in the main program (I have found myself bitten in...- swartzism
- Post #21
- Forum: AI and Computer Science
-
S
Using MKL to Switch Between Single and Double Precision
Sorry for the late response, I was out of town for the 4th. My intent here is to first compare precision of the answer and second to investigate speed increases due to exactly what you guys are talking about with fitting more data into cache. I don't believe my Monte Carlo loop can be...- swartzism
- Post #8
- Forum: AI and Computer Science