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. M

    How can you modify Python code for effective graph plotting?

    TL;DR Summary: How to understand the code determining the plot Hi; this is the code I have been given for a H-R diagram of M35; I understand the inversion concept.. The plot is below. I am trying to understand the code that creates its position and size and how to alter it to a more...
  2. Vanadium 50

    Resistor Color Code

    In the Dark Ages, resistor values were indicated by colored bans, and we all had to memorize the code. (This was back when they were bigger than a speck of dust) My question is - why colored bands? Caps have numbers printed on them (as do some resistors). Why fool with bands if you can just...
  3. S

    Unable to crack this image enhancement code -- Matlab is throwing errors

    img= imread('Image.bmp'); img= rgb2gray(img); imshow(img); pt = ginput(4); % the function ginput is used to get the input from mouse x1 = pt(1,1); y1 = pt(1,2); x2 = pt(2,1); y2 = pt(2,2); x = [x1 x2]; y = [y1 y2]; line(x,y); x3 = pt(3,1); y3 = pt(3,2); x4 = pt(4,1); y4 = pt(4,2); x = [x2 x3]; y...
  4. C

    Is It Time for a Gap Year After College?

    Hi, my name's Cass. I finished my bachelors in physics last year. Kind've floating around I guess. I write code, play guitar, make art, and study Japanese. I hope to spend some time away from school and get my priorities straight then maybe go back to gradschool eventually. Nice to meet you!
  5. pairofstrings

    C# Generic Interfaces and Covariance

    Hi. I have the following code: public interface ICovariance<out T> { void Add(T item); T Get(); } How to remove the compile-time error without changing the code of method declaration and by only changing the interface signature? The error is in:void Add(T item); Thanks.
  6. M

    Python Can Fortran 77 Code Be Used to Debug Python Code for Solving ODEs Using Radau5?

    Hi, I have a piece of Fortran code but I'm not Fortran literate. I'm trying to translate it into Python. I have already made it, but I need someone who can run the Fortran code to compare the values of the variables.
  7. A

    Help debugging MCNP code - particle lost and zero latice element found

    I keep getting particle lost error even though there were no hole in the lattice. Can someone identify any mistake in my code?
  8. Gwen

    Python Thermal lattice Boltzmann model ignoring source term -- python code help please

    LBM model for phase change- relevant equations found here. Also here. #Thermal LBM #solves 1D 1 phase phase-change #D2Q5 Lattice nx=100 # the number of nodes in x direction lattice direction ny=5 # the number of nodes in y...
  9. shivajikobardan

    Comp Sci How do "min" and "hour" get their values in this C++ code?

    How does "min" and "hour" get their values in this C++ code? Full code here: #include<iostream> using namespace std;class Time { public: int hour; int min; Time() { hour=min=0; } Time(int h,int m) { hour=h; min=m; } Time add (Time t)...
  10. G

    I Angle of Sun by date and zip code?

    I don't know the correct works search to find this info online. I have been doing word searches since about Dec 15, 2022 but not finding what I want.??????? Some where there much be a chart by date and zip code for sun angle. I built a sun dial in the yard to learn the angle of the sun on...
  11. emilmammadzada

    I get this error when I try to run the code MCNPX

    I get this error"bad trouble in imcn in routine pass1 unexpected eof in file depletion.inp" when I try to run the code MCNPX my input file c Depletion pincell input file for MCNPX c Define cells c Cell 1: Fuel 1 0 -1.0 -4 -5 -6 c Cell 2: Cladding 2 0 -2.0 4 -7 c Cell 3: Moderator 3 0 -3.0...
  12. emilmammadzada

    FRENDY nuclear code -- Where to download it? (for ubuntu 22.04)

    I want to compare njoy2016 and frendy codes.If anyone is using frendy nuclear, I wanted to get information about how to download it for ubuntu 22.04 version?
  13. emilmammadzada

    Stopping power and projected range for FLUKA code

    How do I calculate the stopping power or projected range for aluminum in Fulka. And in which output file is this data located?How can I edit a change in the input file?
  14. G

    Java Please help explain the reason for the errors displayed for my Java code

    //program showing an advantage of using arrays public class Arr3 { public static void main(String []args) { System.out.println("There are 31 days in the month of Jan"); System.out.println("There are 27 days in the month of Feb"); System.out.println("There...
  15. shivajikobardan

    JavaScript What happens when return is executed in this code?

    I'm currently watching tutorials to build projects as I'm still not in a phase where I can carve a project that I want all on my own. Currently, working on a snake game. let speed = 2; let lastPaintTime = 0; //Game functions function main(ctime) { window.requestAnimationFrame(main); if...
  16. James1238765

    I How to do algebra on the Kitaev toric code grid?

    The toric code is a basic computational model as follows: There are 2 operations that can be performed, A and B, on this grid. To compute the value A at each point on the grid, we transform the raw values at each dot (located in between two vertices) according to some predefined operators...
  17. DiracPool

    MATLAB Help converting MATLAB to Scilab code

    Hello, I am having difficulty converting some MATLAB code to Scilab code. Specifically, the problem is with graphing the results of a spiking neuron program. Herer is the program and the article that explains it: https://www.izhikevich.org/publications/spikes.pdf The problem I am having is...
  18. yezia

    Which MSc to do after BSc physics if you love to code?

    Hi everyone! Merry christmas first and I hope you're getting great rest with close ones around :) Well, as title may suggest it, I will graduate soon in physics and I'm not sure of the next step in my academic curriculum. I like theoretical physics, I've touched upon most fondamental physics...
  19. V

    Comp Sci An Introduction to Deep Learning and Modifying Code

    The code with no modifications is at the very bottom. For part 1: loading a mat file into the code, I just put it above the last function but it's going to have to replace the data part of the original code thus I have to extract it out of the file: (I would add the file but I am unsure of how...
  20. M

    C/C++ Errors trying to compile a simple code

    When trying to compile the following c++ code I get the errors I've screenshot // p12 #include <iostream> #include <vector> #include <string> #include <map> class Solution { private: std::vector<int> num = {1,4,5,9,10,40,50,90,100,400,500,900,1000}; std::vector<std::string> sym =...
  21. D

    Online compilers that will run code that features TextIO?

    Hi everyone I've been trying to teach myself coding using the free materials from https://math.hws.edu/javanotes/index.html I've been using online compilers because I got a "Error: Could not find or load main class" message immediately upon installing Eclipse. The online compilers work for...
  22. D

    C/C++ Learning to Code Game Enemy AI in C++ from Scratch or in Assembly?

    Hello, To keep my questions straightforward they are below. How do I learn how to code Game Enemy AI in C++ from scratch and what are the top resources you recommend(Books, Tutorials, CD-Roms, Videos)? How do I learn how to code Game Enemy AI in Assembly Langauge from scratch and what are the...
  23. G

    I What is the angle of the Sun on June 21 & Dec 21 at US Zip Code 37129?

    What is angle of Sun June 21 & Dec 21 at zip code 37129. I need lowest angle & highest angle and probably angle of sun about Feb 20. Google word search shows nothing. I am probably need using correct word search to find what I want. Several years ago I accidently found a calendar that showed...
  24. K

    Genetic code other than DNA (moved)

    Summary: Curious to find out genetic code other than DNA <mentor> Moved to Discussion, hypothetical discussion Dear PF Forum, It's been a long time since I log into PF. And I hope everybody is in a good health. Recently I had a discussion debate with my friend about other life in this...
  25. sophiatev

    A PD code yields two different knot diagrams

    The PD code [(2, 3, 1, 4), (4, 1, 3, 2)] seems to map to a non-unique knot diagram. I can describe the following two Hopf links with different orientations with this same PD code. As I understand it, while a link diagram does not have a unique PD code, a given PD code should map to just one knot...
  26. MidgetDwarf

    Other Is There a 40% Discount Code for Springer Books?

    Hey there. Here is a springer discount code for %40 off. M3rtp5dd Does PF have a deal with Springer, similar to the agreement with Amazon?
  27. M

    Python One-line Python Code that returns a sequence of integers

    Hey! 😊 I want to write a one-line Python generator or iterator expression that returns the sequence of integers generated by repeatedly adding the ascii values of each letter in the word “Close” to itself. The first 10 integers in this sequence are: 67, 175, 286, 401, 502, 569, 677, 788, 903...
  28. Zakariya

    Changing the Temperature in an MCNP code

    Hello everybody. I would like to ask a question; if I change the dimensions and densities and the material number identifier ZAID to a specific temperature. Does MCNP change automatically the volume of the cells? or I have to change the volume of each cell manually and indicate it in the cell...
  29. stephen8686

    I Propagation of Angular Spectrum Code

    I'm making a MATLAB code to propagate a gaussian field in the angular spectrum regime (fresnel number >> 1). After Fourier transforming the field, you propagate it: $$U(k_x,k_y,z) = U(k_x,k_y,0)e^{ik_z z}$$ The thing that I am having trouble with is the propagation factor, I have looked at this...
  30. user366312

    C/C++ Polymer simulation source code in C++ and Python

    I am absolutely new to Polymer simulation. I am trying to understand the simulation by analyzing source code written by others. Can anyone tell me what are the differences between the following three source code in terms of their objectives? Monte-Carlo-simulation-of-polymers...
  31. A

    Need of Tangle calculation using code and Numerically

    = tangle equation = Inequality condition = partial trace formula. To find the tangle, we need the square concurrence value of ABC states as mentioned in a tangle equation. I am not able to find the value of square concurrence.
  32. M

    Comp Sci How does Instruction 2 affect the updates in a flow chart for coding?

    I found this as problem 3/42 from here (copied below for viewing convenience). I'm a little confused about Instruction 2. The way I interpret it, upon the first loop, no evaluation is occurring, but instruction 1 now becomes "increase Box 2 by 2". So now the three instructions are 1) increase...
  33. Mark44

    Interest in post comparing nVidia CUDA code vs. Intel AVX-512 code?

    I've done a bit of CUDA programming lately, to exercise some parallel code on my nVidia graphics card. I also ported implemented the computations in Intel AVX-512 assembly code. The code I wrote takes a bunch (=262,144 = ##2^{18}## to be exact) of points, and calculates the slope and...
  34. C

    Help with this emu8086 assembly language problem please

    Summary:: my code has been successfully showing the right decrement of the letter. however, i tried to put space in between the letter output but its output became repititive letters. this is the original output when i try to put space it become like this i want to put spaces on the output...
  35. shivajikobardan

    MHB What is minimum requirement vs specific requirements to be called in as intelligent agent for any software code piece?

    https://uobrep.openrepository.com/bitstream/handle/10547/223815/ESWA%20agent%20paper%20-v2.pdf;jsessionid=16B243A8F6C1FC1242A75969D18D00B7?sequence=5 here is some information but i am unable to dcode what is minimum requirement vs specific requirements. can you help me a bit in this case?
  36. M

    Python Why Does My Python Code Output None Instead of the Next Permutation?

    Hi PF! I'm trying to write a code that, given a list of integers, will output the next lexicographic permutation. But my output gives me None, and I can't see why. Is it because I am incorrectly calling the reverse function? Any help is greatly appreciated! class Solution(object): def...
  37. shivajikobardan

    MHB Solving Your Problem: Troubleshooting Mistakes in Code

    https://lh6.googleusercontent.com/gIpHfdMTJMBg2-cMkBWqVQYyAUKTwBCzc30JXJ054wfj06IBGeeXFdHd1-VO0J6EFrssOlAe3ntqJaVHSakLZAK8x4BI6pRL5Lb0JWUdDEuaxAm4NPAiUMvtOSLqjrOkH8r0VOv7...
  38. Math Amateur

    LaTeX Why Is My LaTeX Code Not Working?

    [SOLVED]I keep failing to be able to correct the following Latex Code B' = \{ x \in \mathbb{R^n} \ \ | \ \ a_j \leq x_j \leq t_j \text{ and } a_k \leq x_k \leq b_k \{ for } k \neq j \} Can someone help by indicating what's wrong ... Help will be much appreciated Peter
  39. M

    Python How does this recursive code work?

    Hi PF! Here is a code that generates ##n## amount of valid combinations of parenthesis e.g. n = 2 implies (()), ()(). But this wouldn't work )()( or this ))((. def generate(result, s, _open, close, n): # Base condition if close == n: result.append(s) return # If...
  40. JD_PM

    Understanding the source code for an OpenFOAM solver (CFD)

    I am trying to understand the following code (it starts from line 59) and there are pieces I do not understand. argList::addNote ( "Solver for two incompressible, isothermal immiscible fluids with" " phase-change.\n" "Uses VOF (volume of fluid) phase-fraction based...
  41. M

    Python Executing Specific Python Lines in VS Code on Ubuntu

    Hi PF! I am running VS Code for python on Ubuntu. Is there a way to execute a specific python line? As I currently have it set up, on the terminal input at the bottom of the screen, I can only work through the terminal, so a command like print('hello world') won't do anything. THanks so mcuh!
  42. I

    Prove this inequality about the weights of code words (Coding Theory)

    I'm trying to prove the following: ##wt(x+y) \leq wt(x) + wt(y)##, where "wt(x)" is referring to the weight of a specific code word. Proof: For two code words ##x, y \in F^{n}_2##, we have the inequalities ##0 \leq wt(x)## and ##0 \leq wt(y)##. Adding these together, we have ##0 \leq wt(x) +...
  43. M

    Python Why is spaces equal to tree_height-1 in the Christmas tree code in Python?

    Hey! :giggle: I found online the following code for a christmas tree in Python : tree_height = input("Enter the tree height : ") tree_height = int(tree_height) spaces = tree_height-1 hashes = 1 stump_spaces = tree_height-1 while tree_height != 0 : for i in range(spaces)...
  44. mark_bose

    I want to write my own Monte Carlo code for Neutron transport

    Hi, i would like to write my own MC code in order to simulate the transport of Neutrons in Nuclear reactors. I know the basics of MC and i have already written a code for homogeneus reactors, my problem is the generalization to more complex geometries made of different materials, such as fuel...
  45. fluidistic

    How to understand this "decompiled" program?

    I am sinking deeply into the cryptocurrencies world. There is a website that shows a "smart contract", a piece of code that is supposed to provide rewards for "staking" a particular token, where the rewards is two different tokens (I am not even sure in which proportion). Usually people who...
  46. jrrunge98

    I Is There a Hidden Pattern in This Sequence of Numbers?

    I have been trying to find a pattern in this sequence of numbers: 72.1, 25.2, 35.1, 58.3, 164.14, 99.8, 23.1, 51.5, 13.2 I have tried every method I can think of like finding the mean, putting them in numerical order, trying to see if the differences between each number has any correlation (It...
  47. R

    Resetting PC & Visual Studio Code - Need Help!

    I tried resetting the PC and reinstalling visual studio code and that does nothing. Any advice would be helpful.
  48. A

    Can DRAGON/DONJON Code Handle Complex Boron Compositions in PWR Analysis?

    Hello Everyone, Hope you will be with good health in this situation. I am Ali and i need some help regarding DRAGON/DONJON Code for PWR Analysis if anyone help me i will be very glade Regards Ali
  49. SamRoss

    How can I get the RUN button in Visual Studio Code to turn GREEN again?

    I have been using Visual Studio Code for a couple months now and it has been fine. When I want to run some code, there is usually a little green triangle button in the top right corner that I can click on. A few days ago, that triangle turned white only for Python files (it is still green for...
Back
Top