Click here to Skip to main content
15,889,844 members
Home / Discussions / Algorithms
   

Algorithms

 
QuestionHelp to predict the output of this code Pin
Member 141133789-Jan-19 12:39
Member 141133789-Jan-19 12:39 
AnswerRe: Help to predict the output of this code Pin
Daniel Pfeffer9-Jan-19 21:48
professionalDaniel Pfeffer9-Jan-19 21:48 
AnswerRe: Help to predict the output of this code Pin
ChrisFromWales1-May-19 0:14
ChrisFromWales1-May-19 0:14 
PraiseDinic’s algorithm for Maximum Flow Pin
AshishKhuraishy6-Dec-18 3:56
AshishKhuraishy6-Dec-18 3:56 
GeneralRe: Dinic’s algorithm for Maximum Flow Pin
Patrice T25-Dec-18 16:15
mvePatrice T25-Dec-18 16:15 
SuggestionVector representation of the code. Pin
Member 1406583326-Nov-18 7:50
Member 1406583326-Nov-18 7:50 
GeneralRe: Vector representation of the code. Pin
Gerry Schmitz27-Nov-18 9:19
mveGerry Schmitz27-Nov-18 9:19 
GeneralRe: Vector representation of the code. Pin
shooky561-Dec-18 5:04
shooky561-Dec-18 5:04 
Going to give you a small bio just so you know I have a feel for what (I think) you're trying to do. I'm old, but (to my knowledge) wrote the first flight simulator with shading including a helmet you wore to display the world depending on where you turned your head. This was 1984. At that time I had to write a fast transcendental calculator (nearly 100x faster than the then blossoming Math CoProcessors; not as precise but good enough for the app). During that time frame I read a book called, "Flight Simulators" by Dr. Bruce Artwick and a fellow that was shafting us $30-$40 a pop for new fixes to his DOS OS named Bill Gates. [My opinion of Mr. Gates improved drastically when he donated $2 billion to world health.].

My brother had recommended the book, my comment was, "These guys know their math (linear algebra) but can't write code worth sh..". Mr. Gates openly admitted this fact in an interview.

When asked "Just how good is S.... (me)?" in class one day, a 25 year Calculus teacher remarked, "He's certainly the best I've ever had and maybe the best I've ever met.".

Now that my back is throbbing from all the self-patting. I'll start the humble path. I'm "out of shape". Math is like distance running. A guy who can break 4 minutes for the mile (I got THAT close but never did) is only as good as his recent workouts. The same is true for math. I am WAY out of shape but hope my intuition is still decent.

When you say "solve more complex problems", I beg to differ. Tensor mathematics, matrices and the like introduce methodology shorthands and NOT the ability to solve unique types of problems (like calculus, differential equations and Laplace Transforms do). Even the latter is solved using the four basics (multiplication, division, etc.) in the end but they introduce the logic required to deduce those basic operations.

Let's take a discussion of matrices for example. Given a set of simultaneous equations you can reduce them to a matrix and it and the rules present easy visualization (for human eyes, not code) and logic-less (strictly rule based) solution methods (which makes coding easier).

A clever coder can solve simultaneous equations in code w/o matrices but a garden variety coder can do it with matrices. My impression of what's going on here may be similar. You're trying to introduce a visualization method and set of rules to bypass the complexity of "the other way". What you will not introduce is ability to solve problems that were deemed unsolvable by other methods. I hope I'm wrong and we get to read about your receipt of the Nobel Prize for Mathematics one day.

If you actually want help writing the code then write a function that calculates ONE calculation you want to perform no matter how ugly.

Perhaps someone familiar with tensor math (or something similar) can point you to the latest and greatest technique (like using the GPU to help). BTW, physicists have been coding solutions for as long as there have been PCs (starting with the Manhattan Project) and, because they are the tools of the trade, use math as a second language. After a lifetime of experience, I have come under the impression that nowadays anybody can write code (thanks in no small part to the efforts of the aforementioned, Mr. Bill Gates) but only mathematicians can write the really hard stuff. Again, thanks to the efforts of many, 99% (probably more like 99.9999%) of all coding requires little math skill. Yours appears to be the exception.

Good luck. Apologies for the long post... I almost never post on anything, this one caught my eye looking for something else. All the best.
QuestionOptimal Task Scheduling with Complete Knowledge Pin
Member 140435574-Nov-18 12:11
Member 140435574-Nov-18 12:11 
AnswerRe: Optimal Task Scheduling with Complete Knowledge Pin
Mycroft Holmes4-Nov-18 19:31
professionalMycroft Holmes4-Nov-18 19:31 
GeneralRe: Optimal Task Scheduling with Complete Knowledge Pin
Member 140435575-Nov-18 1:37
Member 140435575-Nov-18 1:37 
AnswerRe: Optimal Task Scheduling with Complete Knowledge Pin
Gerry Schmitz12-Nov-18 8:20
mveGerry Schmitz12-Nov-18 8:20 
QuestionChess Futility pruning Pin
GM Fafkorn5-Oct-18 22:13
GM Fafkorn5-Oct-18 22:13 
QuestionAlgorithms help Pin
Member 139775798-Sep-18 7:36
Member 139775798-Sep-18 7:36 
QuestionStart with a group of size X, divide it into Y groups, Z times, minimize overlap Pin
Member 139396526-Aug-18 5:08
Member 139396526-Aug-18 5:08 
AnswerRe: Start with a group of size X, divide it into Y groups, Z times, minimize overlap Pin
Stefan_Lang7-Aug-18 23:29
Stefan_Lang7-Aug-18 23:29 
AnswerRe: Start with a group of size X, divide it into Y groups, Z times, minimize overlap Pin
Gerry Schmitz8-Aug-18 8:38
mveGerry Schmitz8-Aug-18 8:38 
GeneralRe: Start with a group of size X, divide it into Y groups, Z times, minimize overlap Pin
Stefan_Lang8-Aug-18 21:12
Stefan_Lang8-Aug-18 21:12 
GeneralRe: Start with a group of size X, divide it into Y groups, Z times, minimize overlap Pin
Gerry Schmitz9-Aug-18 9:52
mveGerry Schmitz9-Aug-18 9:52 
GeneralRe: Start with a group of size X, divide it into Y groups, Z times, minimize overlap Pin
Stefan_Lang9-Aug-18 21:42
Stefan_Lang9-Aug-18 21:42 
GeneralRe: Start with a group of size X, divide it into Y groups, Z times, minimize overlap Pin
Kenneth Haugland9-Aug-18 22:25
mvaKenneth Haugland9-Aug-18 22:25 
GeneralRe: Start with a group of size X, divide it into Y groups, Z times, minimize overlap Pin
Gerry Schmitz11-Aug-18 9:19
mveGerry Schmitz11-Aug-18 9:19 
GeneralRe: Start with a group of size X, divide it into Y groups, Z times, minimize overlap Pin
Gerry Schmitz10-Aug-18 7:38
mveGerry Schmitz10-Aug-18 7:38 
GeneralRe: Start with a group of size X, divide it into Y groups, Z times, minimize overlap Pin
Stefan_Lang27-Aug-18 0:25
Stefan_Lang27-Aug-18 0:25 
AnswerRe: Start with a group of size X, divide it into Y groups, Z times, minimize overlap Pin
Patrice T1-Sep-18 16:42
mvePatrice T1-Sep-18 16:42 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.