Table function

mustish1
mustish1 used Ask the Experts™
on
Is it possible to solve and explain this question in a different way? I am working on an online mathematics Helper web site and I need solutions in different ways. This is not a homework or any kind of exam as I already have a solution of these questions. I just need different ways of solutions so that I can write different algorithms on those solutions and then call them in software coding randomly.

screenshot.jpg
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Most Valuable Expert 2011
Top Expert 2012

Commented:
there's not really anything else to explain this example.

given some input (from the domain) to a function, the function must return exactly one output (in the range)

Since your table has one value (8) returning 2 values (4 & 6)  that table can't be describing a function.

The answer is simply applying the definition of a function.

maybe it would help you to think of it in normal "function" syntax rather than as a table.

f(4)  = 2
f(12) = 3

but

f(8) =6
f(8)=4

therefore f is not a function, because a function can't return 2 answers for one input.

Author

Commented:
Can you explain or a link little bit more about what is domain input and what exactly the range is?
Most Valuable Expert 2011
Top Expert 2012
Commented:
domain - the set of values a function can operate on

range - the set of values a function can return
Expert Spotlight: Joe Anderson (DatabaseMX)

We’ve posted a new Expert Spotlight!  Joe Anderson (DatabaseMX) has been on Experts Exchange since 2006. Learn more about this database architect, guitar aficionado, and Microsoft MVP.

Author

Commented:
Thanks. I think its a called parameters when we use these term in methods or functions in any programming language.
Most Valuable Expert 2011
Top Expert 2012

Commented:
a parameter is a single value taken from the domain to be used in a function.

for example  I might have a function that operates on positive integers.

So f(10)  would be a legal function call.  10 is the parameter, not the domain.

the domain is the positive integers.

Author

Commented:
Thank You.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial