Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 9 years ago.
Improve this question
Would anyone be able to explain to me how I would go about converting this DFA to a Regular Expression using the "State Elimination" Method. I have looked online but don't quite understand the few examples I've seen.
Thank you.
First Convert the edges to RE's
Eliminate state 1
Note edge from 3 --> 3
Result = (0+10)*11(0+1)*
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
mission_id: a498094578a
mission_id: a493453456
mission_id: 498343454a
mission_id: 34534535345
From the above 4 mission_id's I need your help in writing a regex pattern which covers all the four mission_id but need to select only the numbers.
So one the first one - need to exempt 'a' and only the numbers.
mission_id:\s*\w?(\d*)\w?
That should work; maybe add any flags you need for parsing multiline text or whatever.
www.regexr.com is a great resource for trying out RegExps
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 8 years ago.
Improve this question
I have the following sentence:
distributed over a considerable extent; "far-flung trading
operations"; "the West's far-flung mountain ranges"; "widespread
nuclear fallout"
What I want is to pickup the sentence between "**********";
My regular expression is \"(.+)", but the result is not what I want(only 1 match)
Any suggestion? Thanks
May this will work.
/\"(.+?)\"/g
I'm not sure that you need to escape quotes so this maybe just fine too.
/"(.+?)"/g
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 9 years ago.
Improve this question
I'm trying to understand in a simple raytracer what does the BSDF function does and in theory I got it but in practice I don't know how to implement one.
Can someone point me out some simple examples (well-explained if possible) on how to use it?
check PBRT project. It is great book, but if you do not want to read it, there is well documented source code availabe: PBRT
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 10 years ago.
Improve this question
I'm making an mfc application in which I need to deduce if two lines intersect or not. For that I have the 2 equations:
x= [-x1y2 +x2y1 - (x2-x1)y ] / y1-y2
y= [-x3y4 +x4y3 - (y3-y4)x ] / x4-x3
But I need a way to solve these 2 equations simultaneously, How would I do that?
OK, assuming that x1,x2,x3,x4,y1,y2,y3,y4 are constant inside the process we can also write this as
x=a-b*y
y=c-d*x
with a=(-x1y2+x2y1)/y1-y2 etc.
Now substituting the first line into the second gives
y=c-d*(a-b*y)
y(1+d*b)=c-d*a
y=(c-d*a)/(1+d*b)
resubstituting into x=a-b*y gives the x part of the result
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
I would like to know the difference and how to choose the polynomial generator for different crc ?
And in some C code they have look up table to compute crc and some of them do it by xor truth table. but in both the cases it is 1byte data array. Its confusing . Could somebody explain this as well ?
Thanks.!