Code Definition and 960 Threads

In communications and information processing, code is a system of rules to convert information—such as a letter, word, sound, image, or gesture—into another form, sometimes shortened or secret, for communication through a communication channel or storage in a storage medium. An early example is an invention of language, which enabled a person, through speech, to communicate what they thought, saw, heard, or felt to others. But speech limits the range of communication to the distance a voice can carry and limits the audience to those present when the speech is uttered. The invention of writing, which converted spoken language into visual symbols, extended the range of communication across space and time.
The process of encoding converts information from a source into symbols for communication or storage. Decoding is the reverse process, converting code symbols back into a form that the recipient understands, such as English or/and Spanish.
One reason for coding is to enable communication in places where ordinary plain language, spoken or written, is difficult or impossible. For example, semaphore, where the configuration of flags held by a signaler or the arms of a semaphore tower encodes parts of the message, typically individual letters, and numbers. Another person standing a great distance away can interpret the flags and reproduce the words sent.

View More On Wikipedia.org
  1. R

    Fortran How Can I Improve My Fortran Program for Calculating Different Types of Means?

    Trying to write a single Fortran program that calculates the arithmetic mean, rms (root-mean-square) average, geometric mean, and harmonic mean for a set of numbers (for example - 4 4 4 4 4). I don't know if I am doing the write way. Please guide me. PROGRAM ComputingMeans IMPLICIT...
  2. K

    Is a Suit Necessary for Presenting at Physics Conferences?

    I'm going to be attending and presenting at my first large physics conference this spring. I'm trying to get my dad to help me buy a suit for the day I present. However, my dad (an experienced biochemist) refuses, not because of money, but because he claims "nobody ever wears suits to those...
  3. S

    C/C++ What is the significance of this C++ code and what does it do?

    Hey guys. I just want to see if I am indeed "seeing" the significance of the code that is to follow. I will follow it with a brief explanation of what I thought the code did. Thanks in advance. const int N = 15; bool table[N]; int i = 0; while (i < N) { table[i] = true...
  4. M

    What Are the Different Methods to Define a Plate in MCNP Code?

    I have a question about diffrence between ways of defining a certain plate like (3^1/2)x+y+17.3=0 to MCNP code .for example I know we can define it to MCNP with 15 p 3 2 0 6 but I couldn't understand this method 15 10 0 5 8.66 0 10 0 1
  5. F

    Fortran Why Am I Getting a Parenthesis Error in FORTRAN Code Compilation?

    Hello, I received some very old cold, and I don't even know for which FORTRAN standard it was originally written, only that it has existed since at least 1993. I'm trying to compile it in gfortran, and I get the following error: 'Error: Expected a right parenthesis in expression at (1)'...
  6. E

    Is the gray code arithmetic code ?

    hi is the gray code arithmetic code?why? where this code used?
  7. T

    MATLAB help, code for Frobenius norm

    Hello, I am trying to write a mtlab code to compute Frobenius norm of an mxn matrix A. defined by ||A||_{F} = \sqrt{ \sum_{i=1}^m \sum_{j=1}^n a^{2}_{i,j}} I have so far written this code, but it does not work, if anyone can help /guide me to the right path, would be greatly...
  8. M

    Confusions about Position Independent Code

    Hello! I was reading this excellent article about position independent code and it's implementation for shared libraries. I'm still confused about one part though. My current understanding is that the offset between the code section and data section is known at compile time. Since this offset...
  9. C

    Calculators How to put code on MS WORD onto TI-89

    My Thermodynamics teacher gave me a code for various calculators to put into the calculator for Interpolation. I am just wondering how you put this code that is in MS WORD onto my TI-89. I have the TI-Connect software. Here is what is looks like: This code is for the TI-89: interpol()...
  10. M

    Fortran Error 112 /undef when running fortran code

    Hi, I am a new Fortran User. I have a problem when I run my code (not errors during building), in fact the code is stopped in the last line and this message appears "Error 112, Reference to undefined variable, array elements or function result" ... write(number,100)k1 open...
  11. Fredrik

    LaTeX An exact copy of a working LaTeX code doesn't work?

    An exact copy of a working LaTeX code doesn't work!? OK, someone needs to explain this to me, because my head is about to explode. Forum member Jorriss has a LaTeX code in his signature. It includes the LaTeX code \Psi in two places. The second one is displayed correctly. The first one isn't...
  12. K

    Cracking the Code: Solving Cylindrical Shells with Gauss's Law

    Homework Statement "A cylindrical shell of length 230 m and radius 6 cm carries a uniform surface charge density of σ = 14 nC/m^2. What is the total charge on the shell? Find the electric field at the end of a radial distance of 3 cm from the long axis of the cylinder." Homework Equations...
  13. Y

    Fortran A FORTRAN code for solving Sudoku puzzle

    For few days I am thinking to write a code in FORTRAN to solve the sudoku puzzle. At first it seams simple but I have no luck writing this code. I am wondering if there is any written code to solve this puzzle. I hope Sudoku puzzle is known for members here. en.wikipedia.org/wiki/Sudoku
  14. S

    Mathematica Optimize Your Mathematica Code with These Helpful Tips and Tricks

    First of all, this might give seasoned Mathematica users some serious eye sores cause I'm a newb at this xD f[x_] := (1^-9) (Exp[38.629 x] - 1); data = Table[if[[f[x], {x, -5, 5, 0.01}] > 0.005, 0.005, f[x]]]; ListPlot [data, DataRange -> {-5, 5}, Joined -> True, PlotRange -> {0, 0.01}...
  15. S

    C code and seven segment display

    I need to write some c code that displays a counter value on four 7 segment displays. The number should increment by one every time a button is pushed. I cannot test this code as my home computer will not run Quartus 2 so I am working blind at the moment, but I would still like to ask some...
  16. H

    MATLAB MATLAB code has stopped working

    A few months ago my hard drive crashed and I managed to recover the data and I tried to run some of my old programs (one solving an ODE via Newton's method. Before the crash, the error was 10^-8 after around 3 iterations, now it won't converge. It looks fine, ithe than writing the code from...
  17. P

    I really with a MATLAB iteration code

    Homework Statement Hello, I want to obtain a solution to a, where k is a constant. The formula is: k/a = tan(a) I need to write a MATLAB code for this but I have been struggling for hours. And I must send the project to my professor in an hour. :( Homework Equations I know that I need to...
  18. A

    LaTeX How can I include MATLAB code in Latex without encountering errors?

    I need some kind of environment in Latex where you can write whatever you want without it interpreting it. The reason is I need to include a MATLAB code. Most places I go says I have to use the lstlisting environment, but that doesn't work. Or at least I get this error: ! Package inputenc...
  19. A

    What does the following lines of C source code mean?

    [b]1. Explain what the CPU will do in terms of functuality and configuration when executing the C source code below: unsigned char value = 0x91 1) BSR = 5; 2) BSRbits.3 = 1; 3) INTCONbitsTMR0IE = 1; 4) INTCON2bitsTMR0IP = 1; 5) TRISB = 0x00; 6) PORTB = 0x00; Please can...
  20. P

    Need help interpreting this C (programming) Code

    // Program to categorize a single character that is entered at the terminal #include <stdio.h> int main (void) { char c; printf ("Enter a single character:\n"); scanf ("%c", &c); if ( (c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z') ) printf ("It's...
  21. S

    MATLAB code for Aldous-Broder algorithm from spanning trees of a graph

    Homework Statement Let G = (V,E) be a graph with vertices V and edge set E. Aldous-Broder algorithm: Input: G = (V,E) Output: T = (V, W), where W is a subset of E such that T is a spanning tree of G. Let W be the empty set. Add edges to W in the following manner: starting at any...
  22. D

    LaTeX Entering Code in LaTeX Documents

    How can I enter code in Latex documents?
  23. thekey

    MATLAB Please I need a Help with matlab code (Controlling the LEGO NXT Using MatLab)

    Hi Controlling the LEGO NXT Using MatLab What are my mistakes in this code ??! COM_CloseNXT all clc clear handle = COM_OpenNXT(); COM_SetDefaultNXT(handle); COM_CloseNXT(handle); NXT_GetBatteryLevel(handle); COM_CloseNXT(handle); COM_CloseNXT all clc clear...
  24. H

    Dc off-set Analysis - Maatlab code

    Hi, I am trying to use Matlab to analyse this raw signal by introducing Dc-offset analysis: I used the following code : a = [1 , -0.98]; b = [1,-1]; y = filtfilt(b,a,x); figure plot(y) And the result : But, I am trying to get a final result similar to the last graph...
  25. C

    Why is this simple output so difficult to code in C

    1 1 2 1 1 2 1 2 1 1 2 1 2 1 2 1 1 2 1 2 1 2 1 2 1 I am stumped on how to do this, is it really as easy as it looks?
  26. J

    Mathematica Maple check of Mathematica code for Puiseux expansion

    Hi, I was wondering if anyone here with Maple could run the algcurve[puiseux] routine to compute the expansion of the algebraic function: f[z,w]=2 w^9+5 w^{10}+20 w^7 z+3 w^8 z+8 w^5 z^{10}+9 w^6 z^{10}+z^{14}+3 z^{15}+4 w^3 z^{15}+w^4 \left(10 z^5-z^6+2 z^7\right)+w^2 \left(3 z^{15}-20...
  27. C

    Fortran Wanted: Ancient Fortran FFT source code

    Hi. I'm new here and wasn't sure which forum to post this request on, but this one seemed a good start. I am developing a talk/seminar on dealing with legacy code. In the late 1990s I was working for a large corporation in a software capacity and one day idly wondered what the source code...
  28. S

    LaTeX Cannot compile equation in LaTeX- Help with code please

    Hello! I have been trying to get this equation to work in my LaTeX document, I do not really see any issues with it so if somebody could give some guidance that would be really helpful. Code: \begin{equation} {\bf{R}} = \sum_{i=1}^{N}_{{\bf{u}}_{i}} \end{equation} Thank you
  29. B

    [MATLAB] Making code faster/more efficient

    A is a sparse matrix. B is a vector. I have the following code: for j=1:N B=A*B; end; This part of the code is inside a function which gets called about 160000 times. I ran the Profiler and this part is the bottleneck. How can I make it more efficient?
  30. R

    MATLAB What is the error in running Newton's Method in Matlab for a specific function?

    I've been using this for a Newton Approximation in Matlab function x = Newton(f, fp, x, nmax, e) % f is an inline function which we apply Newton's method on % fp is an inline function that is the derivative of function f % x is the initial guess of the root % nmax is the total number...
  31. perplexabot

    Java Debugging Java Quicksort Code: Tips and Tricks for Optimal Results

    Hi all. I am currently working on quicksort and have written the following code and gives "almost" good results. I am not too fond of the data structure I have chosen but it is too late for me to change. Lesson learned. Can anyone help me debug this thing. I have been at it for a while. Anyway...
  32. E

    MATLAB Where is my mistake in this MATLAB code?

    Hi, I am trying to plot the AN product sec II.C in the attached paper as: clear all clc s=0.5; w=0; d=5; f=0:20; NdB1=(17-30.*log10(f)); N1=10.^(NdB1./10); NdB2=40+20*(s-0.5)+26.*log10(f)-60.*log10(f+0.03); N2=10.^(NdB2./10); NdB3=50+7.5*w^0.5+20.*log10(f)-40.*log10(f+0.4)...
  33. Q

    Fortran Fortran code for geometry of fcc

    Hi friends . is there anybody here who can give me a fortran code for describing fcc lattice and give us the neighbours of each site and also which pay attention to periodic condition ? thank you for your help my friends.
  34. S

    Why isn't my algorithm code working?

    I have to write a program validating credit card numbers using Luhn's algorithm. I am having trouble getting my last function to work. For a credit card number I'm supposed to double every second digit from right to left, and sum them (note double digits, like 10=1+0), and then add the rest of...
  35. K

    Palindrome in C (Please try my code)

    Homework Statement Make a code that can check if one or many words are palindromes. The Attempt at a Solution I can't get my compiler to work so I wrote my attempt in a note document. Please can you check if it works and if it doesn't give me some guidence.. I have put a lot of time...
  36. V

    Solving the Heat Equation with R Code

    Hi! I have some trouble understanding this question. Could someone help me with it? Thanks! Solve the following with the explicit method from t=0 to t=0.5 with h=1/10 and with μ(=k/h2)=0.5 ut = uxx, -1 ≤ x ≤ 1, t>0 u(0,x) = cos(x), -1 ≤ x ≤ 1 u(t,-1) = u(t,1) = e-tcos1, t>0 Compute...
  37. L

    A code found in equations for superstring theory huh?

    I'm trying to understand what I have just learned. So some sort of browser based code or binary was discovered in equations for super-string theory. I have a few questions since I am very confused. If code was created by Claude Shannon in the 1940's, then how could it be in this code? Does...
  38. J

    MIPS Assembly Code - Convert instruction code to binary

    Homework Statement Write a single line MIPS assembly code as an input through the SPIM simulator console and the program will output a 32 bit MIPS machine code through the console. I'm using PCSpim to write the code. An example, I input this instruction in the console. addi...
  39. Q

    Fortran Fortran code for spins in heisenberg hamiltonian

    hi friends. i don't know how can i write a fortran code for expressing spins in Heisenberg model which have 3 dimension spin operator, sx,sy,sz? thanks for your help
  40. M

    MATLAB Matlab code natural numbers subset

    I have array of natural numbers from 1 to n. They are divided into m groups, where m*(m-1)=n. I need all m-1 elements from first group, last m-2 elements from second group, last m-3 elements from third group...zero elements from last group. For example 5*4=20: 1,2,3,4; 5,6,7,8...
  41. P

    Can any one here program code for PIC?

    having issues with programming, can some one help me write a code for a push button hobby servo control?
  42. Dembadon

    Is LOLCODE the Funniest Programming Language?

    http://lolcode.com/home I figured a few people here will appreciate it as well. :biggrin:
  43. M

    Combinatorial chem - Stills binary code tag system

    In my med chem book: http://books.google.ie/books?id=Qe9lsbfM_m0C&pg=PT170&lpg=PT170&dq=chemistry+binary+code+tag+system&source=bl&ots=ut23YiKXDW&sig=iWH860UeYHYSwBM_ESbxnLXNrQw&hl=en&sa=X&ei=7XcVUNTpCNSThgeVwoGgAQ&redir_esc=y#v=onepage&q=chemistry%20binary%20code%20tag%20system&f=false they...
  44. W

    Fortran Issues with porting Fortran code

    I have a Fortran (F77) code which I used to use at my previous institution that I am having trouble with at my new job. I used to compile it with ifort on computers running Fedora (14 if I recall correctly). At my new job they don't have ifort so I have had to revert to the use of g77 (f77) on...
  45. G

    Fortran Programming trouble with fortran optimization code

    Hi everyone, I have some trouble adapting an existing fortran code for my application. In the following Module I am optimizing a value for two planes ( i = iplan one&two). In order to do that, I need to assign ten certain values from an external inp. file for each plane. I have two loops...
  46. B

    C/C++ Counting '1' Bits in Binary Blocks - Fast C++ Code

    Hi, For example, say we have the binary integer 101010 and I split it into blocks, say (1)(01)(01)(0). The size of the blocks is determined by some function. We want to count the number of '1' bits inside each of these blocks. I'm interested in a fast C++ code to do this. There are fast...
  47. K

    Fortran Fortran code conversion into Excel VBA

    Hi, I'm currently working on a project that requires me to convert a Fortran code into excel vba. There are some problems that I've stumbled into, so itll be great if someone could help out. one of it would be on how to convert a COMMON statement in Fortran to Excel VBA ( as in how would...
  48. Y

    [Fortrran] Some help with a code error: Segmentation Fault

    Hi, I am having a segmentation fault error just when I ask the code to print the value ipos in the program. However, If I change the print to the module, the segmentation fault does not appear. Could anyone can help know, why I can not transfer the variable ipos from the module to the main...
  49. X

    Mealy FSM Edge Detector Code Problems

    Homework Statement Create a Mealy Edge Detector, then measure the pulse width of 75 micro seconds by 50 MHz clock; here is the timing diagram: I am basically trying to emulate this diagram in my test fixture code (using Xilinx 14.1 in Verilog) and am having errors. Also, the tick is...
  50. I

    Fortran Fortran intrinsic functions source code

    Hi How can I see the source codes used for defining intrinsic functions in Fortran 90/95 ? e.g. what is the actual program for sqrt ? thanks
Back
Top